| 1 |
# |
| 2 |
# Bug#29833945 SERVER HANGS IF RESTARTED WITH WRONG LOWER_CASE_TABLE_NAMES VALUE |
| 3 |
# |
| 4 |
|
| 5 |
--source include/have_lowercase0.inc |
| 6 |
|
| 7 |
--echo # SETUP |
| 8 |
CREATE TABLE t1 (c1 INT); |
| 9 |
INSERT INTO t1 VALUES(1); |
| 10 |
|
| 11 |
--echo # Start a transaction but don't commit it. |
| 12 |
BEGIN; |
| 13 |
INSERT INTO t1 VALUES(2); |
| 14 |
|
| 15 |
SET GLOBAL innodb_log_flush_now = ON; |
| 16 |
--source include/kill_mysqld.inc |
| 17 |
|
| 18 |
# LCTN mismatch will cause server startup to abort but transaction won't |
| 19 |
# be rollbacked. Without the patch, abort will be hung. |
| 20 |
--echo # Start MySQL after crash with different LCTN value and slow shutdown. |
| 21 |
--error 1,42 |
| 22 |
--exec $MYSQLD_CMD --innodb-fast-shutdown=0 --lower_case_table_names=1 --log-error=$MYSQLTEST_VARDIR/log/my_restart.err |
| 23 |
|
| 24 |
--echo # Verifying that recovery found transaction which needs rollback |
| 25 |
let SEARCH_FILE=$MYSQLTEST_VARDIR/log/my_restart.err; |
| 26 |
let SEARCH_PATTERN= MY-013023; |
| 27 |
--source include/search_pattern.inc |
| 28 |
--remove_file $SEARCH_FILE |
| 29 |
|
| 30 |
--echo # Restart server with correct LCTN |
| 31 |
let $restart_parameters = "restart: --innodb-fast-shutdown=0 --lower_case_table_names=0 --log-error=$MYSQLTEST_VARDIR/log/my_restart.err"; |
| 32 |
--source include/start_mysqld.inc |
| 33 |
|
| 34 |
--echo # Verifying that transaction was rollbacked |
| 35 |
let SEARCH_FILE=$MYSQLTEST_VARDIR/log/my_restart.err; |
| 36 |
let SEARCH_PATTERN= MY-013012; |
| 37 |
--source include/search_pattern.inc |
| 38 |
--remove_file $SEARCH_FILE |
| 39 |
|
| 40 |
--echo # CLEANUP |
| 41 |
--echo # Restart server to restore server state. |
| 42 |
let $restart_parameters = "restart:"; |
| 43 |
--source include/restart_mysqld.inc |
| 44 |
DROP TABLE t1; |