mariadb/mysql-test/suite/mariabackup
sysprg 41f4f6bea8 MDEV-18565: Galera mtr-suite fails if galera library is not installed (#1243)
* MDEV-18565: Galera mtr-suite fails if galera library is not installed

Currently, running mtr with an incorrect (for example, new or
obsolete) version of wsrep_provider (for example, with the 26
version of libgalera_smm.so) leads to the failure of tests in
several suites with vague error diagnostics.

As for the galera_3nodes suite, the mtr also does not effectively
check all the prerequisites after merge with MDEV-18426 fixes.
For example, tests that using mariabackup do not check for presence
of ss and socat/nc. This is due to improper handling of relative
paths in mtr scripts.

In addition, some tests in different suites can be run without
setting the environment variables such as MTR_GALERA_TFMT, XBSTREAM,
and so on.

To eliminate all these issues, this patch makes the following changes:

1. Added auxiliary wsrep_mtr_check utility (which located in the
mysql-test/lib/My/SafeProcess subdirectory), which compares the
versions of the wsrep API that used by the server and by the wsrep
provider library, and it does this comparison safely, without
accessing the API if the versions do not match.

2. All checks related to the presence of mariabackup and utilities
that necessary for its operation transferred from the local directories
of different mtr suites (from the suite.pm files) to the main suite.pm
file. This not only reduces the amount of code and eliminates duplication
of identical code fragments, but also avoids problems due to the inability
of mtr to consider relative paths to include files when checking skip
combinations.

3. Setting the values of auxiliary environment variables that
are necessary for Galera, SST scripts and mariabackup (to work
properly) is moved to the main mysql-test-run.pl script, so as
not to duplicate this code in different suites, and to avoid
partial corrections of the same errors for different suites
(while other suites remain uncorrected).

4. Fixed duplication of the have_file_key_management.inc and
have_filekeymanagement.inc files between different suites,
these checks are also transferred to the top level.

https://jira.mariadb.org/browse/MDEV-18565

* Build without additional utility in configurations without wsrep support
2019-07-09 09:25:44 +03:00
..
include MDEV-18565: Galera mtr-suite fails if galera library is not installed (#1243) 2019-07-09 09:25:44 +03:00
absolute_ibdata_paths.opt Merge 10.1 into 10.2 2019-03-26 14:17:19 +02:00
absolute_ibdata_paths.result MDEV-15780 : Mariabackup with absolute paths in innodb_data_file_path 2018-04-12 11:15:27 +01:00
absolute_ibdata_paths.test MDEV-12711 mariabackup --backup is refused for multi-file system tablespace 2019-03-26 13:51:15 +02:00
apply-log-only-incr.result MDEV-15143 InnoDB: Rollback of trx with id 0 completed 2018-01-31 12:06:46 +02:00
apply-log-only-incr.test MDEV-16496 Mariabackup: Implement --verbose option to instrument InnoDB log apply 2018-06-15 16:14:12 +03:00
apply-log-only.result MDEV-15143 InnoDB: Rollback of trx with id 0 completed 2018-01-31 12:06:46 +02:00
apply-log-only.test MDEV-15143 InnoDB: Rollback of trx with id 0 completed 2018-01-31 12:06:46 +02:00
auth_plugin_win.opt fix auth_plugin_win test 2017-08-22 13:05:56 +00:00
auth_plugin_win.result MDEV-13608 : set client plugin directory with mysql_options() 2017-08-21 17:16:12 +00:00
auth_plugin_win.test MDEV-13608 : set client plugin directory with mysql_options() 2017-08-21 17:16:12 +00:00
backup_grants.result MDEV-18544 "missing required privilege PROCESS on *.*" using mariabackup for SST 2019-05-02 14:25:24 +01:00
backup_grants.test MDEV-18544 "missing required privilege PROCESS on *.*" using mariabackup for SST 2019-05-02 14:25:24 +01:00
backup_ssl.result MDEV-16105: Mariabackup does not support SSL 2018-05-08 19:52:08 +00:00
backup_ssl.test MDEV-16105: Mariabackup does not support SSL 2018-05-08 19:52:08 +00:00
binlog.result MDEV-15158 On commit, do not write to the TRX_SYS page 2018-02-20 21:36:36 +02:00
binlog.test MDEV-15158 On commit, do not write to the TRX_SYS page 2018-02-20 21:36:36 +02:00
compress_qpress.result Fixed wrong result file that happend because of a previous merge 2018-08-31 14:26:07 +03:00
compress_qpress.test MDEV-14102 restore --remove-original options for mariabackup 2017-10-23 10:30:17 +00:00
create_during_backup.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
create_during_backup.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
create_with_data_directory_during_backup.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
create_with_data_directory_during_backup.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
data_directory.result MDEV-12108 Fix backup for Innodb tables with DATA DIRECTORY 2017-11-06 19:21:23 +00:00
data_directory.test MDEV-12108 Fix backup for Innodb tables with DATA DIRECTORY 2017-11-06 19:21:23 +00:00
drop_table_during_backup.result MDEV-18185 - mariabackup - fix specific case of table rename handing in prepare. 2019-01-09 22:28:31 +01:00
drop_table_during_backup.test MDEV-18185 - mariabackup - fix specific case of table rename handing in prepare. 2019-01-09 22:28:31 +01:00
encrypted_page_compressed.opt MDEV-18025 Mariabackup fails to detect corrupted page_compressed=1 tables 2018-12-18 18:07:17 +05:30
encrypted_page_compressed.result Merge branch '10.2' into 10.3 2019-01-03 13:09:41 +01:00
encrypted_page_compressed.test MDEV-18663 Tests : use --core-file if mariabackup output is redirected to a file 2019-02-20 13:26:48 +01:00
encrypted_page_corruption.opt MDEV-12112 corruption in encrypted table may be overlooked 2018-12-14 15:44:51 +02:00
encrypted_page_corruption.result Merge branch '10.2' into 10.3 2019-01-03 13:09:41 +01:00
encrypted_page_corruption.test MDEV-18663 Tests : use --core-file if mariabackup output is redirected to a file 2019-02-20 13:26:48 +01:00
extra_lsndir.result MDEV-15071 backup does not store xtrabackup_info in the --extra-lsndir directory 2018-02-15 21:08:18 +00:00
extra_lsndir.test MDEV-15071 backup does not store xtrabackup_info in the --extra-lsndir directory 2018-02-15 21:08:18 +00:00
filekeys-data.enc MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
filekeys-data.key MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
full_backup.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
full_backup.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
huge_lsn.opt MDEV-18105 Mariabackup fails to copy encrypted InnoDB system tablespace if LSN>4G 2018-12-29 22:59:20 +02:00
huge_lsn.result Merge 10.1 into 10.2 2018-01-08 17:21:23 +02:00
huge_lsn.test Fix tests for innodb_checksum_algorithm=strict_crc32 2019-02-16 12:06:52 +02:00
incremental_backup.result Merge 10.1 into 10.2 2017-11-09 14:45:39 +02:00
incremental_backup.test Merge 10.1 into 10.2 2017-11-09 14:45:39 +02:00
incremental_ddl_before_backup.result MDEV-18194 Incremental prepare tries to access page which is out of tablespace bounds 2019-02-01 09:15:53 +02:00
incremental_ddl_before_backup.test MDEV-18194 Incremental prepare tries to access page which is out of tablespace bounds 2019-02-01 09:15:53 +02:00
incremental_ddl_during_backup.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
incremental_ddl_during_backup.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
incremental_encrypted.opt MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
incremental_encrypted.result MDEV-14188 mariabackup.incremental_encrypted wrong result 2018-07-06 09:07:52 +03:00
incremental_encrypted.test MDEV-14188 mariabackup.incremental_encrypted wrong result 2018-07-06 09:07:52 +03:00
incremental_rocksdb.opt MDEV-18204 Fix rocksdb incremental backup 2019-02-18 18:59:05 +01:00
incremental_rocksdb.result MDEV-18204 Fix rocksdb incremental backup 2019-02-18 18:59:05 +01:00
incremental_rocksdb.test MDEV-18204 Fix rocksdb incremental backup 2019-02-18 18:59:05 +01:00
innodb_log_optimize_ddl.result MDEV-16809 Allow full redo logging for ALTER TABLE 2018-07-26 08:44:42 +03:00
innodb_log_optimize_ddl.test MDEV-16809 Allow full redo logging for ALTER TABLE 2018-07-26 08:44:42 +03:00
lock_ddl_per_table.opt Allow tests to work with cmake -DPLUGIN_PARTITION=NO 2018-05-29 17:14:34 +03:00
lock_ddl_per_table.result add updated result file for MDEV-13802 test. 2017-09-15 20:44:03 +00:00
lock_ddl_per_table.test Allow tests to work with cmake -DPLUGIN_PARTITION=NO 2018-05-29 17:14:34 +03:00
log_checksum_mismatch.result MDEV-14536 : during backup, retry read of log blocks, if there is 2017-11-30 16:30:40 +00:00
log_checksum_mismatch.test MDEV-18663 Tests : use --core-file if mariabackup output is redirected to a file 2019-02-20 13:26:48 +01:00
mdev-14447.opt MDEV-14447 mariabackup incremental incorrectly extends system tablespace 2017-11-24 00:01:29 +00:00
mdev-14447.result MDEV-18415 mariabackup.mdev-14447 test case fails with Table 'test.t' doesn't exist in engine 2019-02-01 08:53:50 +02:00
mdev-14447.test Speed up buildbot by requiring --big-test for some slow tests 2019-05-29 08:28:15 +03:00
missing_ibd.result MDEV-19886 InnoDB returns misleading ER_NO_SUCH_TABLE_IN_ENGINE 2019-06-27 15:39:04 +03:00
missing_ibd.test MDEV-19886 InnoDB returns misleading ER_NO_SUCH_TABLE_IN_ENGINE 2019-06-27 15:39:04 +03:00
mlog_index_load.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
mlog_index_load.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
nolock_ddl_during_backup_end.result MDEV-17192 Backup with -no-lock should fail, if DDL is detected at the end of backup 2018-09-14 09:36:02 +01:00
nolock_ddl_during_backup_end.test MDEV-17192 Backup with -no-lock should fail, if DDL is detected at the end of backup 2018-09-14 09:36:02 +01:00
page_compression_level.result Merge 10.1 into 10.2 2019-03-08 20:45:45 +02:00
page_compression_level.test MDEV-18855 Mariabackup should fetch innodb_compression_level from running server 2019-03-08 16:00:08 +05:30
partial.result MDEV-13466 Implement --export option for MariaDB Backup 2017-09-07 22:54:06 +00:00
partial.test MDEV-13466 Implement --export option for MariaDB Backup 2017-09-07 22:54:06 +00:00
partial_exclude.result Xtrabackup 2.3.8 2017-04-27 19:12:42 +02:00
partial_exclude.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
partition_datadir.result Fix test case 2017-11-06 21:01:21 +00:00
partition_datadir.test Allow tests to work with cmake -DPLUGIN_PARTITION=NO 2018-05-29 17:14:34 +03:00
partition_partial.opt Add forgotten .opt file. 2018-12-21 19:45:30 +01:00
partition_partial.result Add test for partial backup for partitioned table. 2018-12-21 16:04:16 +01:00
partition_partial.test Add test for partial backup for partitioned table. 2018-12-21 16:04:16 +01:00
recreate_table_during_backup.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
recreate_table_during_backup.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
rename_during_backup.result MDEV-18201 : mariabackup- fix processing of rename/create sequence in prepare 2019-01-10 19:35:45 +01:00
rename_during_backup.test MDEV-18201 : mariabackup- fix processing of rename/create sequence in prepare 2019-01-10 19:35:45 +01:00
rename_during_mdl_lock.result MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
rename_during_mdl_lock.test MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
skip_innodb.opt MDEV-17149 mariabackup hangs if innodb is not started 2018-09-06 15:31:29 +01:00
skip_innodb.result MDEV-17149 mariabackup hangs if innodb is not started 2018-09-06 15:31:29 +01:00
skip_innodb.test MDEV-17149 mariabackup hangs if innodb is not started 2018-09-06 15:31:29 +01:00
small_ibd.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
small_ibd.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
suite.opt MDEV-16791 mariabackup : Support DDL commands during backup 2018-08-14 15:11:13 +01:00
suite.pm MDEV-18565: Galera mtr-suite fails if galera library is not installed (#1243) 2019-07-09 09:25:44 +03:00
system_versioning.result remove "Transaction-based system versioning is EXPERIMENTAL" warning 2018-01-13 02:01:34 +01:00
system_versioning.test remove "Transaction-based system versioning is EXPERIMENTAL" warning 2018-01-13 02:01:34 +01:00
truncate_during_backup.result MDEV-13564: Refuse MLOG_TRUNCATE in mariabackup 2018-08-16 16:10:18 +03:00
truncate_during_backup.test MDEV-13564 Mariabackup does not work with TRUNCATE 2018-09-07 22:10:02 +03:00
undo_space_id.opt Merge branch '10.2' into 10.3 2018-09-28 16:37:06 +02:00
undo_space_id.result MDEV-13561 Mariabackup is incompatible with retroactively created innodb_undo_tablespaces 2018-03-22 14:19:16 +05:30
undo_space_id.test MDEV-13561 Mariabackup is incompatible with retroactively created innodb_undo_tablespaces 2018-03-22 14:19:16 +05:30
unencrypted_page_compressed.result Merge 10.2 into 10.3 2019-04-04 19:41:12 +03:00
unencrypted_page_compressed.test MDEV-18663 Tests : use --core-file if mariabackup output is redirected to a file 2019-02-20 13:26:48 +01:00
unsupported_redo.result Re-enable the test mariabackup.unsupported_redo 2018-08-16 16:09:51 +03:00
unsupported_redo.test Re-enable the test mariabackup.unsupported_redo 2018-08-16 16:09:51 +03:00
xb_aws_key_management.opt AWS Key Management : Introduce "mock" variable, available in debug build. 2017-08-28 18:28:07 +00:00
xb_aws_key_management.result Fix test result. 2018-11-15 18:03:30 +01:00
xb_aws_key_management.test Tests : Fix result file 2018-02-01 12:50:58 +00:00
xb_compressed_encrypted.opt Remove deprecated InnoDB file format parameters 2017-06-02 09:36:14 +03:00
xb_compressed_encrypted.result Reduce a test so that it fails less frequently on buildbot 2017-07-06 23:14:39 +03:00
xb_compressed_encrypted.test Reduce a test so that it fails less frequently on buildbot 2017-07-06 23:14:39 +03:00
xb_file_key_management.opt MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_file_key_management.result MDEV-13311 Presence of old logs in 10.2.7 will corrupt restored instance (change in behavior) 2017-10-10 15:54:11 +03:00
xb_file_key_management.test MDEV-13311 Presence of old logs in 10.2.7 will corrupt restored instance (change in behavior) 2017-10-10 15:54:11 +03:00
xb_fulltext_encrypted.opt MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_fulltext_encrypted.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_fulltext_encrypted.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
xb_history.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_history.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
xb_page_compress.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_page_compress.test MDEV-13466 Implement --export option for MariaDB Backup 2017-09-07 22:54:06 +00:00
xb_partition.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xb_partition.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
xb_rocksdb.opt MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb.result MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb.test MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir.opt MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir.result MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir.test MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir_debug.opt MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir_debug.result MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb_datadir_debug.test MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xbstream.result MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
xbstream.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00