Debian Codegraph @

mysql-test/suite/rpl/t/rpl_gtid_crash_myisam.test

raw
1 --source include/have_debug.inc
2 # Valgrind does not work well with test that crashes the server
3 --source include/not_valgrind.inc
4
5 --let $rpl_topology=1->2
6 --source include/rpl_init.inc
7
8 --disable_query_log
9 call mtr.add_suppression("Could not read packet:.* errno: 11");
10 --enable_query_log
11
12 --echo *** Test crashing master with InnoDB disabled, the binlog gtid state should still be correctly recovered. ***
13
14 --connection server_1
15 CREATE TABLE t1 (a INT PRIMARY KEY) ENGINE=MyISAM;
16 --save_master_pos
17
18 --connection server_2
19 --sync_with_master
20 --source include/stop_slave.inc
21 CHANGE MASTER TO master_use_gtid=slave_pos;
22 --source include/start_slave.inc
23
24 --connection server_1
25 INSERT INTO t1 VALUES (1);
26 INSERT INTO t1 VALUES (2);
27 --save_master_pos
28
29 --connection server_2
30 --sync_with_master
31 SELECT * FROM t1 ORDER BY a;
32
33 --connection server_1
34
35 --write_file $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
36 wait
37 EOF
38
39 FLUSH TABLES;
40 SET SESSION debug_dbug="+d,crash_dispatch_command_before";
41 --error 2006,2013
42 SELECT 1;
43
44 --source include/wait_until_disconnected.inc
45
46 --append_file $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
47 restart-rpl_gtid_crash.test
48 EOF
49
50 --connection server_1
51 --enable_reconnect
52 --source include/wait_until_connected_again.inc
53
54 INSERT INTO t1 VALUES (3);
55 --save_master_pos
56
57 --connection server_2
58 --sync_with_master
59 SELECT * FROM t1 ORDER BY a;
60
61 --connection server_1
62 DROP TABLE t1;
63
64 --connection default
65 --enable_reconnect
66 --source include/wait_until_connected_again.inc
67
68 --source include/rpl_end.inc