diff --git a/mysql-test/suite/galera/r/MDEV-34647.result b/mysql-test/suite/galera/r/MDEV-34647.result index 0333f14ece1..0bdab65d963 100644 --- a/mysql-test/suite/galera/r/MDEV-34647.result +++ b/mysql-test/suite/galera/r/MDEV-34647.result @@ -95,7 +95,6 @@ id val 4 d 5 d 6 d -set global wsrep_mode=default; connection node_1; drop table t1,t2,t3,t4,t5; set global wsrep_mode=default; diff --git a/mysql-test/suite/galera/r/galera_alter_engine_myisam.result b/mysql-test/suite/galera/r/galera_alter_engine_myisam.result index f29c83cad95..98a133c32bc 100644 --- a/mysql-test/suite/galera/r/galera_alter_engine_myisam.result +++ b/mysql-test/suite/galera/r/galera_alter_engine_myisam.result @@ -26,3 +26,4 @@ COUNT(*) = 1 1 DROP TABLE t1; connection node_1; +SET GLOBAL wsrep_mode = DEFAULT; diff --git a/mysql-test/suite/galera/r/galera_bf_abort_mariabackup.result b/mysql-test/suite/galera/r/galera_bf_abort_mariabackup.result index 88c200ee933..88e49c651db 100644 --- a/mysql-test/suite/galera/r/galera_bf_abort_mariabackup.result +++ b/mysql-test/suite/galera/r/galera_bf_abort_mariabackup.result @@ -51,7 +51,7 @@ FOUND 1 /Desyncing and pausing the provider/ in mysqld.2.err FOUND 1 /Resuming and resyncing the provider/ in mysqld.2.err # Should return FOUND 1 because only last backup does not desync FOUND 1 /Server not desynched from group because WSREP_MODE_BF_MARIABACKUP used./ in mysqld.2.err -SET GLOBAL wsrep_mode = ""; +SET GLOBAL wsrep_mode = DEFAULT; connection node_1; DROP TABLE t; disconnect node_2; diff --git a/mysql-test/suite/galera/r/galera_gcs_fragment.result b/mysql-test/suite/galera/r/galera_gcs_fragment.result index bdd749047ee..cac35a78f1c 100644 --- a/mysql-test/suite/galera/r/galera_gcs_fragment.result +++ b/mysql-test/suite/galera/r/galera_gcs_fragment.result @@ -22,7 +22,7 @@ INSERT INTO t1 VALUES (2, "bbbbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa connection node_1a; SET GLOBAL wsrep_provider_options = 'signal=gcs_core_after_frag_send'; connection node_1; -ERROR HY000: Got error 6 "No such device or address" during COMMIT +ERROR HY000: Error while appending streaming replication fragment(provider status: Not connected to Primary Component) INSERT INTO t1 VALUES (3, "cccccaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"); SELECT * FROM t1; f1 f2 diff --git a/mysql-test/suite/galera/r/galera_partitioned_tables.result b/mysql-test/suite/galera/r/galera_partitioned_tables.result index 3f24cae1495..b68c1786ff7 100644 --- a/mysql-test/suite/galera/r/galera_partitioned_tables.result +++ b/mysql-test/suite/galera/r/galera_partitioned_tables.result @@ -1,6 +1,6 @@ connection node_2; connection node_1; -call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled. Storage engine partition for table.*"); +call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled\\. Storage engine partition for table"); # wsrep-mode= DEFAULT SET GLOBAL wsrep_mode = ""; SELECT @@wsrep_mode; diff --git a/mysql-test/suite/galera/r/galera_strict_require_innodb.result b/mysql-test/suite/galera/r/galera_strict_require_innodb.result index cc243cd3813..47adc5e9285 100644 --- a/mysql-test/suite/galera/r/galera_strict_require_innodb.result +++ b/mysql-test/suite/galera/r/galera_strict_require_innodb.result @@ -1,6 +1,6 @@ connection node_2; connection node_1; -call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled. Storage engine .*"); +call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled\\. Storage engine "); CREATE TABLE t1(a int NOT NULL PRIMARY KEY, b varchar(50)) ENGINE=INNODB; CREATE TABLE t2(a int NOT NULL PRIMARY KEY, b varchar(50)) ENGINE=MYISAM; CREATE TABLE t3(a int NOT NULL PRIMARY KEY, b varchar(50)) ENGINE=ARIA; diff --git a/mysql-test/suite/galera/r/galera_strict_require_primary_key.result b/mysql-test/suite/galera/r/galera_strict_require_primary_key.result index 4a05f6405ed..ffdbb89170f 100644 --- a/mysql-test/suite/galera/r/galera_strict_require_primary_key.result +++ b/mysql-test/suite/galera/r/galera_strict_require_primary_key.result @@ -1,6 +1,6 @@ connection node_2; connection node_1; -call mtr.add_suppression("WSREP: wsrep_mode = REQUIRED_PRIMARY_KEY enabled. Table .*"); +call mtr.add_suppression("WSREP: wsrep_mode = REQUIRED_PRIMARY_KEY enabled\\. Table "); CREATE TABLE t1(a int, b varchar(50)) ENGINE=INNODB; CREATE TABLE t2(a int, b varchar(50)) ENGINE=MYISAM; CREATE TABLE t3(a int, b varchar(50)) ENGINE=MEMORY; diff --git a/mysql-test/suite/galera/r/mdev-30653.result b/mysql-test/suite/galera/r/mdev-30653.result index 43f525ceace..2a6099ae915 100644 --- a/mysql-test/suite/galera/r/mdev-30653.result +++ b/mysql-test/suite/galera/r/mdev-30653.result @@ -4,7 +4,7 @@ create table t1 (id serial, val int) engine=innodb; create table t2 (id serial, val int) engine=aria; insert into t1 values(1, 23); insert into t2 values(2, 42); -call mtr.add_suppression("WSREP: Replication of non-transactional engines is experimental. Storage engine Aria for table 'test'.'t2' is not supported in Galera"); +call mtr.add_suppression("WSREP: Replication of non-transactional engines is experimental\\. Storage engine Aria for table 'test'\\.'t2' is not supported in Galera"); begin; update t1 set val=24 where id=1; update t2 set val=41 where id=2; diff --git a/mysql-test/suite/galera/t/MDEV-33136.test b/mysql-test/suite/galera/t/MDEV-33136.test index 12765ef6dfb..4b484eb47da 100644 --- a/mysql-test/suite/galera/t/MDEV-33136.test +++ b/mysql-test/suite/galera/t/MDEV-33136.test @@ -10,6 +10,7 @@ # transaction in the MDL conflict handling code. --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_debug_sync.inc --source include/have_debug.inc diff --git a/mysql-test/suite/galera/t/MDEV-34647.test b/mysql-test/suite/galera/t/MDEV-34647.test index 41cd941df88..2cf4b627f76 100644 --- a/mysql-test/suite/galera/t/MDEV-34647.test +++ b/mysql-test/suite/galera/t/MDEV-34647.test @@ -45,7 +45,6 @@ select * from t2; select * from t3; select * from t4; select * from t5; -set global wsrep_mode=default; --connection node_1 drop table t1,t2,t3,t4,t5; diff --git a/mysql-test/suite/galera/t/binlog_checksum.test b/mysql-test/suite/galera/t/binlog_checksum.test index 8f6091235a1..5aab68a7746 100644 --- a/mysql-test/suite/galera/t/binlog_checksum.test +++ b/mysql-test/suite/galera/t/binlog_checksum.test @@ -1,4 +1,5 @@ --source include/galera_cluster.inc +--source include/have_innodb.inc --echo # On node_1 --connection node_1 diff --git a/mysql-test/suite/galera/t/galera_alter_engine_myisam.test b/mysql-test/suite/galera/t/galera_alter_engine_myisam.test index 57c057f9869..6f23abab6f3 100644 --- a/mysql-test/suite/galera/t/galera_alter_engine_myisam.test +++ b/mysql-test/suite/galera/t/galera_alter_engine_myisam.test @@ -1,4 +1,5 @@ --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_aria.inc # @@ -35,7 +36,4 @@ SELECT COUNT(*) = 1 FROM t1; DROP TABLE t1; --connection node_1 ---disable_query_log SET GLOBAL wsrep_mode = DEFAULT; ---enable_query_log - diff --git a/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.cnf b/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.cnf index 857a4101406..1e6bbcce82f 100644 --- a/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.cnf +++ b/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.cnf @@ -6,10 +6,10 @@ wsrep_sst_auth="root:" wsrep_debug=1 [mysqld.1] -wsrep_provider_options='base_port=@mysqld.1.#galera_port;gcache.size=1;pc.ignore_sb=true' +wsrep_provider_options='pc.ignore_sb=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=1' [mysqld.2] -wsrep_provider_options='base_port=@mysqld.2.#galera_port;gcache.size=1;pc.ignore_sb=true' +wsrep_provider_options='pc.ignore_sb=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=1' [sst] transferfmt=@ENV.MTR_GALERA_TFMT diff --git a/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.test b/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.test index 34c3f5d3621..90d674313bf 100644 --- a/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.test +++ b/mysql-test/suite/galera/t/galera_bf_abort_mariabackup.test @@ -126,7 +126,7 @@ let SEARCH_PATTERN = Resuming and resyncing the provider; let SEARCH_PATTERN = Server not desynched from group because WSREP_MODE_BF_MARIABACKUP used.; --source include/search_pattern_in_file.inc -SET GLOBAL wsrep_mode = ""; +SET GLOBAL wsrep_mode = DEFAULT; --connection node_1 DROP TABLE t; diff --git a/mysql-test/suite/galera/t/galera_bf_kill_debug.test b/mysql-test/suite/galera/t/galera_bf_kill_debug.test index a89bd1d06b2..ddf9522c12f 100644 --- a/mysql-test/suite/galera/t/galera_bf_kill_debug.test +++ b/mysql-test/suite/galera/t/galera_bf_kill_debug.test @@ -89,7 +89,7 @@ SET DEBUG_SYNC = "now SIGNAL continue_kill"; --reap --connection node_2a ---error 0,1213,2013 +--error 0,1213,2013,2026 select * from t1; --connection node_2b @@ -130,7 +130,7 @@ SET DEBUG_SYNC = "now WAIT_FOR bwoc_reached"; SET DEBUG_SYNC = "now SIGNAL bwoc_continue"; --connection node_2a ---error 0,1213 +--error 0,1213,2013,2026 --reap --connection node_2 diff --git a/mysql-test/suite/galera/t/galera_disallow_local_gtid.test b/mysql-test/suite/galera/t/galera_disallow_local_gtid.test index b28bab1f8cb..2867e9e050e 100644 --- a/mysql-test/suite/galera/t/galera_disallow_local_gtid.test +++ b/mysql-test/suite/galera/t/galera_disallow_local_gtid.test @@ -101,4 +101,3 @@ DROP TABLE tab; DROP TABLE tab1; DROP TABLE tab2; DROP TABLE tab3; - diff --git a/mysql-test/suite/galera/t/galera_partitioned_tables.test b/mysql-test/suite/galera/t/galera_partitioned_tables.test index f29adcf1501..8e52b59d97d 100644 --- a/mysql-test/suite/galera/t/galera_partitioned_tables.test +++ b/mysql-test/suite/galera/t/galera_partitioned_tables.test @@ -3,7 +3,7 @@ --source include/have_innodb.inc --source include/have_aria.inc -call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled. Storage engine partition for table.*"); +call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled\\. Storage engine partition for table"); --echo # wsrep-mode= DEFAULT SET GLOBAL wsrep_mode = ""; diff --git a/mysql-test/suite/galera/t/galera_strict_require_innodb.test b/mysql-test/suite/galera/t/galera_strict_require_innodb.test index b627fffe70c..6ca95432dbc 100644 --- a/mysql-test/suite/galera/t/galera_strict_require_innodb.test +++ b/mysql-test/suite/galera/t/galera_strict_require_innodb.test @@ -15,9 +15,10 @@ # In both cases apply flood control if >= 10 same warning # --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_aria.inc -call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled. Storage engine .*"); +call mtr.add_suppression("WSREP: wsrep_mode = STRICT_REPLICATION enabled\\. Storage engine "); CREATE TABLE t1(a int NOT NULL PRIMARY KEY, b varchar(50)) ENGINE=INNODB; CREATE TABLE t2(a int NOT NULL PRIMARY KEY, b varchar(50)) ENGINE=MYISAM; @@ -114,4 +115,3 @@ DROP TABLE t1,t2,t3,t4; SET GLOBAL log_warnings=DEFAULT; SET GLOBAL wsrep_mode=DEFAULT; --disable_query_log - diff --git a/mysql-test/suite/galera/t/galera_strict_require_primary_key.test b/mysql-test/suite/galera/t/galera_strict_require_primary_key.test index dc5f9910396..4733c2e2ef4 100644 --- a/mysql-test/suite/galera/t/galera_strict_require_primary_key.test +++ b/mysql-test/suite/galera/t/galera_strict_require_primary_key.test @@ -14,9 +14,10 @@ # In both cases apply flood control if >= 10 same warning # --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_aria.inc -call mtr.add_suppression("WSREP: wsrep_mode = REQUIRED_PRIMARY_KEY enabled. Table .*"); +call mtr.add_suppression("WSREP: wsrep_mode = REQUIRED_PRIMARY_KEY enabled\\. Table "); CREATE TABLE t1(a int, b varchar(50)) ENGINE=INNODB; CREATE TABLE t2(a int, b varchar(50)) ENGINE=MYISAM; @@ -140,4 +141,3 @@ DROP TABLE t1,t2,t3,t4; SET GLOBAL log_warnings=DEFAULT; SET GLOBAL wsrep_mode=DEFAULT; --disable_query_log - diff --git a/mysql-test/suite/galera/t/galera_var_auto_inc_control_off.test b/mysql-test/suite/galera/t/galera_var_auto_inc_control_off.test index c0bbe5af8cf..241b62dbf8c 100644 --- a/mysql-test/suite/galera/t/galera_var_auto_inc_control_off.test +++ b/mysql-test/suite/galera/t/galera_var_auto_inc_control_off.test @@ -94,11 +94,13 @@ SELECT * FROM t1; --eval SET GLOBAL wsrep_auto_increment_control = $auto_increment_control_orig --eval SET GLOBAL auto_increment_increment = $auto_increment_increment_node1 --eval SET GLOBAL auto_increment_offset = $auto_increment_offset_node1 +--disconnect node_1a --connection node_2 --eval SET GLOBAL wsrep_auto_increment_control = $auto_increment_control_orig --eval SET GLOBAL auto_increment_increment = $auto_increment_increment_node2 --eval SET GLOBAL auto_increment_offset = $auto_increment_offset_node2 +--disconnect node_2a --enable_query_log diff --git a/mysql-test/suite/galera/t/galera_var_replicate_aria_off.test b/mysql-test/suite/galera/t/galera_var_replicate_aria_off.test index c0d8c5d6b3b..6946bc552ea 100644 --- a/mysql-test/suite/galera/t/galera_var_replicate_aria_off.test +++ b/mysql-test/suite/galera/t/galera_var_replicate_aria_off.test @@ -3,7 +3,6 @@ # --source include/galera_cluster.inc ---source include/have_innodb.inc --source include/have_aria.inc CREATE TABLE t1 (f1 INT PRIMARY KEY) Engine=Aria; diff --git a/mysql-test/suite/galera/t/galera_var_replicate_aria_on.test b/mysql-test/suite/galera/t/galera_var_replicate_aria_on.test index ac9a79e6196..c4367642102 100644 --- a/mysql-test/suite/galera/t/galera_var_replicate_aria_on.test +++ b/mysql-test/suite/galera/t/galera_var_replicate_aria_on.test @@ -234,4 +234,3 @@ SET GLOBAL wsrep_mode = DEFAULT; --connection node_2 SET GLOBAL wsrep_mode = DEFAULT; --enable_query_log - diff --git a/mysql-test/suite/galera/t/galera_var_wsrep_mode.test b/mysql-test/suite/galera/t/galera_var_wsrep_mode.test index 002dce0a05a..fdb033b0874 100644 --- a/mysql-test/suite/galera/t/galera_var_wsrep_mode.test +++ b/mysql-test/suite/galera/t/galera_var_wsrep_mode.test @@ -57,9 +57,3 @@ SELECT @@wsrep_mode; # reset SET GLOBAL wsrep_mode=DEFAULT; - - - - - - diff --git a/mysql-test/suite/galera/t/galera_var_wsrep_strict_ddl.test b/mysql-test/suite/galera/t/galera_var_wsrep_strict_ddl.test index 2aa76d46f82..a2edf27c3dc 100644 --- a/mysql-test/suite/galera/t/galera_var_wsrep_strict_ddl.test +++ b/mysql-test/suite/galera/t/galera_var_wsrep_strict_ddl.test @@ -10,4 +10,3 @@ SELECT @@global.wsrep_strict_ddl; SET @@global.wsrep_strict_ddl=OFF; SELECT @@global.wsrep_mode; SELECT @@global.wsrep_strict_ddl; - diff --git a/mysql-test/suite/galera/t/galera_vote_rejoin_ddl.test b/mysql-test/suite/galera/t/galera_vote_rejoin_ddl.test index 58371061a5f..c868e5e8e5b 100644 --- a/mysql-test/suite/galera/t/galera_vote_rejoin_ddl.test +++ b/mysql-test/suite/galera/t/galera_vote_rejoin_ddl.test @@ -91,10 +91,6 @@ CALL mtr.add_suppression("WSREP: Vote 0 \\(success\\) on .* is inconsistent with DROP TABLE t2; ---let $node_3=node_3 ---let $auto_increment_offset_node_3 = 3; ---let $node_4=node_4 ---let $auto_increment_offset_node_4 = 4; --source suite/galera/include/auto_increment_offset_restore.inc --disconnect node_3 diff --git a/mysql-test/suite/galera/t/galera_wsrep_mode.test b/mysql-test/suite/galera/t/galera_wsrep_mode.test index a8e192123bd..d50018c1c4b 100644 --- a/mysql-test/suite/galera/t/galera_wsrep_mode.test +++ b/mysql-test/suite/galera/t/galera_wsrep_mode.test @@ -16,7 +16,6 @@ CREATE TABLE t1 (f1 INTEGER PRIMARY KEY) ENGINE=InnoDB; DROP TABLE t1; SET GLOBAL wsrep_mode = default; - # MDEV-25698 SIGSEGV in wsrep_should_replicate_ddl SET GLOBAL wsrep_mode = STRICT_REPLICATION; diff --git a/mysql-test/suite/galera/t/mdev-30653.test b/mysql-test/suite/galera/t/mdev-30653.test index 658c4372d6b..425f93b3f8c 100644 --- a/mysql-test/suite/galera/t/mdev-30653.test +++ b/mysql-test/suite/galera/t/mdev-30653.test @@ -1,4 +1,5 @@ --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_aria.inc create table t1 (id serial, val int) engine=innodb; @@ -6,7 +7,8 @@ create table t2 (id serial, val int) engine=aria; insert into t1 values(1, 23); insert into t2 values(2, 42); -call mtr.add_suppression("WSREP: Replication of non-transactional engines is experimental. Storage engine Aria for table 'test'.'t2' is not supported in Galera"); + +call mtr.add_suppression("WSREP: Replication of non-transactional engines is experimental\\. Storage engine Aria for table 'test'\\.'t2' is not supported in Galera"); begin; update t1 set val=24 where id=1; diff --git a/mysql-test/suite/galera_3nodes/t/galera_duplicate_primary_value.test b/mysql-test/suite/galera_3nodes/t/galera_duplicate_primary_value.test index 49ddb31d2d7..fe7f0b01607 100644 --- a/mysql-test/suite/galera_3nodes/t/galera_duplicate_primary_value.test +++ b/mysql-test/suite/galera_3nodes/t/galera_duplicate_primary_value.test @@ -1,4 +1,5 @@ --source include/galera_cluster.inc +--source include/have_innodb.inc --source include/have_debug.inc --source include/have_debug_sync.inc --source include/big_test.inc diff --git a/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.cnf b/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.cnf index 1457727270e..84500819cee 100644 --- a/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.cnf +++ b/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.cnf @@ -5,12 +5,12 @@ wsrep_sst_method=rsync [mysqld.1] wsrep_node_name='node.1' -wsrep_provider_options='base_port=@mysqld.1.#galera_port;socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true' +wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.1.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M' [mysqld.2] wsrep_node_name='node.2' -wsrep_provider_options='base_port=@mysqld.2.#galera_port' +wsrep_provider_options='repl.causal_read_timeout=PT90S;base_port=@mysqld.2.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M' [mysqld.3] wsrep_node_name='node.3' -wsrep_provider_options='base_port=@mysqld.3.#galera_port;socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true' +wsrep_provider_options='socket.ssl=yes;socket.ssl_cert=@ENV.MYSQL_TEST_DIR/std_data/galera-cert.pem;socket.ssl_key=@ENV.MYSQL_TEST_DIR/std_data/galera-key.pem;socket.dynamic=true;repl.causal_read_timeout=PT90S;base_port=@mysqld.3.#galera_port;evs.suspect_timeout=PT10S;evs.inactive_timeout=PT30S;evs.install_timeout=PT15S;pc.wait_prim_timeout=PT60S;gcache.size=10M' diff --git a/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.test b/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.test index bdb6a9db55b..b4536762560 100644 --- a/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.test +++ b/mysql-test/suite/galera_3nodes/t/galera_dynamic_protocol.test @@ -14,7 +14,6 @@ --let $node_3 = node_3 --source ../galera/include/auto_increment_offset_save.inc - --connection node_1 --let $wait_condition = SELECT VARIABLE_VALUE = 'Synced' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_state_comment'; --source include/wait_condition.inc diff --git a/mysql-test/suite/galera_3nodes_sr/r/MDEV-26707.result b/mysql-test/suite/galera_3nodes_sr/r/MDEV-26707.result index 6891be559d8..b1c266dd605 100644 --- a/mysql-test/suite/galera_3nodes_sr/r/MDEV-26707.result +++ b/mysql-test/suite/galera_3nodes_sr/r/MDEV-26707.result @@ -45,7 +45,7 @@ SET SESSION wsrep_sync_wait = 0; SET SESSION wsrep_sync_wait = DEFAULT; SET DEBUG_SYNC = 'now SIGNAL continue'; connection node_2; -ERROR HY000: Got error 6 "No such device or address" during COMMIT +ERROR HY000: Error while appending streaming replication fragment(provider status: Not connected to Primary Component) connection node_2a; SET DEBUG_SYNC = 'RESET'; connection node_1a; diff --git a/sql/handler.cc b/sql/handler.cc index 8fce97c3ea4..44b88e0e656 100644 --- a/sql/handler.cc +++ b/sql/handler.cc @@ -7774,6 +7774,7 @@ int handler::ha_write_row(const uchar *buf) Log_func *log_func= Write_rows_log_event::binlog_row_logging_function; error= binlog_log_row(table, 0, buf, log_func); } + #ifdef WITH_WSREP THD *thd= ha_thd(); if (WSREP_NNULL(thd) && table_share->tmp_table == NO_TMP_TABLE && diff --git a/sql/wsrep_mysqld.cc b/sql/wsrep_mysqld.cc index bd5c8b929bf..e2d61325847 100644 --- a/sql/wsrep_mysqld.cc +++ b/sql/wsrep_mysqld.cc @@ -2473,25 +2473,22 @@ bool wsrep_should_replicate_ddl(THD* thd, const handlerton *hton) case DB_TYPE_MYISAM: if (wsrep_check_mode(WSREP_MODE_REPLICATE_MYISAM)) return true; - else - WSREP_DEBUG("wsrep OSU failed for %s", wsrep_thd_query(thd)); + break; + case DB_TYPE_ARIA: + if (wsrep_check_mode(WSREP_MODE_REPLICATE_ARIA)) + return true; break; case DB_TYPE_PARTITION_DB: /* In most cases this means we could not find out table->file->partition_ht() */ return true; break; - case DB_TYPE_ARIA: - if (wsrep_check_mode(WSREP_MODE_REPLICATE_ARIA)) - return true; - else - WSREP_DEBUG("wsrep OSU failed for %s", wsrep_thd_query(thd)); - break; default: - WSREP_DEBUG("wsrep OSU failed for %s", wsrep_thd_query(thd)); break; } + WSREP_DEBUG("wsrep OSU failed for %s", wsrep_thd_query(thd)); + /* wsrep_mode = STRICT_REPLICATION, treat as error */ my_error(ER_GALERA_REPLICATION_NOT_SUPPORTED, MYF(0)); push_warning_printf(thd, Sql_condition::WARN_LEVEL_WARN, @@ -2506,15 +2503,14 @@ bool wsrep_should_replicate_ddl_iterate(THD* thd, const TABLE_LIST* table_list) { for (const TABLE_LIST* it= table_list; it; it= it->next_global) { - if (it->table && !it->table_function) + const TABLE* table= it->table; + if (table && !it->table_function) { /* If this is partitioned table we need to find out implementing storage engine handlerton. */ - const handlerton *ht= it->table->file->partition_ht() ? - it->table->file->partition_ht() : - it->table->s->db_type(); - + const handlerton *ht= table->file->partition_ht(); + if (!ht) ht= table->s->db_type(); if (!wsrep_should_replicate_ddl(thd, ht)) return false; } @@ -3208,6 +3204,7 @@ void wsrep_handle_mdl_conflict(MDL_context *requestor_ctx, THD *request_thd= requestor_ctx->get_thd(); mysql_mutex_lock(&request_thd->LOCK_thd_data); + if (wsrep_thd_is_toi(request_thd) || wsrep_thd_is_applying(request_thd)) { diff --git a/sql/wsrep_thd.h b/sql/wsrep_thd.h index bf5baf9ac7d..2fe3e123cea 100644 --- a/sql/wsrep_thd.h +++ b/sql/wsrep_thd.h @@ -237,25 +237,13 @@ static inline void wsrep_override_error(THD* thd, wsrep::client_error ce, enum wsrep::provider::status status) { - DBUG_ASSERT(ce != wsrep::e_success); - switch (ce) - { - case wsrep::e_error_during_commit: - if (status == wsrep::provider::error_size_exceeded) - wsrep_override_error(thd, ER_UNKNOWN_ERROR, "Maximum writeset size exceeded"); - else - wsrep_override_error(thd, ER_ERROR_DURING_COMMIT, 0, status); - break; - case wsrep::e_deadlock_error: - wsrep_override_error(thd, ER_LOCK_DEADLOCK); - break; - case wsrep::e_interrupted_error: - wsrep_override_error(thd, ER_QUERY_INTERRUPTED); - break; - case wsrep::e_size_exceeded_error: + DBUG_ASSERT(ce != wsrep::e_success); + switch (ce) + { + case wsrep::e_error_during_commit: + if (status == wsrep::provider::error_size_exceeded) wsrep_override_error(thd, ER_UNKNOWN_ERROR, "Maximum writeset size exceeded"); - break; - case wsrep::e_append_fragment_error: + else /* TODO: Figure out better error number */ if (status) wsrep_override_error(thd, ER_ERROR_DURING_COMMIT, @@ -265,17 +253,45 @@ static inline void wsrep_override_error(THD* thd, else wsrep_override_error(thd, ER_ERROR_DURING_COMMIT, "Error while appending streaming replication fragment"); - break; - case wsrep::e_not_supported_error: - wsrep_override_error(thd, ER_NOT_SUPPORTED_YET); - break; - case wsrep::e_timeout_error: - wsrep_override_error(thd, ER_LOCK_WAIT_TIMEOUT); + break; + case wsrep::e_deadlock_error: + switch (thd->lex->sql_command) + { + case SQLCOM_XA_END: + case SQLCOM_XA_PREPARE: + wsrep_override_error(thd, ER_XA_RBDEADLOCK); break; default: - wsrep_override_error(thd, ER_UNKNOWN_ERROR); + wsrep_override_error(thd, ER_LOCK_DEADLOCK); break; } + break; + case wsrep::e_interrupted_error: + wsrep_override_error(thd, ER_QUERY_INTERRUPTED); + break; + case wsrep::e_size_exceeded_error: + wsrep_override_error(thd, ER_UNKNOWN_ERROR, "Maximum writeset size exceeded"); + break; + case wsrep::e_append_fragment_error: + /* TODO: Figure out better error number */ + if (status) + wsrep_override_error(thd, ER_ERROR_DURING_COMMIT, + "Error while appending streaming replication fragment" + "(provider status: %s)", + wsrep::provider::to_string(status).c_str()); + else + wsrep_override_error(thd, ER_ERROR_DURING_COMMIT, + "Error while appending streaming replication fragment"); + break; + case wsrep::e_not_supported_error: + wsrep_override_error(thd, ER_NOT_SUPPORTED_YET); + break; + case wsrep::e_timeout_error: + wsrep_override_error(thd, ER_LOCK_WAIT_TIMEOUT); + break; + default: + wsrep_override_error(thd, ER_UNKNOWN_ERROR); + } } /**