1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00
This commit is contained in:
Brave Galera Crew
2019-01-23 15:30:00 +04:00
committed by Sergey Vojtovich
parent 382115b992
commit 36a2a185fe
791 changed files with 28035 additions and 8865 deletions

View File

@ -103,5 +103,56 @@ cat_file $datadir.tempfiles.txt;
remove_file $datadir.tempfiles.txt;
list_files $datadir/mysql #sql*;
#
# Check that SHOW ENGINE INNODB STATUS does not show any active transactions
# We do this only if wsrep provider is loaded, to avoid disturbing any non-Galera MTR tests
#
if (`SELECT COUNT(*)=1 FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME = 'wsrep' AND PLUGIN_STATUS='ACTIVE'`) {
if (`SELECT @@wsrep_on`) {
if (`SELECT COUNT(*) FROM information_schema.innodb_trx WHERE trx_mysql_thread_id != 0`) {
if ($before) {
--echo Before test start.
}
if (!$before) {
--echo After test end.
}
--echo There is one or more active InnoDB transaction(s) when there should be none. Dumping some diagnostics.
--let $status_locks = `SELECT @@innodb_status_output_locks`
--let $status_output = `SELECT @@innodb_status_output`
--enable_query_log
SET GLOBAL innodb_status_output_locks=ON;
SHOW ENGINE INNODB STATUS;
--disable_query_log
--eval SET GLOBAL innodb_status_output_locks=$status_locks;
--eval SET GLOBAL innodb_status_output=$status_output;
--enable_query_log
--vertical_results
if ($before) {
--replace_regex /$/ /
}
SELECT * FROM information_schema.processlist;
if ($before) {
--replace_regex /$/ /
}
SELECT * FROM information_schema.innodb_trx;
if ($before) {
--replace_regex /$/ /
}
SELECT * FROM information_schema.innodb_locks;
if ($before) {
--replace_regex /$/ /
}
SELECT * FROM information_schema.innodb_lock_waits;
--horizontal_results
--disable_query_log
}
}
}
--enable_query_log