| 1 |
connection node_2; |
| 2 |
connection node_1; |
| 3 |
connection node_1; |
| 4 |
connection node_2; |
| 5 |
connection node_3; |
| 6 |
connection node_1; |
| 7 |
CREATE TABLE test.t1 (f1 INTEGER PRIMARY KEY, f2 CHAR(1)) ENGINE=InnoDB; |
| 8 |
connection node_2; |
| 9 |
SET GLOBAL wsrep_on=OFF; |
| 10 |
INSERT INTO t1 VALUES (1, 'a'); |
| 11 |
SET GLOBAL wsrep_on=ON; |
| 12 |
LOCK TABLE t1 WRITE; |
| 13 |
connection node_1; |
| 14 |
INSERT INTO t1 VALUES (1, 'b'); |
| 15 |
SET GLOBAL wsrep_provider_options = 'gmcast.isolate=1'; |
| 16 |
SET SESSION wsrep_sync_wait=0; |
| 17 |
connection node_3; |
| 18 |
SHOW STATUS LIKE 'wsrep_cluster_size'; |
| 19 |
Variable_name Value |
| 20 |
wsrep_cluster_size 2 |
| 21 |
SHOW STATUS LIKE 'wsrep_cluster_status'; |
| 22 |
Variable_name Value |
| 23 |
wsrep_cluster_status Primary |
| 24 |
connection node_2; |
| 25 |
UNLOCK TABLES; |
| 26 |
SET SESSION wsrep_on = ON; |
| 27 |
SET SESSION wsrep_sync_wait = 15; |
| 28 |
connection node_1; |
| 29 |
SHOW STATUS LIKE 'wsrep_cluster_status'; |
| 30 |
Variable_name Value |
| 31 |
wsrep_cluster_status non-Primary |
| 32 |
SHOW STATUS LIKE 'wsrep_cluster_size'; |
| 33 |
Variable_name Value |
| 34 |
wsrep_cluster_size 1 |
| 35 |
connection node_2; |
| 36 |
SET SESSION wsrep_sync_wait=0; |
| 37 |
SHOW STATUS LIKE 'wsrep_cluster_status'; |
| 38 |
Variable_name Value |
| 39 |
wsrep_cluster_status Disconnected |
| 40 |
SHOW STATUS LIKE 'wsrep_cluster_size'; |
| 41 |
Variable_name Value |
| 42 |
wsrep_cluster_size 0 |
| 43 |
SET GLOBAL wsrep_on=OFF; |
| 44 |
SELECT * FROM t1; |
| 45 |
f1 f2 |
| 46 |
1 a |
| 47 |
connection node_3; |
| 48 |
SET SESSION wsrep_sync_wait=0; |
| 49 |
SHOW STATUS LIKE 'wsrep_cluster_status'; |
| 50 |
Variable_name Value |
| 51 |
wsrep_cluster_status Primary |
| 52 |
SHOW STATUS LIKE 'wsrep_cluster_size'; |
| 53 |
Variable_name Value |
| 54 |
wsrep_cluster_size 1 |
| 55 |
SELECT * FROM t1; |
| 56 |
f1 f2 |
| 57 |
1 b |
| 58 |
# reconnect node #1 |
| 59 |
connection node_1; |
| 60 |
SET GLOBAL wsrep_provider_options = 'gmcast.isolate=0'; |
| 61 |
# reconnect node #2 |
| 62 |
connection node_2; |
| 63 |
# restart |
| 64 |
SHOW STATUS LIKE 'wsrep_cluster_status'; |
| 65 |
Variable_name Value |
| 66 |
wsrep_cluster_status Primary |
| 67 |
SHOW STATUS LIKE 'wsrep_cluster_size'; |
| 68 |
Variable_name Value |
| 69 |
wsrep_cluster_size 3 |
| 70 |
SELECT * FROM t1; |
| 71 |
f1 f2 |
| 72 |
1 b |
| 73 |
connection node_1; |
| 74 |
SELECT * FROM t1; |
| 75 |
f1 f2 |
| 76 |
1 b |
| 77 |
connection node_2; |
| 78 |
SELECT * FROM t1; |
| 79 |
f1 f2 |
| 80 |
1 b |
| 81 |
connection node_3; |
| 82 |
SELECT * FROM t1; |
| 83 |
f1 f2 |
| 84 |
1 b |
| 85 |
DROP TABLE t1; |
| 86 |
connection node_2; |
| 87 |
CALL mtr.add_suppression("Slave SQL: Could not execute Write_rows event on table test.t1; Duplicate entry '1' for key 'PRIMARY', Error_code: 1062; handler error HA_ERR_FOUND_DUPP_KEY; the event's master log FIRST, end_log_pos (.*), Error_code: 1062"); |
| 88 |
CALL mtr.add_suppression("WSREP: Event (.*) Write_rows_v1 apply failed: 121, seqno "); |
| 89 |
CALL mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on "); |
| 90 |
CALL mtr.add_suppression("Plugin 'InnoDB' will be forced to shutdown"); |
| 91 |
CALL mtr.add_suppression("WSREP: Failed to apply write set: "); |