Details
-
Bug
-
Status: Closed (View Workflow)
-
Blocker
-
Resolution: Fixed
-
10.6, 10.7(EOL), 10.8(EOL), 10.9(EOL), 10.10(EOL), 10.11
Description
The fix of MDEV-27414 turns out to be incomplete. The server can still hang, with a deadlock between buf_pool_t::release_freed_page() and trx_purge_truncate_history(). In the latter, we'd better actively wait for the former to complete:
diff --git a/storage/innobase/trx/trx0purge.cc b/storage/innobase/trx/trx0purge.cc
|
index b834c5d070d..e162456e63f 100644
|
--- a/storage/innobase/trx/trx0purge.cc
|
+++ b/storage/innobase/trx/trx0purge.cc
|
@@ -768,11 +768,12 @@ TRANSACTIONAL_TARGET static void trx_purge_truncate_history()
|
auto block= reinterpret_cast<buf_block_t*>(bpage);
|
if (!bpage->lock.x_lock_try())
|
{
|
+ rescan:
|
/* Let buf_pool_t::release_freed_page() proceed. */
|
mysql_mutex_unlock(&buf_pool.flush_list_mutex);
|
- std::this_thread::yield();
|
+ mysql_mutex_lock(&buf_pool.mutex);
|
mysql_mutex_lock(&buf_pool.flush_list_mutex);
|
- rescan:
|
+ mysql_mutex_unlock(&buf_pool.mutex);
|
bpage= UT_LIST_GET_LAST(buf_pool.flush_list);
|
continue;
|
} |
Attachments
Issue Links
- blocks
-
MDEV-29986 Set innodb_undo_tablespaces=3 by default
-
- Closed
-
- relates to
-
MDEV-30863 Server freeze, all threads in trx_assign_rseg_low
-
- Closed
-
-
MDEV-31343 Another server hang with innodb_undo_log_truncate=ON
-
- Closed
-
-
MDEV-33009 Server hangs for a long time with innodb_undo_log_truncate=ON
-
- Closed
-
-
MDEV-27414 Server may hang when innodb_undo_log_truncate=ON
-
- Closed
-
Activity
Field | Original Value | New Value |
---|---|---|
Link |
This issue blocks |
Link |
This issue relates to |
Status | Open [ 1 ] | In Progress [ 3 ] |
issue.field.resolutiondate | 2022-12-12 07:49:27.0 | 2022-12-12 07:49:27.406 |
Fix Version/s | 10.6.12 [ 28513 ] | |
Fix Version/s | 10.7.8 [ 28515 ] | |
Fix Version/s | 10.8.7 [ 28517 ] | |
Fix Version/s | 10.9.5 [ 28519 ] | |
Fix Version/s | 10.10.3 [ 28521 ] | |
Fix Version/s | 10.11.2 [ 28523 ] | |
Fix Version/s | 10.6 [ 24028 ] | |
Fix Version/s | 10.7 [ 24805 ] | |
Fix Version/s | 10.8 [ 26121 ] | |
Fix Version/s | 10.9 [ 26905 ] | |
Fix Version/s | 10.10 [ 27530 ] | |
Fix Version/s | 10.11 [ 27614 ] | |
Resolution | Fixed [ 1 ] | |
Status | In Progress [ 3 ] | Closed [ 6 ] |
Link |
This issue relates to |
Link |
This issue relates to |
Link |
This issue relates to |