1
# Bug#12691: Exec_master_log_pos corrupted with SQL_SLAVE_SKIP_COUNTER
3
# Added: Serge Kozlov <skozlov@mysql.com>
5
--source include/master-slave.inc
7
--source include/have_binlog_format_mixed_or_statement.inc
10
--echo **** On Master ****
11
CREATE TABLE t1 (b CHAR(10));
13
--echo **** On Slave ****
14
--sync_slave_with_master
16
--source include/wait_for_slave_to_stop.inc
21
--echo **** On Master ****
22
--exec cp $MYSQL_TEST_DIR/suite/bugs/data/rpl_bug12691.dat $MYSQLTEST_VARDIR/tmp/
23
--echo LOAD DATA INFILE FILENAME
25
--eval LOAD DATA INFILE '$MYSQLTEST_VARDIR/tmp/rpl_bug12691.dat' INTO TABLE t1 FIELDS TERMINATED BY '|'
27
--remove_file $MYSQLTEST_VARDIR/tmp/rpl_bug12691.dat
29
SELECT COUNT(*) FROM t1;
31
--replace_column 2 # 5 #
32
--replace_regex /Server ver: .+/Server ver: #/ /table_id: [0-9]+/table_id: #/ /COMMIT.+xid=[0-9]+.+/#/ /file_id=[0-9]+/file_id=#/ /block_len=[0-9]+/block_len=#/ /'.+'/FILENAME/
39
--echo **** On Slave ****
40
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1;
42
--source include/wait_for_slave_to_start.inc
45
SELECT COUNT(*) FROM t1;
50
--echo **** On Master ****
52
--sync_slave_with_master