Skip to content

Commit c638051

Browse files
committed
MDEV-32798 innodb_fast_shutdown=0 hang after incomplete startup
innodb_preshutdown(): Only wait for active transactions to be terminated if InnoDB was started and innodb_force_recovery=3 or larger does not prevent a rollback. This fixes the following: ./mtr --parallel=auto --mysqld=--innodb-fast-shutdown=0 \ innodb.log_file_size innodb.innodb_force_recovery \ innodb.read_only_recovery innodb.read_only_recover_committed \ mariabackup.apply-log-only-incr
1 parent 9f83a88 commit c638051

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

storage/innobase/srv/srv0start.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1995,7 +1995,7 @@ void innodb_preshutdown()
19951995
better prevent any further changes from being buffered. */
19961996
innodb_change_buffering= 0;
19971997

1998-
if (trx_sys.is_initialised())
1998+
if (srv_force_recovery < SRV_FORCE_NO_TRX_UNDO && srv_was_started)
19991999
while (trx_sys.any_active_transactions())
20002000
os_thread_sleep(1000);
20012001
}

0 commit comments

Comments
 (0)