2017-09-16 08:53:29 +02:00
|
|
|
call mtr.add_suppression("InnoDB: New log files created");
|
|
|
|
CREATE TABLE t(a INT UNSIGNED PRIMARY KEY) ENGINE INNODB;
|
|
|
|
INSERT INTO t VALUES(0);
|
|
|
|
COMMIT;
|
|
|
|
start transaction;
|
2017-12-22 11:23:39 +01:00
|
|
|
connect flush_log,localhost,root,,;
|
2017-12-21 16:40:01 +01:00
|
|
|
BEGIN;
|
|
|
|
DELETE FROM t LIMIT 1;
|
|
|
|
SET GLOBAL innodb_flush_log_at_trx_commit = 1;
|
|
|
|
ROLLBACK;
|
2017-12-22 11:23:39 +01:00
|
|
|
disconnect flush_log;
|
|
|
|
connection default;
|
2018-01-31 11:01:35 +01:00
|
|
|
NOT FOUND /Rolled back recovered transaction/ in current_test
|
2017-09-16 08:53:29 +02:00
|
|
|
# expect NOT FOUND
|
2018-01-31 11:01:35 +01:00
|
|
|
NOT FOUND /Rolled back recovered transaction/ in current_test
|
2017-09-16 08:53:29 +02:00
|
|
|
# expect NOT FOUND
|
|
|
|
commit;
|
|
|
|
SELECT count(*) FROM t;
|
|
|
|
count(*)
|
|
|
|
201
|
|
|
|
# Restore and check results
|
|
|
|
# shutdown server
|
|
|
|
# remove datadir
|
|
|
|
# xtrabackup move back
|
|
|
|
# restart server
|
|
|
|
SELECT COUNT(*) FROM t;
|
|
|
|
COUNT(*)
|
|
|
|
1
|
|
|
|
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;
|
|
|
|
SELECT COUNT(*) FROM t;
|
|
|
|
COUNT(*)
|
|
|
|
201
|
|
|
|
SELECT * FROM t;
|
|
|
|
a
|
|
|
|
0
|
|
|
|
DROP TABLE t;
|