Skip to content

Commit 374f94c

Browse files
committed
MDEV-21751 followup: Bypass the change buffer on slow shutdown
1 parent d642c5b commit 374f94c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

storage/innobase/srv/srv0start.cc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2066,8 +2066,14 @@ void innodb_preshutdown()
20662066
if (srv_read_only_mode)
20672067
return;
20682068
if (!srv_fast_shutdown && srv_operation == SRV_OPERATION_NORMAL)
2069+
{
2070+
/* Because a slow shutdown must empty the change buffer, we had
2071+
better prevent any further changes from being buffered. */
2072+
innodb_change_buffering= 0;
2073+
20692074
while (trx_sys.any_active_transactions())
20702075
os_thread_sleep(1000);
2076+
}
20712077
srv_shutdown_bg_undo_sources();
20722078
srv_purge_shutdown();
20732079
}

0 commit comments

Comments
 (0)