Commit 78ffeaa9 authored by Monty's avatar Monty

Fix that one can run rpl_binlog_errors with --debug

parent 05ed9fec
......@@ -28,7 +28,7 @@ ERROR HY000: Can't generate a unique log-filename master-bin.(1-999)
show binary logs;
Log_name File_size
master-bin.000001 #
SET GLOBAL debug_dbug="";
SET GLOBAL debug_dbug=@old_debug;
RESET MASTER;
###################### TEST #3
CREATE TABLE t1 (a INT);
......@@ -42,7 +42,7 @@ show binary logs;
Log_name File_size
master-bin.000001 #
master-bin.000002 #
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
###################### TEST #4
......@@ -54,7 +54,7 @@ ERROR HY000: Can't generate a unique log-filename master-bin.(1-999)
SELECT count(*) FROM t2;
count(*)
1
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
###################### TEST #5
......@@ -64,7 +64,7 @@ LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/bug_46166-2.data' INTO TABLE t2;
SELECT count(*) FROM t2;
count(*)
1
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
###################### TEST #6
......@@ -81,7 +81,7 @@ SELECT count(*) FROM t2;
count(*)
3
SET AUTOCOMMIT= 1;
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
###################### TEST #7
......@@ -97,7 +97,7 @@ SELECT count(*) FROM t4;
count(*)
1
### check that the incident event is written to the current log
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
include/show_binlog_events.inc
Log_name Pos Event_type Server_id End_log_pos Info
master-bin.000001 # Incident # # #1 (LOST_EVENTS)
......@@ -144,7 +144,7 @@ count(*)
SELECT count(*) FROM t2;
count(*)
0
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
###################### TEST #9
SET GLOBAL debug_dbug="+d,error_unique_log_filename";
SET SQL_LOG_BIN=0;
......@@ -167,7 +167,7 @@ SELECT count(*) FROM t4;
count(*)
0
SET SQL_LOG_BIN=1;
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
###################### TEST #10
call mtr.add_suppression("MSYQL_BIN_LOG::open failed to sync the index file.");
call mtr.add_suppression("Could not open .*");
......@@ -215,7 +215,6 @@ DELETE FROM t4;
DELETE FROM t2;
DROP TABLE t5;
include/rpl_restart_server.inc [server_number=1]
SET GLOBAL debug_dbug= @old_debug;
DROP TABLE t1, t2, t4;
RESET MASTER;
include/start_slave.inc
......@@ -271,7 +270,6 @@ include/rpl_restart_server.inc [server_number=2]
include/stop_slave_sql.inc
Warnings:
Note 1255 Slave already has been stopped
SET GLOBAL debug_dbug=@old_debug;
RESET SLAVE;
RESET MASTER;
include/rpl_end.inc
......@@ -75,7 +75,7 @@ FLUSH LOGS;
-- source include/show_binary_logs.inc
### ACTION: clean up and move to next test
SET GLOBAL debug_dbug="";
SET GLOBAL debug_dbug=@old_debug;
RESET MASTER;
-- echo ###################### TEST #3
......@@ -100,7 +100,7 @@ RESET MASTER;
-- source include/show_binary_logs.inc
# clean up the table and the binlog to be used in next part of test
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
......@@ -121,7 +121,7 @@ SET GLOBAL debug_dbug="+d,error_unique_log_filename";
SELECT count(*) FROM t2;
# clean up the table and the binlog to be used in next part of test
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
......@@ -139,7 +139,7 @@ SET GLOBAL debug_dbug="+d,error_unique_log_filename";
SELECT count(*) FROM t2;
# clean up the table and the binlog to be used in next part of test
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
......@@ -165,7 +165,7 @@ SELECT count(*) FROM t2;
### ACTION: clean up and move to the next test
SET AUTOCOMMIT= 1;
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
DELETE FROM t2;
RESET MASTER;
......@@ -185,7 +185,7 @@ SELECT count(*) FROM t4;
SELECT count(*) FROM t4;
-- echo ### check that the incident event is written to the current log
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
-- let $binlog_limit= 4,1
-- source include/show_binlog_events.inc
......@@ -229,7 +229,7 @@ SELECT count(*) FROM t4;
SELECT count(*) FROM t2;
# remove fault injection
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
-- echo ###################### TEST #9
......@@ -248,7 +248,7 @@ DELETE FROM t4;
SELECT count(*) FROM t2;
SELECT count(*) FROM t4;
SET SQL_LOG_BIN=1;
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
SET GLOBAL debug_dbug=@old_debug;
-- echo ###################### TEST #10
......@@ -340,7 +340,6 @@ DROP TABLE t5;
--source include/rpl_restart_server.inc
## clean up
SET GLOBAL debug_dbug= @old_debug;
DROP TABLE t1, t2, t4;
RESET MASTER;
......@@ -398,7 +397,6 @@ call mtr.add_suppression("Can't generate a unique log-filename .*");
### clean up
-- source include/stop_slave_sql.inc
SET GLOBAL debug_dbug=@old_debug;
RESET SLAVE;
RESET MASTER;
--let $rpl_only_running_threads= 1
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment