mariadb/storage/innobase
Marko Mäkelä 032678ad18 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 signalled 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.

After each call to os_event_free(), ensure that the freed event
is not reachable via global variables, by setting the relevant
variables to NULL.
2017-03-10 18:54:29 +02:00
..
api Merge branch 'merge-innodb-5.6' into 10.0 2015-08-03 16:23:58 +02:00
btr Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
buf Use correct integer format with printf-like functions. 2017-03-09 11:28:07 +02:00
data 5.6.31 2016-06-21 14:21:03 +02:00
dict Fix a compiler warning. 2017-03-08 10:06:34 +02:00
dyn Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
eval move to storage/innobase 2015-05-04 19:17:21 +02:00
fil MDEV-11520: Retry posix_fallocate() after EINTR. 2017-03-03 12:03:33 +02:00
fsp Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
fts MDEV-11233 CREATE FULLTEXT INDEX with a token longer than 127 bytes 2017-01-27 10:19:39 +02:00
fut move to storage/innobase 2015-05-04 19:17:21 +02:00
ha move to storage/innobase 2015-05-04 19:17:21 +02:00
handler Rewrite the innodb.log_file_size test with DBUG_EXECUTE_IF. 2017-02-05 17:07:16 +02:00
ibuf Merge branch 'merge-innodb-5.6' into 10.0 2016-06-21 14:58:19 +02:00
include Merge 5.5 into 10.0 2017-03-08 11:40:43 +02:00
lock Merge branch 'merge-innodb-5.6' into 10.0 2016-06-21 14:58:19 +02:00
log MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-10 18:54:29 +02:00
mach 5.6.35 2017-01-07 14:24:42 +02:00
mem 5.6.31 2016-06-21 14:21:03 +02:00
mtr Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
mysql-test/storage_engine 5.5 merge 2014-11-19 17:23:39 +01:00
os MDEV-11520: Retry posix_fallocate() after EINTR. 2017-03-03 12:03:33 +02:00
page Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
pars 5.6.31 2016-06-21 14:21:03 +02:00
que 5.6.24 2015-05-04 22:13:46 +02:00
read move to storage/innobase 2015-05-04 19:17:21 +02:00
rem Fix gcc 6.3.x compiler warnings. 2017-02-16 12:02:31 +02:00
row Merge branch '5.5' into 10.0 2017-03-03 01:37:54 +02:00
srv MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-10 18:54:29 +02:00
sync Remove unused declarations. 2017-03-08 11:46:34 +02:00
trx MDEV-12091 Shutdown fails to wait for rollback of recovered transactions to finish 2017-03-10 18:54:29 +02:00
usr move to storage/innobase 2015-05-04 19:17:21 +02:00
ut MDEV-9276: MySQL Bug #78754: FK definitions missing from SHOW CREATE TABLE in "innodb_read_only" mode 2015-12-14 22:10:37 +02:00
CMakeLists.txt MDEV-8883 more cross-compiling fixes 2015-10-24 19:58:34 +02:00
compile-innodb move to storage/innobase 2015-05-04 19:17:21 +02:00
COPYING.Google move to storage/innobase 2015-05-04 19:17:21 +02:00
COPYING.Percona move to storage/innobase 2015-05-04 19:17:21 +02:00
Doxyfile move to storage/innobase 2015-05-04 19:17:21 +02:00
ha_innodb.def move to storage/innobase 2015-05-04 19:17:21 +02:00
plugin_exports Solaris compilation failure: xtradb is linked in statically, ha_innodb.so needs 2014-05-01 14:05:52 +02:00