mariadb/storage/innobase
Marko Mäkelä e5b155a4e5 MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish
In the 10.1 InnoDB Plugin, a call os_event_free(buf_flush_event) was
misplaced. The event could be triggered by rollback of resurrected
transactions while shutdown was in progress. This bug was caught
by cmake -DWITH_ASAN testing. This call was only present in the
10.1 InnoDB Plugin, not in other versions, or in XtraDB.

That said, the bug affects all InnoDB versions. Shutdown assumes the
cessation of any page-dirtying activity, including the activity of
the background rollback thread. InnoDB only waited for the background
rollback to finish as part of a slow shutdown (innodb_fast_shutdown=0).
The default is a clean shutdown (innodb_fast_shutdown=1). In a scenario
where InnoDB is killed, restarted, and shut down soon enough, the data
files could become corrupted.

logs_empty_and_mark_files_at_shutdown(): Wait for the
rollback to finish, except if innodb_fast_shutdown=2
(crash-like shutdown) was requested.

trx_rollback_or_clean_recovered(): Before choosing the next
recovered transaction to roll back, terminate early if non-slow
shutdown was initiated. Roll back everything on slow shutdown
(innodb_fast_shutdown=0).

srv_innodb_monitor_mutex: Declare as static, because the mutex
is only used within one module.

In 10.2, os_event_destroy() sets the event to a NULL pointer,
while os_event_free() in earlier versions did not do that.
2017-03-13 18:11:36 +02:00
..
btr Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
buf Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
data Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
dict enum btr_latch_mode: Incorporate some flags. 2017-03-09 10:30:36 +02:00
eval
fil MDEV-12201 innodb_flush_method are not available on Windows 2017-03-09 19:19:38 +00:00
fsp Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
fts
fut
gis Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
ha
handler Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
ibuf Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
include Define a mtr_t::start() wrapper inline. 2017-03-13 18:11:01 +02:00
lock Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
log MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-13 18:11:36 +02:00
mach
mem Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
mtr Define a mtr_t::start() wrapper inline. 2017-03-13 18:11:01 +02:00
mysql-test/storage_engine
os MDEV-12201 innodb_flush_method are not available on Windows 2017-03-09 19:19:38 +00:00
page Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
pars
que
read
rem Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
row Remove trx_sys_t::pending_purge_rseg_array. 2017-03-09 15:58:33 +02:00
srv MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-13 18:11:36 +02:00
sync Adjust an outdated comment. 2017-03-13 18:11:01 +02:00
trx MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-13 18:11:36 +02:00
usr
ut Fix many -Wconversion warnings. 2017-03-07 19:07:27 +02:00
CMakeLists.txt
compile-innodb
COPYING.Google
COPYING.Percona
innodb.cmake
plugin_exports