summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/mariabackup/options_check.test
blob: 022bcbd5d1017f745f3010f3ae2f5f75207c82b1 (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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
--let $targetdir=$MYSQLTEST_VARDIR/tmp/backup
--let $custom_cnf=$MYSQLTEST_VARDIR/tmp/custom_my.cnf

--echo # Check for unknown options in command-line
--disable_result_log
--error 7
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --unknown-option=xxx --target-dir=$targetdir;
--error 2
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --unknown-option --target-dir=$targetdir;

--echo # Check for unknown options in "mariabackup" group
--write_file $custom_cnf
[mariabackup]
unknown-option=XXX
EOF
--error 7
exec $XTRABACKUP --defaults-file=$custom_cnf --backup --target-dir=$targetdir;
--remove_file $custom_cnf

--echo # Check for unknown options in "xtrabackup" group
--write_file $custom_cnf
[xtrabackup]
unknown-option=XXX
EOF
--error 7
exec $XTRABACKUP --defaults-file=$custom_cnf --backup --target-dir=$targetdir;
--remove_file $custom_cnf

--echo # Check for unknown options in "mariadb-backup" group
--write_file $custom_cnf
[mariadb-backup]
unknown-option=XXX
EOF
--error 7
exec $XTRABACKUP --defaults-file=$custom_cnf --backup --target-dir=$targetdir;
--remove_file $custom_cnf

--echo # Check for options overwriting
--write_file $custom_cnf
[mariadbd]
innodb-flush-method=O_DIRECT

[mariabackup]
innodb-flush-method=blablabla
EOF
--error 13
exec $XTRABACKUP --defaults-file=$custom_cnf --backup --target-dir=$targetdir;
--remove_file $custom_cnf

--echo # Check if uknown options that follow --mysqld-args are ingored
exec $XTRABACKUP --defaults-file=$MYSQLTEST_VARDIR/my.cnf --backup --target-dir=$targetdir --mysqld-args --unknown-option;
--rmdir $targetdir

--echo # Check if [mariadb-client] group is not loaded (MDEV-22894)
--copy_file $MYSQLTEST_VARDIR/my.cnf $custom_cnf
--append_file $custom_cnf
[mariadb-client]
user=bla
password=bla
EOF
exec $XTRABACKUP --defaults-file=$custom_cnf --backup --target-dir=$targetdir;
--remove_file $custom_cnf
--rmdir $targetdir

--echo # Check if --help presents
exec $XTRABACKUP --help;
exec $XTRABACKUP -?;
--enable_result_log