| 1 |
--source include/galera_cluster.inc |
| 2 |
--source include/have_sequence.inc |
| 3 |
--source include/force_restart.inc |
| 4 |
|
| 5 |
# Save original auto_increment_offset values. |
| 6 |
--let $node_1=node_1 |
| 7 |
--let $node_2=node_2 |
| 8 |
--source include/auto_increment_offset_save.inc |
| 9 |
|
| 10 |
--connection node_1 |
| 11 |
call mtr.add_suppression("WSREP: Event .* Write_rows_v1 apply failed: "); |
| 12 |
call mtr.add_suppression("WSREP: Failed to apply write set: "); |
| 13 |
call mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on "); |
| 14 |
|
| 15 |
--connection node_2 |
| 16 |
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing"); |
| 17 |
call mtr.add_suppression("WSREP: Failed to open SR table for write"); |
| 18 |
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0"); |
| 19 |
call mtr.add_suppression("WSREP: Inconsistency detected: Inconsistent by consensus on "); |
| 20 |
|
| 21 |
SET @@global.transaction_read_only = ON; |
| 22 |
--error 0,1286 |
| 23 |
SET default_storage_engine = SEQUENCE; |
| 24 |
--error 1005 |
| 25 |
create table t1 (c1 int); |
| 26 |
CREATE TABLE t1(c1 VARCHAR(20)) engine=innodb charset=latin1; |
| 27 |
INSERT INTO t1 VALUES(0xA9B8); |
| 28 |
--error 1050 |
| 29 |
create TABLE t1 (c1 int) engine=innodb; |
| 30 |
--error 1050 |
| 31 |
create TABLE t1 (c1 int) engine=innodb; |
| 32 |
--let $wsrep_cluster_address_saved = `SELECT @@global.wsrep_cluster_address` |
| 33 |
SET GLOBAL wsrep_on=OFF; |
| 34 |
SET GLOBAL wsrep_cluster_address='gcomm://'; |
| 35 |
INSERT INTO t1 VALUES (1); |
| 36 |
SELECT 1; |
| 37 |
SELECT 1; |
| 38 |
COMMIT; |
| 39 |
|
| 40 |
# |
| 41 |
# Kill the entire cluster and restart |
| 42 |
# |
| 43 |
--echo # Killing cluster because we have messed with wsrep_cluster_address |
| 44 |
--connection node_2 |
| 45 |
SET SESSION wsrep_sync_wait = 0; |
| 46 |
--source include/kill_galera.inc |
| 47 |
|
| 48 |
--connection node_1 |
| 49 |
SET SESSION wsrep_sync_wait = 0; |
| 50 |
--source include/kill_galera.inc |
| 51 |
|
| 52 |
--remove_file $MYSQLTEST_VARDIR/mysqld.1/data/grastate.dat |
| 53 |
--let $start_mysqld_params =--wsrep-new-cluster |
| 54 |
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.1.expect |
| 55 |
--source include/start_mysqld.inc |
| 56 |
--source include/wait_until_ready.inc |
| 57 |
|
| 58 |
--connection node_2 |
| 59 |
--let $start_mysqld_params = |
| 60 |
--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.2.expect |
| 61 |
--source include/start_mysqld.inc |
| 62 |
--source include/wait_until_ready.inc |
| 63 |
|
| 64 |
call mtr.add_suppression("WSREP: Failed to open table mysql\\.wsrep_streaming_log for writing"); |
| 65 |
call mtr.add_suppression("WSREP: Failed to open SR table for write"); |
| 66 |
call mtr.add_suppression("WSREP: Failed to recover SR transactions from schema: wsrep_on : 0"); |
| 67 |
|
| 68 |
--connection node_1 |
| 69 |
# |
| 70 |
# after the membership change on a newly synced node, then this is just a warning |
| 71 |
# |
| 72 |
call mtr.add_suppression("WSREP: Cert position .* less than last committed"); |
| 73 |
--connection node_2 |
| 74 |
call mtr.add_suppression("WSREP: Cert position .* less than last committed"); |
| 75 |
|
| 76 |
# |
| 77 |
# Cleanup |
| 78 |
# |
| 79 |
--source ../../galera/include/auto_increment_offset_restore.inc |
| 80 |
# We killed cluster, it might mean that table does not exists |
| 81 |
--disable_warnings |
| 82 |
DROP TABLE IF EXISTS t1; |
| 83 |
--enable_warnings |