summaryrefslogtreecommitdiff
path: root/mysql-test/suite/mariabackup/compress_qpress.test
blob: c7762f8e55efd594ccede1131d0ec09361e140e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
CREATE TABLE t(i INT) ENGINE INNODB;
INSERT INTO t VALUES(1);
echo # xtrabackup backup;
let $targetdir=$MYSQLTEST_VARDIR/tmp/backup;

--disable_result_log
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --compress --target-dir=$targetdir;
--enable_result_log

INSERT INTO t VALUES(2);


echo # xtrabackup prepare;
--disable_result_log
# Because MDEV-24626 in 10.6 optimized file creation, we could end up with
# t.new.qp instead of t.ibd.qp unless a log checkpoint happened to be
# triggered between CREATE TABLE and the backup run.
--replace_result t.new t.ibd
list_files  $targetdir/test *.qp;
exec $XTRABACKUP --decompress --remove-original --target-dir=$targetdir;
list_files  $targetdir/test *.qp;
exec $XTRABACKUP  --prepare --target-dir=$targetdir;
-- source include/restart_and_restore.inc
--enable_result_log

SELECT * FROM t;
DROP TABLE t;
rmdir $targetdir;