1include/master-slave.inc 2[connection master] 3connection master; 4show binary logs; 5Log_name File_size 6master-bin.000001 # 7create table t1 (f text) engine=innodb; 8SET DEBUG_SYNC = 'at_purge_logs_before_date WAIT_FOR rotated'; 9SET DEBUG_SYNC = 'after_purge_logs_before_date SIGNAL continued'; 10insert into t1 set f=repeat('a', 4096); 11connection master1; 12*** there must be two logs in the list *** 13show binary logs; 14Log_name File_size 15master-bin.000001 # 16master-bin.000002 # 17insert into t1 set f=repeat('b', 4096); 18*** there must be three logs in the list *** 19show binary logs; 20Log_name File_size 21master-bin.000001 # 22master-bin.000002 # 23master-bin.000003 # 24SET DEBUG_SYNC = 'now SIGNAL rotated'; 25SET DEBUG_SYNC = 'now WAIT_FOR continued'; 26SET DEBUG_SYNC = 'RESET'; 27connection master; 28SET DEBUG_SYNC = 'RESET'; 29connection slave; 30connection master; 31SET DEBUG_SYNC = 'at_purge_logs_before_date WAIT_FOR rotated'; 32SET DEBUG_SYNC = 'after_purge_logs_before_date SIGNAL continued'; 33insert into t1 set f=repeat('b', 4096); 34connection master1; 35SET DEBUG_SYNC = 'now SIGNAL rotated'; 36SET DEBUG_SYNC = 'now WAIT_FOR continued'; 37SET DEBUG_SYNC = 'RESET'; 38connection master; 39SET DEBUG_SYNC = 'RESET'; 40drop table t1; 41connection slave; 42include/rpl_end.inc 43