diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-07-01 18:15:00 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-07-01 18:15:00 +0000 |
commit | a2a2e32c02643a0cec111511220227703fda1cd5 (patch) | |
tree | 69cc2b631234c2a8e026b9cd4d72676c61c594df /mysql-test/suite/mariabackup | |
parent | Releasing progress-linux version 1:10.11.8-1~progress7.99u1. (diff) | |
download | mariadb-a2a2e32c02643a0cec111511220227703fda1cd5.tar.xz mariadb-a2a2e32c02643a0cec111511220227703fda1cd5.zip |
Merging upstream version 1:11.4.2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/mariabackup')
27 files changed, 236 insertions, 28 deletions
diff --git a/mysql-test/suite/mariabackup/backup_ssl.result b/mysql-test/suite/mariabackup/backup_ssl.result index 099b8d42..3598c27b 100644 --- a/mysql-test/suite/mariabackup/backup_ssl.result +++ b/mysql-test/suite/mariabackup/backup_ssl.result @@ -7,3 +7,11 @@ FLUSH PRIVILEGES; # xtrabackup move back # restart DROP USER backup_user; +# +# MDEV-31855 validate ssl certificates using client password in the internal client +# +# tcp ssl ssl-verify-server-cert +# +# MDEV-32473 --disable-ssl doesn't disable it +# +# tcp skip-ssl diff --git a/mysql-test/suite/mariabackup/backup_ssl.test b/mysql-test/suite/mariabackup/backup_ssl.test index b38073cf..c38efc88 100644 --- a/mysql-test/suite/mariabackup/backup_ssl.test +++ b/mysql-test/suite/mariabackup/backup_ssl.test @@ -14,3 +14,18 @@ exec $XTRABACKUP --prepare --target-dir=$targetdir; DROP USER backup_user; rmdir $targetdir; +echo #; +echo # MDEV-31855 validate ssl certificates using client password in the internal client; +echo #; +# fails to connect, passwordless root +echo # tcp ssl ssl-verify-server-cert; +error 1; +exec $XTRABACKUP --protocol=tcp --user=root --port=$MASTER_MYPORT --backup --target-dir=$targetdir; + +--echo # +--echo # MDEV-32473 --disable-ssl doesn't disable it +--echo # +# connects fine +echo # tcp skip-ssl; +exec $XTRABACKUP --protocol=tcp --user=root --skip-ssl --port=$MASTER_MYPORT --backup --target-dir=$targetdir; +rmdir $targetdir; diff --git a/mysql-test/suite/mariabackup/backup_ssl_not_win.result b/mysql-test/suite/mariabackup/backup_ssl_not_win.result new file mode 100644 index 00000000..42376fce --- /dev/null +++ b/mysql-test/suite/mariabackup/backup_ssl_not_win.result @@ -0,0 +1,4 @@ +# +# MDEV-31855 validate ssl certificates using client password in the internal client +# +# socket ssl ssl-verify-server-cert diff --git a/mysql-test/suite/mariabackup/backup_ssl_not_win.test b/mysql-test/suite/mariabackup/backup_ssl_not_win.test new file mode 100644 index 00000000..933d434f --- /dev/null +++ b/mysql-test/suite/mariabackup/backup_ssl_not_win.test @@ -0,0 +1,10 @@ +source include/not_windows.inc; +let $targetdir=$MYSQLTEST_VARDIR/tmp/backup; + +echo #; +echo # MDEV-31855 validate ssl certificates using client password in the internal client; +echo #; +# connects fine, unix socket is a secure transport +echo # socket ssl ssl-verify-server-cert; +exec $XTRABACKUP --protocol=socket --user=root --socket=$MASTER_MYSOCK --backup --target-dir=$targetdir; +rmdir $targetdir; diff --git a/mysql-test/suite/mariabackup/compat_xtrabackup.result b/mysql-test/suite/mariabackup/compat_xtrabackup.result new file mode 100644 index 00000000..484dc0d7 --- /dev/null +++ b/mysql-test/suite/mariabackup/compat_xtrabackup.result @@ -0,0 +1,21 @@ +call mtr.add_suppression("InnoDB: New log files created"); +# +# Start of 10.11 tests +# +# +# MDEV-18931 Rename Mariabackup's xtrabackup_* files to mariadb_backup_* +# +CREATE TABLE t1(i INT PRIMARY KEY) ENGINE MYISAM; +INSERT INTO t1 VALUES (1); +# Prepare full backup, apply incremental one +# shutdown server +# remove datadir +# xtrabackup move back +# restart +SELECT * FROM test.t1; +i +1 +DROP TABLE t1; +# +# End of 10.11 tests +# diff --git a/mysql-test/suite/mariabackup/compat_xtrabackup.test b/mysql-test/suite/mariabackup/compat_xtrabackup.test new file mode 100644 index 00000000..67d043fd --- /dev/null +++ b/mysql-test/suite/mariabackup/compat_xtrabackup.test @@ -0,0 +1,62 @@ +call mtr.add_suppression("InnoDB: New log files created"); + +--echo # +--echo # Start of 10.11 tests +--echo # + +--echo # +--echo # MDEV-18931 Rename Mariabackup's xtrabackup_* files to mariadb_backup_* +--echo # + +--let $basedir=$MYSQLTEST_VARDIR/tmp/backup +--let $incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1 + +CREATE TABLE t1(i INT PRIMARY KEY) ENGINE MYISAM; +INSERT INTO t1 VALUES (1); + +--disable_result_log +--exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$basedir +--enable_result_log + +--exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$incremental_dir --incremental-basedir=$basedir + +# +# Emulate a backup created by an older version: +# Rename mariadb_backup_checkpoints +# + +--move_file $basedir/mariadb_backup_checkpoints $basedir/xtrabackup_checkpoints +--move_file $incremental_dir/mariadb_backup_checkpoints $incremental_dir/xtrabackup_checkpoints + +# +# Emulate a backup created by an older version: +# Rename mariadb_backup_info +# Note, mariadb_backup_info is not currently used during --prepare or --restore +# But it's still good to rename it: +# - we can start using it during --prepare or --restore +# - to provide full emulation +# + +--move_file $basedir/mariadb_backup_info $basedir/mariadb_backup_info +--move_file $incremental_dir/mariadb_backup_info $incremental_dir/mariadb_backup_info + + +--disable_result_log +--echo # Prepare full backup, apply incremental one +--exec $XTRABACKUP --prepare --target-dir=$basedir +--exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir +--enable_result_log + +--let $targetdir=$basedir +--source include/restart_and_restore.inc +--enable_result_log + +SELECT * FROM test.t1; + +DROP TABLE t1; +--rmdir $basedir +--rmdir $incremental_dir + +--echo # +--echo # End of 10.11 tests +--echo # diff --git a/mysql-test/suite/mariabackup/extra_lsndir.result b/mysql-test/suite/mariabackup/extra_lsndir.result index a25c45a1..58e395eb 100644 --- a/mysql-test/suite/mariabackup/extra_lsndir.result +++ b/mysql-test/suite/mariabackup/extra_lsndir.result @@ -1,2 +1,2 @@ -xtrabackup_checkpoints -xtrabackup_info +mariadb_backup_checkpoints +mariadb_backup_info diff --git a/mysql-test/suite/mariabackup/extra_lsndir_stream.result b/mysql-test/suite/mariabackup/extra_lsndir_stream.result index a25c45a1..58e395eb 100644 --- a/mysql-test/suite/mariabackup/extra_lsndir_stream.result +++ b/mysql-test/suite/mariabackup/extra_lsndir_stream.result @@ -1,2 +1,2 @@ -xtrabackup_checkpoints -xtrabackup_info +mariadb_backup_checkpoints +mariadb_backup_info diff --git a/mysql-test/suite/mariabackup/include/show_xtrabackup_slave_info.inc b/mysql-test/suite/mariabackup/include/show_xtrabackup_slave_info.inc index 4a83c9c3..ba0116a8 100644 --- a/mysql-test/suite/mariabackup/include/show_xtrabackup_slave_info.inc +++ b/mysql-test/suite/mariabackup/include/show_xtrabackup_slave_info.inc @@ -1,8 +1,8 @@ --disable_query_log ---file_exists $targetdir/xtrabackup_slave_info +--file_exists $targetdir/mariadb_backup_slave_info CREATE TEMPORARY TABLE tmp_slave_info(lineno SERIAL, line TEXT); --replace_result $targetdir TARGETDIR ---eval LOAD DATA LOCAL INFILE '$targetdir/xtrabackup_slave_info' INTO TABLE tmp_slave_info (line); +--eval LOAD DATA LOCAL INFILE '$targetdir/mariadb_backup_slave_info' INTO TABLE tmp_slave_info (line); SELECT lineno, regexp_replace( diff --git a/mysql-test/suite/mariabackup/incremental_compressed.test b/mysql-test/suite/mariabackup/incremental_compressed.test index 15aff909..ebb1fada 100644 --- a/mysql-test/suite/mariabackup/incremental_compressed.test +++ b/mysql-test/suite/mariabackup/incremental_compressed.test @@ -12,11 +12,11 @@ let $incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1; CREATE TABLE t (pk INT PRIMARY KEY) ENGINE=InnoDB ROW_FORMAT=COMPRESSED; ---exec $XTRABACKUP --backup --target-dir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root +--exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root ALTER TABLE t PARTITION BY KEY(pk); ---exec $XTRABACKUP --backup --target-dir=$incremental_dir --incremental-basedir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root > $incremental_dir.log 2>&1 +--exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$incremental_dir --incremental-basedir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root > $incremental_dir.log 2>&1 --exec $XTRABACKUP --prepare --target-dir=$basedir --user=root > $MYSQL_TMP_DIR/backup_prepare_0.log 2>&1 --exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir --user=root > $MYSQL_TMP_DIR/backup_prepare_1.log --cat_file $MYSQL_TMP_DIR/backup_prepare_1.log diff --git a/mysql-test/suite/mariabackup/innodb_force_recovery.result b/mysql-test/suite/mariabackup/innodb_force_recovery.result index 6626bb0b..8e785f3a 100644 --- a/mysql-test/suite/mariabackup/innodb_force_recovery.result +++ b/mysql-test/suite/mariabackup/innodb_force_recovery.result @@ -8,6 +8,14 @@ FOUND 1 /should only be used with "--apply-log"/ in backup.log FOUND 1 /innodb_force_recovery = 1/ in backup.log # "innodb_force_recovery" should be limited to "SRV_FORCE_IGNORE_CORRUPT" (innobackupex) FOUND 1 /innodb_force_recovery = 1/ in backup.log +# +# This fragment was added for MDEV-31505 Deprecate mariabackup --innobackupex mode +# +NOT FOUND /Deprecated program name/ in backup.log +FOUND 1 /[-][-]innobackupex.*is deprecated and will be removed in a future release/ in backup.log +# +# End of the MDEV-31505 fragment +# # "innodb_force_recovery" should be read from "backup-my.cnf" (mariabackup) FOUND 1 /innodb_force_recovery = 1/ in backup.log # "innodb_force_recovery=1" should be read from "backup-my.cnf" (innobackupex) diff --git a/mysql-test/suite/mariabackup/innodb_force_recovery.test b/mysql-test/suite/mariabackup/innodb_force_recovery.test index 3a7b3c61..91b916a2 100644 --- a/mysql-test/suite/mariabackup/innodb_force_recovery.test +++ b/mysql-test/suite/mariabackup/innodb_force_recovery.test @@ -52,6 +52,16 @@ exec $XTRABACKUP --innobackupex --apply-log --innodb-force-recovery=2 $targetdir --let SEARCH_PATTERN=innodb_force_recovery = 1 --let SEARCH_FILE=$backuplog --source include/search_pattern_in_file.inc +--echo # +--echo # This fragment was added for MDEV-31505 Deprecate mariabackup --innobackupex mode +--echo # +--let SEARCH_PATTERN=Deprecated program name +--source include/search_pattern_in_file.inc +--let SEARCH_PATTERN=[-][-]innobackupex.*is deprecated and will be removed in a future release +--source include/search_pattern_in_file.inc +--echo # +--echo # End of the MDEV-31505 fragment +--echo # rmdir $targetdir; # Check for default file ("backup-my.cnf"). diff --git a/mysql-test/suite/mariabackup/mdev-14447.result b/mysql-test/suite/mariabackup/mdev-14447.result index 16d3ab56..5db4693d 100644 --- a/mysql-test/suite/mariabackup/mdev-14447.result +++ b/mysql-test/suite/mariabackup/mdev-14447.result @@ -1,5 +1,7 @@ call mtr.add_suppression("InnoDB: New log files created"); SET GLOBAL innodb_file_per_table=0; +Warnings: +Warning 1287 '@@innodb_file_per_table' is deprecated and will be removed in a future release CREATE TABLE t(a varchar(40) PRIMARY KEY, b varchar(40), c varchar(40), d varchar(40), index(b,c,d)) ENGINE INNODB; # Create full backup , modify table, then create incremental/differential backup SET debug_dbug='+d,skip_page_checksum',foreign_key_checks=0,unique_checks=0; diff --git a/mysql-test/suite/mariabackup/rpl_clone_slave.result b/mysql-test/suite/mariabackup/rpl_clone_slave.result index 2e6c2701..fc6390eb 100644 --- a/mysql-test/suite/mariabackup/rpl_clone_slave.result +++ b/mysql-test/suite/mariabackup/rpl_clone_slave.result @@ -45,13 +45,13 @@ connection master; connection slave; ############################################################## ### Running `mariadb-backup --backup,--prepare` and checking -### that xtrabackup_slave_info and xtrabackup_binlog_info are OK +### that mariadb_backup_slave_info and mariadb_backup_binlog_info are OK ### Slave: Create a backup ### Slave: Prepare the backup ### Slave: xtrabackup files: -############################ xtrabackup_slave_info +############################ mariadb_backup_slave_info CHANGE MASTER TO MASTER_LOG_FILE='master_after_tr01_show_master_status_file', MASTER_LOG_POS=master_after_tr01_show_master_status_position; -############################ xtrabackup_binlog_info +############################ mariadb_backup_binlog_info slave_after_tr01_show_master_status_file slave_after_tr01_show_master_status_position slave_after_tr01_gtid_binlog_pos ############################ ############################################################## @@ -135,8 +135,8 @@ tr#01:stmt#00 - slave run#0, before backup tr#01:stmt#01 - slave run#0, before backup tr#01:stmt#02 - slave run#0, before backup ### Slave: Execute the CHANGE MASTER statement to set up the host and port -CHANGE MASTER '' TO MASTER_USER='root', MASTER_HOST='127.0.0.1', MASTER_PORT=###, MASTER_CONNECT_RETRY=1; -### Slave: Execute the CHANGE MASTER statement from xtrabackup_slave_info +CHANGE MASTER '' TO MASTER_USER='root', MASTER_HOST='127.0.0.1', MASTER_PORT=###, MASTER_CONNECT_RETRY=1, MASTER_SSL_VERIFY_SERVER_CERT=0; +### Slave: Execute the CHANGE MASTER statement from mariadb_backup_slave_info CHANGE MASTER TO MASTER_LOG_FILE='master_after_tr01_show_master_status_file', MASTER_LOG_POS=master_after_tr01_show_master_status_position; Warnings: Note 4190 CHANGE MASTER TO is implicitly changing the value of 'Using_Gtid' from 'Slave_Pos' to 'No' diff --git a/mysql-test/suite/mariabackup/rpl_slave_info.result b/mysql-test/suite/mariabackup/rpl_slave_info.result index ec27166e..2b9b6223 100644 --- a/mysql-test/suite/mariabackup/rpl_slave_info.result +++ b/mysql-test/suite/mariabackup/rpl_slave_info.result @@ -11,8 +11,8 @@ connection master; CREATE TABLE t(i INT); connection slave; "using_gtid: Slave_Pos" -FOUND 1 /gtid_slave_pos/ in xtrabackup_slave_info -NOT FOUND /MASTER_LOG_FILE/ in xtrabackup_slave_info +FOUND 1 /gtid_slave_pos/ in mariadb_backup_slave_info +NOT FOUND /MASTER_LOG_FILE/ in mariadb_backup_slave_info lineno line 1 SET GLOBAL gtid_slave_pos = '<NUM-NUM-NUM>'; 2 CHANGE MASTER TO master_use_gtid = slave_pos; @@ -21,8 +21,8 @@ lineno line ######################## include/stop_slave.inc SET GLOBAL gtid_slave_pos=""; -NOT FOUND /gtid_slave_pos/ in xtrabackup_slave_info -FOUND 1 /MASTER_LOG_FILE/ in xtrabackup_slave_info +NOT FOUND /gtid_slave_pos/ in mariadb_backup_slave_info +FOUND 1 /MASTER_LOG_FILE/ in mariadb_backup_slave_info lineno line 1 CHANGE MASTER TO MASTER_LOG_FILE='master-bin.000001', MASTER_LOG_POS=<NUM>; ############### @@ -34,8 +34,8 @@ connection master; INSERT INTO t VALUES(1); connection slave; "using_gtid: No" -NOT FOUND /gtid_slave_pos/ in xtrabackup_slave_info -FOUND 1 /MASTER_LOG_FILE/ in xtrabackup_slave_info +NOT FOUND /gtid_slave_pos/ in mariadb_backup_slave_info +FOUND 1 /MASTER_LOG_FILE/ in mariadb_backup_slave_info lineno line 1 CHANGE MASTER TO MASTER_LOG_FILE='master-bin.000001', MASTER_LOG_POS=<NUM>; connection master; diff --git a/mysql-test/suite/mariabackup/rpl_slave_info.test b/mysql-test/suite/mariabackup/rpl_slave_info.test index 1c5dd89a..73ad00f1 100644 --- a/mysql-test/suite/mariabackup/rpl_slave_info.test +++ b/mysql-test/suite/mariabackup/rpl_slave_info.test @@ -22,7 +22,7 @@ CREATE TABLE t(i INT); exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --defaults-group-suffix=.2 --slave-info --backup --target-dir=$targetdir; --enable_result_log ---let SEARCH_FILE=$targetdir/xtrabackup_slave_info +--let SEARCH_FILE=$targetdir/mariadb_backup_slave_info --let SEARCH_PATTERN=gtid_slave_pos --source include/search_pattern_in_file.inc --let SEARCH_PATTERN=MASTER_LOG_FILE @@ -45,7 +45,7 @@ SET GLOBAL gtid_slave_pos=""; exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --defaults-group-suffix=.2 --slave-info --backup --target-dir=$targetdir; --enable_result_log ---let SEARCH_FILE=$targetdir/xtrabackup_slave_info +--let SEARCH_FILE=$targetdir/mariadb_backup_slave_info --let SEARCH_PATTERN=gtid_slave_pos --source include/search_pattern_in_file.inc --let SEARCH_PATTERN=MASTER_LOG_FILE @@ -73,7 +73,7 @@ INSERT INTO t VALUES(1); exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --defaults-group-suffix=.2 --slave-info --backup --target-dir=$targetdir; --enable_result_log ---let SEARCH_FILE=$targetdir/xtrabackup_slave_info +--let SEARCH_FILE=$targetdir/mariadb_backup_slave_info --let SEARCH_PATTERN=gtid_slave_pos --source include/search_pattern_in_file.inc --let SEARCH_PATTERN=MASTER_LOG_FILE diff --git a/mysql-test/suite/mariabackup/slave_info_norpl.result b/mysql-test/suite/mariabackup/slave_info_norpl.result index 04ca2fb2..18cda940 100644 --- a/mysql-test/suite/mariabackup/slave_info_norpl.result +++ b/mysql-test/suite/mariabackup/slave_info_norpl.result @@ -8,7 +8,7 @@ SELECT @@global.gtid_slave_pos; @@global.gtid_slave_pos -# Without any masters the file xtrabackup_slave_info is not created +# Without any masters the file mariadb_backup_slave_info is not created line [00] YYYY-MM-DD hh:mm:ss Failed to get master binlog coordinates from SHOW SLAVE STATUS.This means that the server is not a replication slave. Ignoring the --slave-info option diff --git a/mysql-test/suite/mariabackup/slave_info_norpl.test b/mysql-test/suite/mariabackup/slave_info_norpl.test index 0d2d2ed4..298aaa2d 100644 --- a/mysql-test/suite/mariabackup/slave_info_norpl.test +++ b/mysql-test/suite/mariabackup/slave_info_norpl.test @@ -19,13 +19,13 @@ SELECT @@global.gtid_slave_pos; --echo ---echo # Without any masters the file xtrabackup_slave_info is not created +--echo # Without any masters the file mariadb_backup_slave_info is not created --disable_result_log exec $XTRABACKUP $XTRABACKUP_ARGS >$XTRABACKUP_OUT; --enable_result_log --error 1 ---file_exists $targetdir/xtrabackup_slave_info +--file_exists $targetdir/mariadb_backup_slave_info --source include/show_xtrabackup_slave_info_out.inc --remove_file $XTRABACKUP_OUT rmdir $targetdir; diff --git a/mysql-test/suite/mariabackup/slave_provision_nolock.cnf b/mysql-test/suite/mariabackup/slave_provision_nolock.cnf index 0e0bbd63..d8326a5c 100644 --- a/mysql-test/suite/mariabackup/slave_provision_nolock.cnf +++ b/mysql-test/suite/mariabackup/slave_provision_nolock.cnf @@ -1,3 +1,5 @@ +!include include/default_my.cnf + [mysqld.1] log-slave-updates loose-innodb diff --git a/mysql-test/suite/mariabackup/slave_provision_nolock.result b/mysql-test/suite/mariabackup/slave_provision_nolock.result index 445a9801..66e0a079 100644 --- a/mysql-test/suite/mariabackup/slave_provision_nolock.result +++ b/mysql-test/suite/mariabackup/slave_provision_nolock.result @@ -28,6 +28,7 @@ CREATE TABLE t3 (file VARCHAR(255), pos INT) ENGINE=InnoDB; LOAD DATA LOCAL INFILE "BASEDIR/xtrabackup_binlog_pos_innodb" INTO TABLE t3 FIELDS ESCAPED BY '' (file, pos); CHANGE MASTER TO +master_ssl_verify_server_cert=0, master_port=PORT, master_host='127.0.0.1', master_user='root', master_log_file= "MASTER_FILE", master_log_pos= MASTER_POS; diff --git a/mysql-test/suite/mariabackup/slave_provision_nolock.test b/mysql-test/suite/mariabackup/slave_provision_nolock.test index 618f3132..874a32d6 100644 --- a/mysql-test/suite/mariabackup/slave_provision_nolock.test +++ b/mysql-test/suite/mariabackup/slave_provision_nolock.test @@ -139,6 +139,7 @@ eval LOAD DATA LOCAL INFILE "$basedir/xtrabackup_binlog_pos_innodb" --replace_result $SERVER_MYPORT_1 PORT $provision_master_file MASTER_FILE $provision_master_pos MASTER_POS eval CHANGE MASTER TO + master_ssl_verify_server_cert=0, master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_log_file= "$provision_master_file", master_log_pos= $provision_master_pos; diff --git a/mysql-test/suite/mariabackup/sys_truncate.opt b/mysql-test/suite/mariabackup/sys_truncate.opt new file mode 100644 index 00000000..006127ed --- /dev/null +++ b/mysql-test/suite/mariabackup/sys_truncate.opt @@ -0,0 +1,2 @@ +--innodb_data_file_path=ibdata1:1M:autoextend:autoshrink +--innodb_sys_tablespaces diff --git a/mysql-test/suite/mariabackup/sys_truncate.result b/mysql-test/suite/mariabackup/sys_truncate.result new file mode 100644 index 00000000..f1932a3d --- /dev/null +++ b/mysql-test/suite/mariabackup/sys_truncate.result @@ -0,0 +1,28 @@ +SET GLOBAL INNODB_FILE_PER_TABLE= 0; +Warnings: +Warning 1287 '@@innodb_file_per_table' is deprecated and will be removed in a future release +CREATE TABLE t1(f1 INT NOT NULL, f2 INT NOT NULL, +f3 INT NOT NULL, INDEX(f1), +INDEX(f2), INDEX(f3))ENGINE=InnoDB; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +DROP TABLE t1; +InnoDB 0 transactions not purged +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; +NAME FILE_SIZE +innodb_system 70254592 +# restart +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; +NAME FILE_SIZE +innodb_system 3145728 +# Incremental backup +# Prepare full backup, apply incremental one +# Restore and check results +# shutdown server +# remove datadir +# xtrabackup move back +# restart +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; +NAME FILE_SIZE +innodb_system 3145728 diff --git a/mysql-test/suite/mariabackup/sys_truncate.test b/mysql-test/suite/mariabackup/sys_truncate.test new file mode 100644 index 00000000..4f4ea510 --- /dev/null +++ b/mysql-test/suite/mariabackup/sys_truncate.test @@ -0,0 +1,36 @@ +--source include/have_innodb.inc +--source include/have_sequence.inc +let basedir=$MYSQLTEST_VARDIR/tmp/backup; +let incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1; +SET GLOBAL INNODB_FILE_PER_TABLE= 0; +CREATE TABLE t1(f1 INT NOT NULL, f2 INT NOT NULL, + f3 INT NOT NULL, INDEX(f1), + INDEX(f2), INDEX(f3))ENGINE=InnoDB; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +INSERT INTO t1 SELECT seq, seq, seq FROM seq_1_to_16384; +DROP TABLE t1; +--source ../innodb/include/wait_all_purged.inc +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; +--disable_result_log +exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --parallel=10 --target-dir=$basedir --throttle=1000; +--enable_result_log +--source include/restart_mysqld.inc +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; + +--echo # Incremental backup +exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --parallel=2 --ftwrl-wait-timeout=5 --ftwrl-wait-threshold=300 --ftwrl-wait-query-type=all --target-dir=$incremental_dir --incremental-basedir=$basedir; + +--disable_result_log +echo # Prepare full backup, apply incremental one; +exec $XTRABACKUP --prepare --target-dir=$basedir; +exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir; + +echo # Restore and check results; +let $targetdir=$basedir; +-- source include/restart_and_restore.inc +--enable_result_log +SELECT NAME, FILE_SIZE FROM information_schema.innodb_sys_tablespaces WHERE SPACE = 0; +# Cleanup +rmdir $basedir; +rmdir $incremental_dir; diff --git a/mysql-test/suite/mariabackup/undo_space_id.opt b/mysql-test/suite/mariabackup/undo_space_id.opt index 006e17a2..cc31e3dc 100644 --- a/mysql-test/suite/mariabackup/undo_space_id.opt +++ b/mysql-test/suite/mariabackup/undo_space_id.opt @@ -1,3 +1,3 @@ ---debug=d,innodb_undo_upgrade,force_rebootstrap +--debug-dbug=d,innodb_undo_upgrade,force_rebootstrap --innodb_data_file_path=ib_mysql:10M --innodb_undo_tablespaces=2 diff --git a/mysql-test/suite/mariabackup/xb_compressed_encrypted.opt b/mysql-test/suite/mariabackup/xb_compressed_encrypted.opt index 4105fecf..52ef47f3 100644 --- a/mysql-test/suite/mariabackup/xb_compressed_encrypted.opt +++ b/mysql-test/suite/mariabackup/xb_compressed_encrypted.opt @@ -5,4 +5,3 @@ --loose-file-key-management --loose-file-key-management-filename=$MYSQL_TEST_DIR/std_data/logkey.txt --innodb_strict_mode ---innodb_file_per_table diff --git a/mysql-test/suite/mariabackup/xb_fulltext_encrypted.opt b/mysql-test/suite/mariabackup/xb_fulltext_encrypted.opt index b3ef3663..e3a9e5a4 100644 --- a/mysql-test/suite/mariabackup/xb_fulltext_encrypted.opt +++ b/mysql-test/suite/mariabackup/xb_fulltext_encrypted.opt @@ -1,6 +1,5 @@ --plugin-load-add=$FILE_KEY_MANAGEMENT_SO --innodb_strict_mode ---innodb_file_per_table --innodb-encryption-rotate-key-age=2 --innodb-encryption-threads=4 --innodb-tablespaces-encryption |