summaryrefslogtreecommitdiff
path: root/mysql-test/suite/rpl/t/rpl_bug33931.test
blob: 1316ddb7401d29ded144420ca40ed8c5a913447d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Test for 
# Bug #33931  	assertion at write_ignored_events_info_to_relay_log if init_slave_thread() fails
# Bug #33932  	assertion at handle_slave_sql if init_slave_thread() fails

source include/have_debug.inc;
source include/have_log_bin.inc;

connect (master,127.0.0.1,root,,test,$MASTER_MYPORT,);
connect (slave,127.0.0.1,root,,test,$SLAVE_MYPORT,);


connection master;
reset master;

connection slave;

# Add suppression for expected warnings in slaves error log
call mtr.add_suppression("Failed during slave I/O thread initialization");

--disable_warnings
stop slave;
--enable_warnings
reset slave;

# Set debug flags on slave to force errors to occur
SET GLOBAL debug="d,simulate_io_slave_error_on_init,simulate_sql_slave_error_on_init";

start slave;

connection master;
save_master_pos;
connection slave;

#
# slave is going to stop because of emulated failures
# but there won't be any crashes nor asserts hit.
#
source include/wait_for_slave_to_stop.inc;

--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 8 # 9 # 19 # 23 # 33 # 37 #
query_vertical show slave status;

#
# Cleanup
#
SET GLOBAL debug="";