From 836a352b86fc90bffc25d62f2674ca33793ec33a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Lindstr=C3=B6m?= Date: Fri, 29 Apr 2022 10:34:58 +0300 Subject: [PATCH] MDEV-22666 : galera.MW-328A MTR failed: "Semaphore wait has lasted > 600 seconds" and do not release port 16002 Removed bad tests. --- mysql-test/suite/galera/disabled.def | 2 - mysql-test/suite/galera/r/MW-328A.result | 47 ------------ mysql-test/suite/galera/r/MW-328B.result | 25 ------- mysql-test/suite/galera/r/MW-328D.result | 22 ------ mysql-test/suite/galera/r/MW-328E.result | 22 ------ mysql-test/suite/galera/t/MW-328-footer.inc | 18 ----- mysql-test/suite/galera/t/MW-328-header.inc | 29 -------- mysql-test/suite/galera/t/MW-328A.cnf | 7 -- mysql-test/suite/galera/t/MW-328A.test | 82 --------------------- mysql-test/suite/galera/t/MW-328B.cnf | 7 -- mysql-test/suite/galera/t/MW-328B.test | 36 --------- mysql-test/suite/galera/t/MW-328D.cnf | 7 -- mysql-test/suite/galera/t/MW-328D.test | 39 ---------- mysql-test/suite/galera/t/MW-328E.cnf | 7 -- mysql-test/suite/galera/t/MW-328E.test | 40 ---------- 15 files changed, 390 deletions(-) delete mode 100644 mysql-test/suite/galera/r/MW-328A.result delete mode 100644 mysql-test/suite/galera/r/MW-328B.result delete mode 100644 mysql-test/suite/galera/r/MW-328D.result delete mode 100644 mysql-test/suite/galera/r/MW-328E.result delete mode 100644 mysql-test/suite/galera/t/MW-328-footer.inc delete mode 100644 mysql-test/suite/galera/t/MW-328-header.inc delete mode 100644 mysql-test/suite/galera/t/MW-328A.cnf delete mode 100644 mysql-test/suite/galera/t/MW-328A.test delete mode 100644 mysql-test/suite/galera/t/MW-328B.cnf delete mode 100644 mysql-test/suite/galera/t/MW-328B.test delete mode 100644 mysql-test/suite/galera/t/MW-328D.cnf delete mode 100644 mysql-test/suite/galera/t/MW-328D.test delete mode 100644 mysql-test/suite/galera/t/MW-328E.cnf delete mode 100644 mysql-test/suite/galera/t/MW-328E.test diff --git a/mysql-test/suite/galera/disabled.def b/mysql-test/suite/galera/disabled.def index 0cb698bbe73..0263c57c264 100644 --- a/mysql-test/suite/galera/disabled.def +++ b/mysql-test/suite/galera/disabled.def @@ -12,8 +12,6 @@ GCF-1081 : MDEV-18283 Galera test failure on galera.GCF-1081 GCF-939 : MDEV-21520 galera.GCF-939 -MW-328A : MDEV-22666 galera.MW-328A MTR failed: "Semaphore wait has lasted > 600 seconds" and do not release port 16002 -MW-328B : MDEV-22666 galera.MW-328A MTR failed: "Semaphore wait has lasted > 600 seconds" and do not release port 16002 MW-329 : MDEV-19962 Galera test failure on MW-329 galera_as_slave_ctas : MDEV-28378 timeout galera_as_slave_replication_bundle : MDEV-15785 OPTION_GTID_BEGIN is set in Gtid_log_event::do_apply_event() diff --git a/mysql-test/suite/galera/r/MW-328A.result b/mysql-test/suite/galera/r/MW-328A.result deleted file mode 100644 index f256558644e..00000000000 --- a/mysql-test/suite/galera/r/MW-328A.result +++ /dev/null @@ -1,47 +0,0 @@ -connection node_2; -connection node_1; -CREATE TABLE t1 (f1 INTEGER AUTO_INCREMENT PRIMARY KEY, f2 CHAR(20) DEFAULT 'abc') ENGINE=InnoDB; -INSERT INTO t1 (f1) VALUES (1); -CREATE TABLE t2 (f1 CHAR(20)) ENGINE=InnoDB; -CREATE PROCEDURE proc_update () -BEGIN -DECLARE CONTINUE HANDLER FOR SQLEXCEPTION BEGIN END; -SET SESSION wsrep_sync_wait = 0; -WHILE 1 DO -UPDATE t1 SET f2 = LEFT(MD5(RAND()), 4); -END WHILE; -END| -connect node_1X, 127.0.0.1, root, , test, $NODE_MYPORT_1; -connection node_1X; -CALL proc_update();; -connection node_1; -call mtr.add_suppression("WSREP: Wait for gtid returned error 3 while waiting for prior transactions to commit before setting position"); -connection node_2; -call mtr.add_suppression("WSREP: Wait for gtid returned error 3 while waiting for prior transactions to commit before setting position"); -SET SESSION wsrep_retry_autocommit = 0; -connection node_1; -connection node_1X; -Got one of the listed errors -connection node_1; -DROP PROCEDURE proc_update; -DROP TABLE t1, t2; -CALL mtr.add_suppression("conflict state ABORTED after post commit"); -connection node_1; -CREATE TABLE t1 (i int primary key, j int) engine=innodb; -INSERT INTO t1 values (1,0); -BEGIN; -UPDATE t1 SET j=1 WHERE i=1; -connection node_2; -UPDATE t1 SET j=2 WHERE i=1; -connection node_1; -COMMIT; -ERROR 40001: Deadlock found when trying to get lock; try restarting transaction -SELECT * FROM t1; -i j -1 2 -connection node_2; -SELECT * FROM t1; -i j -1 2 -connection node_1; -DROP TABLE t1; diff --git a/mysql-test/suite/galera/r/MW-328B.result b/mysql-test/suite/galera/r/MW-328B.result deleted file mode 100644 index 93a8685cc9e..00000000000 --- a/mysql-test/suite/galera/r/MW-328B.result +++ /dev/null @@ -1,25 +0,0 @@ -connection node_2; -connection node_1; -CREATE TABLE t1 (f1 INTEGER AUTO_INCREMENT PRIMARY KEY, f2 CHAR(20) DEFAULT 'abc') ENGINE=InnoDB; -INSERT INTO t1 (f1) VALUES (1); -CREATE TABLE t2 (f1 CHAR(20)) ENGINE=InnoDB; -CREATE PROCEDURE proc_update () -BEGIN -DECLARE CONTINUE HANDLER FOR SQLEXCEPTION BEGIN END; -SET SESSION wsrep_sync_wait = 0; -WHILE 1 DO -UPDATE t1 SET f2 = LEFT(MD5(RAND()), 4); -END WHILE; -END| -connect node_1X, 127.0.0.1, root, , test, $NODE_MYPORT_1; -connection node_1X; -CALL proc_update();; -connection node_2; -SET SESSION wsrep_retry_autocommit = 0; -connection node_1; -connection node_1X; -Got one of the listed errors -connection node_1; -DROP PROCEDURE proc_update; -DROP TABLE t1, t2; -CALL mtr.add_suppression("conflict state ABORTED after post commit"); diff --git a/mysql-test/suite/galera/r/MW-328D.result b/mysql-test/suite/galera/r/MW-328D.result deleted file mode 100644 index 43e1cefe08f..00000000000 --- a/mysql-test/suite/galera/r/MW-328D.result +++ /dev/null @@ -1,22 +0,0 @@ -connection node_2; -connection node_1; -CREATE TABLE t1 (i INT) ENGINE = InnoDB; -INSERT INTO t1 (i) VALUES(1); -CREATE TABLE t2 (i INT) ENGINE = InnoDB; -connection node_1; -SET AUTOCOMMIT=OFF; -START TRANSACTION; -SELECT * FROM t1 WHERE i = 1 LOCK IN SHARE MODE; -i -1 -connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1; -connection node_1a; -SET AUTOCOMMIT=OFF; -START TRANSACTION; -INSERT IGNORE INTO t2 SELECT * FROM t1 WHERE i = 1 FOR UPDATE;; -connection node_1; -DELETE FROM t1 WHERE i = 1; -COMMIT; -connection node_1a; -ERROR 40001: Deadlock found when trying to get lock; try restarting transaction -DROP TABLE t1, t2; diff --git a/mysql-test/suite/galera/r/MW-328E.result b/mysql-test/suite/galera/r/MW-328E.result deleted file mode 100644 index 729fdea1a63..00000000000 --- a/mysql-test/suite/galera/r/MW-328E.result +++ /dev/null @@ -1,22 +0,0 @@ -connection node_2; -connection node_1; -create table t1 (i int primary key, j int) engine=innodb; -create table t2 (i int primary key, j int) engine=innodb; -insert into t1 values (1,0); -insert into t2 values (2,0); -set autocommit=off; -start transaction; -update t1 set j=1 where i=1; -connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1; -connection node_1a; -set autocommit=off; -start transaction; -begin; -update t2 set j=1 where i=2; -connection node_1; -insert into t1 select * from t2;; -connection node_1a; -insert into t2 select * from t1; -ERROR 40001: Deadlock found when trying to get lock; try restarting transaction -connection node_1; -DROP TABLE t1, t2; diff --git a/mysql-test/suite/galera/t/MW-328-footer.inc b/mysql-test/suite/galera/t/MW-328-footer.inc deleted file mode 100644 index 12a4bf12590..00000000000 --- a/mysql-test/suite/galera/t/MW-328-footer.inc +++ /dev/null @@ -1,18 +0,0 @@ -# -# Cleanup for MW-328 tests -# - ---connection node_1 ---disable_query_log ---eval KILL CONNECTION $sp_connection_id ---enable_query_log - ---connection node_1X ---error 2013,1317 ---reap - ---connection node_1 -DROP PROCEDURE proc_update; -DROP TABLE t1, t2; - -CALL mtr.add_suppression("conflict state ABORTED after post commit"); diff --git a/mysql-test/suite/galera/t/MW-328-header.inc b/mysql-test/suite/galera/t/MW-328-header.inc deleted file mode 100644 index f0a6ccaccc6..00000000000 --- a/mysql-test/suite/galera/t/MW-328-header.inc +++ /dev/null @@ -1,29 +0,0 @@ -# -# Initialization for MW-328 tests -# - -CREATE TABLE t1 (f1 INTEGER AUTO_INCREMENT PRIMARY KEY, f2 CHAR(20) DEFAULT 'abc') ENGINE=InnoDB; -INSERT INTO t1 (f1) VALUES (1); - -CREATE TABLE t2 (f1 CHAR(20)) ENGINE=InnoDB; - -# -# Have some random updates going on against t1 -# - -DELIMITER |; -CREATE PROCEDURE proc_update () -BEGIN - DECLARE CONTINUE HANDLER FOR SQLEXCEPTION BEGIN END; - SET SESSION wsrep_sync_wait = 0; - WHILE 1 DO - UPDATE t1 SET f2 = LEFT(MD5(RAND()), 4); - END WHILE; -END| - -DELIMITER ;| - ---connect node_1X, 127.0.0.1, root, , test, $NODE_MYPORT_1 ---connection node_1X ---let $sp_connection_id = `SELECT CONNECTION_ID()` ---send CALL proc_update(); diff --git a/mysql-test/suite/galera/t/MW-328A.cnf b/mysql-test/suite/galera/t/MW-328A.cnf deleted file mode 100644 index e68f891792c..00000000000 --- a/mysql-test/suite/galera/t/MW-328A.cnf +++ /dev/null @@ -1,7 +0,0 @@ -!include ../galera_2nodes.cnf - -[mysqld.1] -wsrep-debug=SERVER - -[mysqld.2] -wsrep-debug=SERVER diff --git a/mysql-test/suite/galera/t/MW-328A.test b/mysql-test/suite/galera/t/MW-328A.test deleted file mode 100644 index 2435a9e2c2e..00000000000 --- a/mysql-test/suite/galera/t/MW-328A.test +++ /dev/null @@ -1,82 +0,0 @@ -# -# MW-328 Fix unnecessary/silent BF aborts -# - -# -# test phase 1 is not deterministic -# -# Here we attempt to insert into t2 and check if insert actually -# inserted rows if a success was reported. -# -# However, deadlocks may or may not happen in this test execution -# it all depends on timing. -# - ---source include/galera_cluster.inc ---source include/force_restart.inc ---source suite/galera/t/MW-328-header.inc - ---connection node_1 -call mtr.add_suppression("WSREP: Wait for gtid returned error 3 while waiting for prior transactions to commit before setting position"); - ---connection node_2 -call mtr.add_suppression("WSREP: Wait for gtid returned error 3 while waiting for prior transactions to commit before setting position"); ---let $count = 100 ---let $successes = 0 ---let $deadlocks = 0 - -SET SESSION wsrep_retry_autocommit = 0; - ---disable_query_log - -while ($count) -{ - TRUNCATE TABLE t2; - - --error 0,ER_LOCK_DEADLOCK - INSERT IGNORE INTO t2 SELECT f2 FROM t1; - if ($mysql_errno != 1213) { - --inc $successes - if (`SELECT COUNT(*) = 0 FROM t2`) { - --die No rows arrived in table t2 - } - } - - if ($mysql_errno == 1213) { - --inc $deadlocks - - } - - --dec $count -} - ---enable_query_log - - ---source suite/galera/t/MW-328-footer.inc - -# -# Test phase 2 is deterministic -# Here we generate a sure conflict in node 1 and verify that -# insert failed in both nodes -# ---connection node_1 -CREATE TABLE t1 (i int primary key, j int) engine=innodb; -INSERT INTO t1 values (1,0); - -BEGIN; -UPDATE t1 SET j=1 WHERE i=1; - ---connection node_2 -UPDATE t1 SET j=2 WHERE i=1; - ---connection node_1 ---error ER_LOCK_DEADLOCK -COMMIT; - -SELECT * FROM t1; ---connection node_2 -SELECT * FROM t1; ---connection node_1 - -DROP TABLE t1; diff --git a/mysql-test/suite/galera/t/MW-328B.cnf b/mysql-test/suite/galera/t/MW-328B.cnf deleted file mode 100644 index e68f891792c..00000000000 --- a/mysql-test/suite/galera/t/MW-328B.cnf +++ /dev/null @@ -1,7 +0,0 @@ -!include ../galera_2nodes.cnf - -[mysqld.1] -wsrep-debug=SERVER - -[mysqld.2] -wsrep-debug=SERVER diff --git a/mysql-test/suite/galera/t/MW-328B.test b/mysql-test/suite/galera/t/MW-328B.test deleted file mode 100644 index 41581d9c239..00000000000 --- a/mysql-test/suite/galera/t/MW-328B.test +++ /dev/null @@ -1,36 +0,0 @@ -# -# MW-328 Fix unnecessary/silent BF aborts -# - -# -# Make sure an unrelated SELECT following a BF-aborted query never -# gets the deadlock error -# - ---source include/galera_cluster.inc ---source include/force_restart.inc ---source suite/galera/t/MW-328-header.inc - ---connection node_2 ---let $count = 100 - -SET SESSION wsrep_retry_autocommit = 0; - ---disable_query_log - -while ($count) -{ - --error 0,1213 - INSERT IGNORE INTO t2 SELECT f2 FROM t1; - - --disable_result_log - --error 0 - SELECT 1 FROM DUAL; - --enable_result_log - - --dec $count -} - ---enable_query_log - ---source suite/galera/t/MW-328-footer.inc diff --git a/mysql-test/suite/galera/t/MW-328D.cnf b/mysql-test/suite/galera/t/MW-328D.cnf deleted file mode 100644 index e68f891792c..00000000000 --- a/mysql-test/suite/galera/t/MW-328D.cnf +++ /dev/null @@ -1,7 +0,0 @@ -!include ../galera_2nodes.cnf - -[mysqld.1] -wsrep-debug=SERVER - -[mysqld.2] -wsrep-debug=SERVER diff --git a/mysql-test/suite/galera/t/MW-328D.test b/mysql-test/suite/galera/t/MW-328D.test deleted file mode 100644 index e8a22f22a99..00000000000 --- a/mysql-test/suite/galera/t/MW-328D.test +++ /dev/null @@ -1,39 +0,0 @@ -# -# MW-328 Fix unnecessary/silent BF aborts -# - -# -# Test that non-Galera deadlock error still behaves as expected -# - ---source include/galera_cluster.inc - -CREATE TABLE t1 (i INT) ENGINE = InnoDB; -INSERT INTO t1 (i) VALUES(1); - -CREATE TABLE t2 (i INT) ENGINE = InnoDB; - -# Create a deadlock situation - ---connection node_1 -SET AUTOCOMMIT=OFF; -START TRANSACTION; -SELECT * FROM t1 WHERE i = 1 LOCK IN SHARE MODE; - ---connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1 ---connection node_1a -SET AUTOCOMMIT=OFF; -START TRANSACTION; ---send INSERT IGNORE INTO t2 SELECT * FROM t1 WHERE i = 1 FOR UPDATE; - ---connection node_1 ---sleep 2 -DELETE FROM t1 WHERE i = 1; -COMMIT; - -# We expect that ER_LOCK_DEADLOCK will be delivered even though it was a INSERT INGORE statement ---connection node_1a ---error ER_LOCK_DEADLOCK ---reap - -DROP TABLE t1, t2; diff --git a/mysql-test/suite/galera/t/MW-328E.cnf b/mysql-test/suite/galera/t/MW-328E.cnf deleted file mode 100644 index e68f891792c..00000000000 --- a/mysql-test/suite/galera/t/MW-328E.cnf +++ /dev/null @@ -1,7 +0,0 @@ -!include ../galera_2nodes.cnf - -[mysqld.1] -wsrep-debug=SERVER - -[mysqld.2] -wsrep-debug=SERVER diff --git a/mysql-test/suite/galera/t/MW-328E.test b/mysql-test/suite/galera/t/MW-328E.test deleted file mode 100644 index 34b17be7b08..00000000000 --- a/mysql-test/suite/galera/t/MW-328E.test +++ /dev/null @@ -1,40 +0,0 @@ -# -# MW-328 Fix unnecessary/silent BF aborts -# - -# -# Test that non-Galera deadlock error still behaves as expected (case #2) -# - ---source include/galera_cluster.inc - -create table t1 (i int primary key, j int) engine=innodb; -create table t2 (i int primary key, j int) engine=innodb; - -insert into t1 values (1,0); -insert into t2 values (2,0); - -set autocommit=off; -start transaction; -update t1 set j=1 where i=1; - ---connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1 ---connection node_1a -set autocommit=off; -start transaction; -begin; -update t2 set j=1 where i=2; - ---connection node_1 -# Hang expected here ---send insert into t1 select * from t2; - ---sleep 2 ---connection node_1a ---error ER_LOCK_DEADLOCK -insert into t2 select * from t1; - ---connection node_1 ---reap - -DROP TABLE t1, t2;