Debian Codegraph @

mysql-test/suite/mariabackup/incremental_newdb_while_backup.test

raw
1 --source include/have_innodb.inc
2 --source include/have_debug.inc
3 --source include/innodb_undo_tablespaces.inc
4
5 call mtr.add_suppression("InnoDB: New log files created");
6
7 --echo #
8 --echo # Start of 10.2 tests
9 --echo #
10
11 --echo #
12 --echo # MDEV-28446 mariabackup prepare fails for incrementals if a new schema is created after full backup is taken
13 --echo #
14
15 --let $basedir=$MYSQLTEST_VARDIR/tmp/backup
16 --let $incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1
17
18 CREATE TABLE t1(i INT PRIMARY KEY) ENGINE INNODB;
19
20 --disable_result_log
21 --exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$basedir
22 --enable_result_log
23
24 --let after_load_tablespaces=BEGIN NOT ATOMIC CREATE DATABASE test1; CREATE TABLE test1.t1 ENGINE=INNODB SELECT UUID() from test.seq_1_to_10000; END
25
26 --exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$incremental_dir --incremental-basedir=$basedir --dbug=+d,mariabackup_events,mariabackup_inject_code
27 --let after_load_tablespaces=
28 --disable_result_log
29 --echo # Prepare full backup, apply incremental one
30 --exec $XTRABACKUP --prepare --target-dir=$basedir
31 --exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir
32 --enable_result_log
33
34 --let $targetdir=$basedir
35 --source include/restart_and_restore.inc
36 --enable_result_log
37
38 SELECT COUNT(*) FROM test.t1;
39 SELECT COUNT(*) FROM test1.t1;
40
41 DROP TABLE t1;
42 DROP DATABASE test1;
43 --rmdir $basedir
44 --rmdir $incremental_dir
45
46 --echo #
47 --echo # End of 10.2 tests
48 --echo #