mariadb/mysql-test/suite/mariabackup
Sujatha 6c39eaeb12 MDEV-21117: refine the server binlog-based recovery for semisync
Problem:
=======
When the semisync master is crashed and restarted as slave it could
recover transactions that former slaves may never have seen.
A known method existed to clear out all prepared transactions
with --tc-heuristic-recover=rollback does not care to adjust
binlog accordingly.

Fix:
===
The binlog-based recovery is made to concern of the slave semisync role of
post-crash restarted server.
No changes in behavior is done to the "normal" binloggging server
and the semisync master.

When the restarted server is configured with
  --rpl-semi-sync-slave-enabled=1
the refined recovery attempts to roll back prepared transactions
and truncate binlog accordingly.
In case of a partially committed (that is committed at least
in one of the engine participants) such transaction gets committed.
It's guaranteed no (partially as well) committed transactions
exist beyond the truncate position.
In case there exists a non-transactional replication event
(being in a way a committed transaction) past the
computed truncate position the recovery ends with an error.

As after master crash and failover to slave, the demoted-to-slave
ex-master must be ready to face and accept its own (generated by)
events, without generally necessary --replicate-same-server-id.
So the acceptance conditions are relaxed for the semisync slave
to accept own events without that option.
While gtid_strict_mode ON ensures no duplicate transaction can be
(re-)executed the master_use_gtid=none slave has to be
configured with --replicate-same-server-id.

*NOTE* for reviewers.

This patch does not handle the user XA which is done
in next git commit.
2021-06-11 19:49:39 +03:00
..
include MDEV-21117: refine the server binlog-based recovery for semisync 2021-06-11 19:49:39 +03:00
absolute_ibdata_paths.opt MDEV-19534 Make innodb_checksum_algorithm=full_crc32 by default, and remove innodb_checksums 2019-05-22 08:53:28 +03:00
absolute_ibdata_paths.result Write information about restart in .result 2019-04-01 19:47:24 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
apply-log-only-incr.test MDEV-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +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-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +03: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_lock_wait_timeout.result MDEV-20230: mariabackup --ftwrl-wait-timeout never times out on explicit 2020-04-27 22:10:50 +03:00
backup_lock_wait_timeout.test MDEV-20230: mariabackup --ftwrl-wait-timeout never times out on explicit 2020-04-27 22:10:50 +03:00
backup_ssl.result Write information about restart in .result 2019-04-01 19:47:24 +03:00
backup_ssl.test MDEV-16105: Mariabackup does not support SSL 2018-05-08 19:52:08 +00:00
big_innodb_log.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
big_innodb_log.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03: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-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +03:00
compress_qpress.result Fix compress_qpress result file, broken in b5615eff0d 2019-08-27 20:46:05 +02:00
compress_qpress.test MDEV-14102 restore --remove-original options for mariabackup 2017-10-23 10:30:17 +00:00
create_during_backup.result Write information about restart in .result 2019-04-01 19:47:24 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
data_directory.test MDEV-12108 Fix backup for Innodb tables with DATA DIRECTORY 2017-11-06 19:21:23 +00:00
deadlock_drop_table.result Fixed hang in concurrent DROP TABLE and BACKUP LOCK BLOCK_DDL 2021-05-19 22:54:14 +02:00
deadlock_drop_table.test Fixed hang in concurrent DROP TABLE and BACKUP LOCK BLOCK_DDL 2021-05-19 22:54:14 +02:00
drop_table_during_backup.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
drop_table_during_backup.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
encrypted_page_compressed.test MDEV-18644: Support full_crc32 for page_compressed 2019-03-18 14:08:43 +02:00
encrypted_page_corruption,full_crc32.rdiff MDEV-12112/MDEV-12026: Enable the test for full_crc32 2019-09-10 12:43:48 +03:00
encrypted_page_corruption.combinations MDEV-12112/MDEV-12026: Enable the test for full_crc32 2019-09-10 12:43:48 +03:00
encrypted_page_corruption.opt MDEV-12112/MDEV-12026: Enable the test for full_crc32 2019-09-10 12:43:48 +03:00
encrypted_page_corruption.result Write information about restart in .result 2019-04-01 19:47:24 +03:00
encrypted_page_corruption.test MDEV-12112/MDEV-12026: Enable the test for full_crc32 2019-09-10 12:43:48 +03:00
error_during_copyback.result Merge 10.3 into 10.4 2021-04-14 10:33:59 +03:00
error_during_copyback.test MDEV-25221 Do not remove source file, if copy_file() fails in mariabackup --move-back 2021-03-31 14:23:56 +02: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
extra_lsndir_stream.result MDEV-18438 Don't stream xtrabackup_info of extra-lsndir 2019-09-19 17:47:54 +03:00
extra_lsndir_stream.test MDEV-18438 Don't stream xtrabackup_info of extra-lsndir 2019-09-19 17:47:54 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
full_backup.test MDEV-12548 Initial implementation of Mariabackup for MariaDB 10.2 2017-07-05 11:43:28 +03:00
huge_lsn.combinations MDEV-12026: Implement innodb_checksum_algorithm=full_crc32 2019-02-19 18:50:19 +02: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.4 into 10.5 2020-07-15 14:51:22 +03:00
huge_lsn.test Merge 10.4 into 10.5 2020-07-15 14:51:22 +03:00
incremental_backup.result MDEV-515 Reduce InnoDB undo logging for insert into empty table 2021-01-25 18:41:27 +02:00
incremental_backup.test MDEV-515 Reduce InnoDB undo logging for insert into empty table 2021-01-25 18:41:27 +02:00
incremental_ddl_before_backup.result Write information about restart in .result 2019-04-01 19:47:24 +03:00
incremental_ddl_before_backup.test MDEV-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +03:00
incremental_ddl_during_backup.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
incremental_ddl_during_backup.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
incremental_encrypted.opt MDEV-9566 MariaBackup test suite 2017-04-27 19:12:40 +02:00
incremental_encrypted.result Write information about restart in .result 2019-04-01 19:47:24 +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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
incremental_rocksdb.test MDEV-18204 Fix rocksdb incremental backup 2019-02-18 18:59:05 +01:00
innodb_force_recovery.result Merge 10.3 into 10.4 2021-04-14 10:33:59 +03:00
innodb_force_recovery.test MDEV-24197: Add "innodb_force_recovery" for "mariabackup --prepare" 2021-04-01 13:34:40 +03:00
innodb_redo_log_overwrite.opt MDEV-14425 deprecate and ignore innodb_log_files_in_group 2020-02-19 12:21:59 +03:00
innodb_redo_log_overwrite.result MDEV-21255: Deadlock of parallel slave and mariabackup (with failed log 2019-12-12 13:28:30 +03:00
innodb_redo_log_overwrite.test MDEV-21255: Deadlock of parallel slave and mariabackup (with failed log 2019-12-12 13:28:30 +03:00
innodb_redo_overwrite.opt Merge 10.4 into 10.5 2020-09-23 11:32:43 +03:00
innodb_redo_overwrite.result Merge 10.4 into 10.5 2020-09-23 11:32:43 +03:00
innodb_redo_overwrite.test Merge 10.4 into 10.5 2020-09-23 11:32:43 +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 MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
lock_ddl_per_table.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
log_checksum_mismatch.result Write information about restart in .result 2019-04-01 19:47:24 +03: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
log_page_corruption.opt MDEV-22929 MariaBackup option to report and/or continue when corruption is encountered 2020-12-01 08:08:57 +03:00
log_page_corruption.result Merge 10.3 into 10.4 2021-03-08 09:39:54 +02:00
log_page_corruption.test MDEV-22929 fixup. Print "completed OK!" if page corruption and --log-innodb-page-corruption 2021-03-05 09:04:30 +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-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
mdev-14447.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
mdev-18438.result MDEV-18438 Don't stream xtrabackup_info of extra-lsndir 2019-09-19 17:47:54 +03:00
mdev-18438.test MDEV-18438 Don't stream xtrabackup_info of extra-lsndir 2019-09-19 17:47:54 +03:00
missing_ibd.result Merge 10.3 into 10.4 2019-07-02 21:44:58 +03:00
missing_ibd.test MDEV-25743: Unnecessary copying of table names in InnoDB dictionary 2021-05-21 18:03:40 +03: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
options_check.result MDEV-22983: Mariabackup's --help option disappeared 2020-07-01 23:30:44 +03:00
options_check.test MDEV-22983: Mariabackup's --help option disappeared 2020-07-01 23:30:44 +03: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-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
partial.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
partial_exclude.opt MDEV-19347: Mariabackup does not honor ignore_db_dirs from server 2020-04-21 10:34:37 +03:00
partial_exclude.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
partial_exclude.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
partition_datadir.result Write information about restart in .result 2019-04-01 19:47:24 +03: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-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
recreate_table_during_backup.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
rename_during_backup.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
rename_during_backup.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
rename_during_mdl_lock.result MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
rename_during_mdl_lock.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
row_format_redundant.result MDEV-24848 Assertion rlen<llen failed when applying MEMSET 2021-02-17 16:18:55 +02:00
row_format_redundant.test MDEV-24848 Assertion rlen<llen failed when applying MEMSET 2021-02-17 16:18:55 +02:00
rpl_slave_info.result MDEV-19264 Better support MariaDB GTID for Mariabackup's --slave-info option 2020-09-14 11:14:50 +03:00
rpl_slave_info.test MDEV-19264 Better support MariaDB GTID for Mariabackup's --slave-info option 2020-09-14 11:14:50 +03:00
skip_innodb.opt MDEV-17149 mariabackup hangs if innodb is not started 2018-09-06 15:31:29 +01:00
skip_innodb.result Write information about restart in .result 2019-04-01 19:47:24 +03: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 2020-04-27 09:22:36 +02:00
system_versioning.result Write information about restart in .result 2019-04-01 19:47:24 +03: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-21216 InnoDB does dirty read of TRX_SYS page before recovery 2019-12-04 15:34:28 +02:00
undo_space_id.test Merge 10.4 into 10.5 2020-06-18 13:58:54 +03:00
unencrypted_page_compressed.result Merge 10.3 into 10.4 2019-04-05 11:41:03 +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 MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +03:00
unsupported_redo.test MDEV-24626 Remove synchronous write of page0 file during file creation 2021-05-17 18:12:33 +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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
xb_aws_key_management.test Tests : Fix result file 2018-02-01 12:50:58 +00:00
xb_compressed_encrypted.opt MDEV-24426 fil_crypt_thread keep spinning even if innodb_encryption_rotate_key_age=0 2020-12-17 13:46:21 +02:00
xb_compressed_encrypted.result Write information about restart in .result 2019-04-01 19:47:24 +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 Write information about restart in .result 2019-04-01 19:47:24 +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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
xb_fulltext_encrypted.test MDEV-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
xb_partition.test MDEV-18215: mariabackup does not report unknown command line options 2020-06-14 13:23:07 +03:00
xb_rocksdb.opt MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xb_rocksdb.result Write information about restart in .result 2019-04-01 19:47:24 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03: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 Write information about restart in .result 2019-04-01 19:47:24 +03:00
xb_rocksdb_datadir_debug.test MDEV-13122 Backup myrocksdb with mariabackup. 2018-06-07 15:13:54 +01:00
xbstream.result Write information about restart in .result 2019-04-01 19:47:24 +03:00
xbstream.test MDEV-25815 mariabackup crash or debug assert with --backup --databases-exclude 2021-05-29 06:32:40 +02:00