Skip to content

Commit 761cf49

Browse files
committed
Merge 10.1 into 10.2
2 parents 6233398 + d2ffafe commit 761cf49

File tree

3 files changed

+23
-4
lines changed

3 files changed

+23
-4
lines changed

mysql-test/suite/mariabackup/incremental_backup.result

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,22 @@
11
call mtr.add_suppression("InnoDB: New log files created");
2-
CREATE TABLE t(i INT) ENGINE INNODB;
2+
CREATE TABLE t(i INT PRIMARY KEY) ENGINE INNODB;
3+
BEGIN;
4+
INSERT INTO t VALUES(2);
5+
connect con1,localhost,root,,;
6+
SET GLOBAL innodb_flush_log_at_trx_commit = 1;
37
INSERT INTO t VALUES(1);
48
# Create full backup , modify table, then create incremental/differential backup
5-
INSERT INTO t VALUES(2);
9+
BEGIN;
10+
INSERT INTO t VALUES(0);
11+
DELETE FROM t WHERE i=0;
12+
connection default;
13+
COMMIT;
614
SELECT * FROM t;
715
i
816
1
917
2
1018
# Prepare full backup, apply incremental one
19+
disconnect con1;
1120
# Restore and check results
1221
# shutdown server
1322
# remove datadir

mysql-test/suite/mariabackup/incremental_backup.test

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,22 @@ call mtr.add_suppression("InnoDB: New log files created");
55
let $basedir=$MYSQLTEST_VARDIR/tmp/backup;
66
let $incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1;
77

8-
CREATE TABLE t(i INT) ENGINE INNODB;
8+
CREATE TABLE t(i INT PRIMARY KEY) ENGINE INNODB;
9+
BEGIN;
10+
INSERT INTO t VALUES(2);
11+
connect (con1,localhost,root,,);
12+
SET GLOBAL innodb_flush_log_at_trx_commit = 1;
913
INSERT INTO t VALUES(1);
1014

1115
echo # Create full backup , modify table, then create incremental/differential backup;
1216
--disable_result_log
1317
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$basedir;
1418
--enable_result_log
15-
INSERT INTO t VALUES(2);
19+
BEGIN;
20+
INSERT INTO t VALUES(0);
21+
DELETE FROM t WHERE i=0;
22+
connection default;
23+
COMMIT;
1624
SELECT * FROM t;
1725
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --ftwrl-wait-timeout=5 --ftwrl-wait-threshold=300 --ftwrl-wait-query-type=all --target-dir=$incremental_dir --incremental-basedir=$basedir;
1826

@@ -21,6 +29,7 @@ echo # Prepare full backup, apply incremental one;
2129
exec $XTRABACKUP --prepare --target-dir=$basedir;
2230
exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir ;
2331

32+
disconnect con1;
2433
echo # Restore and check results;
2534
let $targetdir=$basedir;
2635
-- source include/restart_and_restore.inc

storage/xtradb/trx/trx0undo.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2025,6 +2025,7 @@ trx_undo_free_prepared(
20252025
/* lock_trx_release_locks() assigns
20262026
trx->is_recovered=false */
20272027
ut_a(srv_read_only_mode
2028+
|| srv_apply_log_only
20282029
|| srv_force_recovery >= SRV_FORCE_NO_TRX_UNDO);
20292030
break;
20302031
default:

0 commit comments

Comments
 (0)