2002-09-11 05:40:08 +02:00
|
|
|
# Testing if "flush logs" command bouncing resulting in logs created in a loop
|
|
|
|
# in case of bi-directional replication
|
2005-12-22 06:39:02 +01:00
|
|
|
-- source include/master-slave.inc
|
2002-09-11 05:40:08 +02:00
|
|
|
|
2006-03-21 17:40:51 +01:00
|
|
|
#
|
|
|
|
# Start replication master -> slave
|
|
|
|
#
|
2002-09-11 05:40:08 +02:00
|
|
|
connection slave;
|
2005-12-22 06:39:02 +01:00
|
|
|
--disable_warnings
|
2005-07-15 17:51:43 +02:00
|
|
|
stop slave;
|
2005-12-22 06:39:02 +01:00
|
|
|
--enable_warnings
|
2002-09-23 15:34:49 +02:00
|
|
|
--replace_result $MASTER_MYPORT MASTER_PORT
|
2002-09-11 05:40:08 +02:00
|
|
|
eval change master to master_host='127.0.0.1',master_user='root',
|
|
|
|
master_password='',master_port=$MASTER_MYPORT;
|
2002-10-25 01:46:14 +02:00
|
|
|
start slave;
|
2006-03-21 17:40:51 +01:00
|
|
|
|
|
|
|
#
|
|
|
|
# Start replication slave -> master
|
|
|
|
#
|
2002-09-11 05:40:08 +02:00
|
|
|
connection master;
|
2005-12-22 06:39:02 +01:00
|
|
|
--disable_warnings
|
|
|
|
stop slave;
|
|
|
|
--enable_warnings
|
2002-09-23 15:34:49 +02:00
|
|
|
--replace_result $SLAVE_MYPORT SLAVE_PORT
|
2002-09-11 05:40:08 +02:00
|
|
|
eval change master to master_host='127.0.0.1',master_user='root',
|
|
|
|
master_password='',master_port=$SLAVE_MYPORT;
|
2002-10-25 01:46:14 +02:00
|
|
|
start slave;
|
2006-03-21 17:40:51 +01:00
|
|
|
|
|
|
|
#
|
|
|
|
# Wait for start of slave IO and SQL threads
|
|
|
|
#
|
|
|
|
let $result_pattern= '%127.0.0.1%root%slave-bin.000001%slave-bin.000001%Yes%Yes%0%0%None%';
|
|
|
|
--source include/wait_slave_status.inc
|
|
|
|
|
|
|
|
#
|
|
|
|
# Flush logs of slave
|
|
|
|
#
|
2002-09-11 05:40:08 +02:00
|
|
|
flush logs;
|
|
|
|
sleep 5;
|
2006-03-21 17:40:51 +01:00
|
|
|
|
|
|
|
#
|
|
|
|
# Show status of slave
|
|
|
|
#
|
2002-09-23 15:34:49 +02:00
|
|
|
--replace_result $SLAVE_MYPORT SLAVE_PORT
|
2005-12-22 06:39:02 +01:00
|
|
|
--replace_column 1 # 8 # 9 # 16 # 23 # 33 #
|
2006-03-21 17:40:51 +01:00
|
|
|
--vertical_results
|
|
|
|
SHOW SLAVE STATUS;
|