| 1 |
let $alg = $MTR_COMBINATIONS; |
| 2 |
|
| 3 |
if (`select count(*) = 0 from information_schema.plugins where plugin_name = 'provider_$alg' and plugin_status='active'`) |
| 4 |
{ |
| 5 |
skip "Needs provider_$alg plugin"; |
| 6 |
} |
| 7 |
|
| 8 |
--echo # |
| 9 |
--echo # Testing mariabackup with $alg compression |
| 10 |
--echo # |
| 11 |
|
| 12 |
--echo # Creating table |
| 13 |
eval set global innodb_compression_algorithm = $alg; |
| 14 |
eval create table t1 (a int, b text $column_params) engine = innodb page_compressed = 1; |
| 15 |
insert t1 (a, b) values (0, repeat("abc", 100)); |
| 16 |
insert t1 (a, b) values (1, repeat("def", 1000)); |
| 17 |
insert t1 (a, b) values (2, repeat("ghi", 10000)); |
| 18 |
select a, left(b, 9), length(b) from t1; |
| 19 |
|
| 20 |
--source include/restart_mysqld.inc |
| 21 |
|
| 22 |
--echo # xtrabackup backup |
| 23 |
let $targetdir=$MYSQLTEST_VARDIR/tmp/backup; |
| 24 |
|
| 25 |
disable_result_log; |
| 26 |
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$targetdir; |
| 27 |
enable_result_log; |
| 28 |
|
| 29 |
--echo # xtrabackup prepare; |
| 30 |
disable_result_log; |
| 31 |
exec $XTRABACKUP --prepare --target-dir=$targetdir; |
| 32 |
source include/restart_and_restore.inc; |
| 33 |
enable_result_log; |
| 34 |
|
| 35 |
select a, left(b, 9), length(b) from t1; |
| 36 |
|
| 37 |
drop table t1; |
| 38 |
rmdir $targetdir; |