1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

fixes for galera_as_slave replication tests

This commit is contained in:
Julius Goryavsky
2025-01-24 19:31:00 +01:00
parent e53ffdee96
commit acf7b000ff
14 changed files with 19 additions and 18 deletions

View File

@@ -94,3 +94,6 @@ DROP TABLE t1;
connection node_3; connection node_3;
DROP TABLE t1; DROP TABLE t1;
RESET MASTER; RESET MASTER;
connection node_1;
disconnect node_2a;
disconnect node_3;

View File

@@ -37,7 +37,7 @@ while ($counter) {
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--disable_result_log --disable_result_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3;
START SLAVE; START SLAVE;
--eval SELECT MASTER_GTID_WAIT('$gtid', 600) --eval SELECT MASTER_GTID_WAIT('$gtid', 600)
--enable_result_log --enable_result_log

View File

@@ -4,7 +4,7 @@
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3, MASTER_USE_GTID=slave_pos; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3, MASTER_USE_GTID=slave_pos;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;

View File

@@ -9,7 +9,7 @@
--connect node_3, 127.0.0.1, root, , test, $NODE_MYPORT_3 --connect node_3, 127.0.0.1, root, , test, $NODE_MYPORT_3
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_1; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_1;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;

View File

@@ -13,7 +13,7 @@
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;

View File

@@ -13,7 +13,7 @@
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;

View File

@@ -16,7 +16,7 @@ SELECT @@wsrep_on;
--connection node_1 --connection node_1
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;

View File

@@ -15,7 +15,6 @@
# we open the node_4 connection here # we open the node_4 connection here
--connect node_4, 127.0.0.1, root, , test, $NODE_MYPORT_4 --connect node_4, 127.0.0.1, root, , test, $NODE_MYPORT_4
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$NODE_MYPORT_4, MASTER_USER='root'; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$NODE_MYPORT_4, MASTER_USER='root';

View File

@@ -38,7 +38,6 @@ SET debug_sync = 'now SIGNAL signal.wsrep_retry_event_group';
--let $wait_condition = SELECT COUNT(*) = 1 FROM t1; --let $wait_condition = SELECT COUNT(*) = 1 FROM t1;
--source include/wait_condition.inc --source include/wait_condition.inc
--connection node_1 --connection node_1
SET debug_sync = 'RESET'; SET debug_sync = 'RESET';

View File

@@ -10,4 +10,3 @@ wsrep-debug=1
[mysqld.2] [mysqld.2]
wsrep_restart_slave=1 wsrep_restart_slave=1
wsrep-debug=1 wsrep-debug=1

View File

@@ -16,7 +16,6 @@
--connection node_2a --connection node_2a
--source include/galera_cluster.inc --source include/galera_cluster.inc
#--source suite/galera/include/galera_have_debug_sync.inc
ALTER TABLE mysql.gtid_slave_pos ENGINE=InnoDB; ALTER TABLE mysql.gtid_slave_pos ENGINE=InnoDB;
@@ -33,12 +32,11 @@ RESET MASTER;
# #
--let $wsrep_local_replays_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_replays'` --let $wsrep_local_replays_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_replays'`
# #
# nodes 1 and 2 form a galera cluster, node 2 operates as slave for native MariaDB naster in node 3 # nodes 1 and 2 form a galera cluster, node 2 operates as slave for native MariaDB master in node 3
# #
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;
@@ -81,7 +79,7 @@ SET SESSION wsrep_sync_wait = 0;
SET GLOBAL debug_dbug = "d,sync.wsrep_apply_cb"; SET GLOBAL debug_dbug = "d,sync.wsrep_apply_cb";
# #
# now inject a conflicting insert from node 3, it will replicate with # now inject a conflicting insert from node 1, it will replicate with
# earlier seqno (than async transaction) and pause before applying in node 2 # earlier seqno (than async transaction) and pause before applying in node 2
# #
--connection node_1 --connection node_1

View File

@@ -16,7 +16,7 @@
--echo #Connection 2 --echo #Connection 2
--connection node_2 --connection node_2
--disable_query_log --disable_query_log
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3,master_use_gtid=slave_pos; --eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3, master_use_gtid=slave_pos;
--enable_query_log --enable_query_log
START SLAVE; START SLAVE;
--sleep 1 --sleep 1

View File

@@ -29,7 +29,7 @@ call mtr.add_suppression("WSREP: Ignoring server id .* for non bootstrap node");
--connection node_3 --connection node_3
--replace_result $NODE_MYPORT_1 NODE_MYPORT_1 --replace_result $NODE_MYPORT_1 NODE_MYPORT_1
--eval CHANGE MASTER TO master_host='127.0.0.1', master_user='root', master_port=$NODE_MYPORT_1, master_use_gtid=current_pos; --eval CHANGE MASTER TO master_host='127.0.0.1', master_user='root', MASTER_PORT=$NODE_MYPORT_1, master_use_gtid=current_pos
START SLAVE; START SLAVE;
--source include/wait_for_slave_to_start.inc --source include/wait_for_slave_to_start.inc

View File

@@ -32,7 +32,6 @@ RESET MASTER;
# #
--let $wsrep_local_replays_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_replays'` --let $wsrep_local_replays_old = `SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_replays'`
# #
# nodes 1 and 2 form a galera cluster, node 2 operates as slave for native MariaDB master in node 3 # nodes 1 and 2 form a galera cluster, node 2 operates as slave for native MariaDB master in node 3
# #
@@ -134,7 +133,7 @@ SELECT * FROM t1;
SET DEBUG_SYNC = "RESET"; SET DEBUG_SYNC = "RESET";
#******************************************************************************** #********************************************************************************
# test phase 2 # test phase 2
#******************************************************************************** #********************************************************************************
--echo # --echo #
@@ -197,3 +196,7 @@ DROP TABLE t1;
--connection node_3 --connection node_3
DROP TABLE t1; DROP TABLE t1;
RESET MASTER; RESET MASTER;
--connection node_1
--disconnect node_2a
--disconnect node_3