Debian Codegraph @

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

raw
1 --source include/have_innodb.inc
2 --source include/have_binlog_format_mixed.inc
3
4 --let $rpl_topology=1->2,1->3
5 --source include/rpl_init.inc
6
7 connection server_1;
8 create table t1 (n int);
9 insert into t1 values (1);
10 insert into t1 values (2);
11 save_master_pos;
12
13 connection server_3;
14 sync_with_master;
15 source include/stop_slave.inc;
16 source include/wait_for_slave_to_stop.inc;
17
18 connection server_2;
19 sync_with_master;
20 source include/stop_slave.inc;
21 source include/wait_for_slave_to_stop.inc;
22 reset slave all;
23
24 connection server_1;
25 --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2
26 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_2,
27 master_user='root', master_ssl_verify_server_cert=0,
28 MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1;
29 source include/start_slave.inc;
30 source include/wait_for_slave_to_start.inc;
31
32 connection server_2;
33 flush logs;
34 insert into t1 values (3);
35 insert into t1 values (4);
36 flush logs;
37 save_master_pos;
38
39 connection server_3;
40 --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2
41 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_2,
42 MASTER_USE_GTID=SLAVE_POS;
43 source include/start_slave.inc;
44 sync_with_master;
45
46 select * from t1 order by n;
47 source include/show_binary_logs.inc;
48 let $binlog_file=LAST;
49 source include/show_binlog_events.inc;
50
51 connection server_1;
52 --sync_with_master
53 source include/stop_slave.inc;
54 source include/wait_for_slave_to_stop.inc;
55 reset slave all;
56
57 connection server_2;
58 --replace_result $SERVER_MYPORT_1 SERVER_MYPORT_1
59 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_1,
60 master_user = 'root', MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1;
61 source include/start_slave.inc;
62
63 connection server_3;
64 source include/stop_slave.inc;
65 --replace_result $SERVER_MYPORT_1 SERVER_MYPORT_1
66 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_1,
67 MASTER_USE_GTID=SLAVE_POS;
68 source include/start_slave.inc;
69
70 connection server_1;
71 drop table t1;
72
73 --source include/rpl_end.inc