mirror of
https://github.com/MariaDB/server.git
synced 2025-02-09 23:24:11 +01:00
![Kristian Nielsen](/assets/img/avatar_default.png)
The problem is that these tests run optimistic parallel replication with non-transactional mysql.gtid_slave_pos table. Very occasionally InnoDB stats update may race with one another and cause a parallel replication deadlock kill after the mysql.gtid_slave_pos table has been updated. Since mysql.gtid_slave_pos is non-transactional, the update cannot be rolled back, and transaction retry will fail with a duplicate key error in mysql.gtid_slave_pos. Fixed by altering the storage engine to InnoDB for the table. Signed-off-by: Kristian Nielsen <knielsen@knielsen-hq.org>
34 lines
931 B
Text
34 lines
931 B
Text
#
|
|
# Start Alter with Legacy Replication
|
|
#
|
|
--source include/have_innodb.inc
|
|
--source include/have_debug.inc
|
|
--source include/master-slave.inc
|
|
|
|
--connection master
|
|
ALTER TABLE mysql.gtid_slave_pos ENGINE=InnoDB;
|
|
--let $binlog_alter_two_phase= `select @@binlog_alter_two_phase`
|
|
set global binlog_alter_two_phase = ON;
|
|
set binlog_alter_two_phase = ON;
|
|
--connection slave
|
|
--let $gtid_strict_mode= `select @@gtid_strict_mode`
|
|
set global gtid_strict_mode=1;
|
|
|
|
--echo # Legacy Master Slave
|
|
--let $domain_1=0
|
|
--let $domain_2=0
|
|
--let $M_port= $MASTER_MYPORT
|
|
--let $S_port= $SLAVE_MYPORT
|
|
--let $sync_slave=1
|
|
|
|
--source include/start_alter_include.inc
|
|
--connection master
|
|
--source include/save_master_gtid.inc
|
|
|
|
--connection slave
|
|
--source include/sync_with_master_gtid.inc
|
|
--eval set global gtid_strict_mode = $gtid_strict_mode;
|
|
|
|
--connection master
|
|
--eval set global binlog_alter_two_phase=$binlog_alter_two_phase;
|
|
--source include/rpl_end.inc
|