mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
Fix that one can run rpl_binlog_errors with --debug
This commit is contained in:
@ -28,7 +28,7 @@ ERROR HY000: Can't generate a unique log-filename master-bin.(1-999)
|
|||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 #
|
master-bin.000001 #
|
||||||
SET GLOBAL debug_dbug="";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
###################### TEST #3
|
###################### TEST #3
|
||||||
CREATE TABLE t1 (a INT);
|
CREATE TABLE t1 (a INT);
|
||||||
@ -42,7 +42,7 @@ show binary logs;
|
|||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 #
|
master-bin.000001 #
|
||||||
master-bin.000002 #
|
master-bin.000002 #
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
###################### TEST #4
|
###################### TEST #4
|
||||||
@ -54,7 +54,7 @@ ERROR HY000: Can't generate a unique log-filename master-bin.(1-999)
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
count(*)
|
count(*)
|
||||||
1
|
1
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
###################### TEST #5
|
###################### TEST #5
|
||||||
@ -64,7 +64,7 @@ LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/bug_46166-2.data' INTO TABLE t2;
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
count(*)
|
count(*)
|
||||||
1
|
1
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
###################### TEST #6
|
###################### TEST #6
|
||||||
@ -81,7 +81,7 @@ SELECT count(*) FROM t2;
|
|||||||
count(*)
|
count(*)
|
||||||
3
|
3
|
||||||
SET AUTOCOMMIT= 1;
|
SET AUTOCOMMIT= 1;
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
###################### TEST #7
|
###################### TEST #7
|
||||||
@ -97,7 +97,7 @@ SELECT count(*) FROM t4;
|
|||||||
count(*)
|
count(*)
|
||||||
1
|
1
|
||||||
### check that the incident event is written to the current log
|
### 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
|
include/show_binlog_events.inc
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000001 # Incident # # #1 (LOST_EVENTS)
|
master-bin.000001 # Incident # # #1 (LOST_EVENTS)
|
||||||
@ -144,7 +144,7 @@ count(*)
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
count(*)
|
count(*)
|
||||||
0
|
0
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
###################### TEST #9
|
###################### TEST #9
|
||||||
SET GLOBAL debug_dbug="+d,error_unique_log_filename";
|
SET GLOBAL debug_dbug="+d,error_unique_log_filename";
|
||||||
SET SQL_LOG_BIN=0;
|
SET SQL_LOG_BIN=0;
|
||||||
@ -167,7 +167,7 @@ SELECT count(*) FROM t4;
|
|||||||
count(*)
|
count(*)
|
||||||
0
|
0
|
||||||
SET SQL_LOG_BIN=1;
|
SET SQL_LOG_BIN=1;
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
###################### TEST #10
|
###################### TEST #10
|
||||||
call mtr.add_suppression("MSYQL_BIN_LOG::open failed to sync the index file.");
|
call mtr.add_suppression("MSYQL_BIN_LOG::open failed to sync the index file.");
|
||||||
call mtr.add_suppression("Could not open .*");
|
call mtr.add_suppression("Could not open .*");
|
||||||
@ -215,7 +215,6 @@ DELETE FROM t4;
|
|||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
DROP TABLE t5;
|
DROP TABLE t5;
|
||||||
include/rpl_restart_server.inc [server_number=1]
|
include/rpl_restart_server.inc [server_number=1]
|
||||||
SET GLOBAL debug_dbug= @old_debug;
|
|
||||||
DROP TABLE t1, t2, t4;
|
DROP TABLE t1, t2, t4;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
include/start_slave.inc
|
include/start_slave.inc
|
||||||
@ -271,7 +270,6 @@ include/rpl_restart_server.inc [server_number=2]
|
|||||||
include/stop_slave_sql.inc
|
include/stop_slave_sql.inc
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1255 Slave already has been stopped
|
Note 1255 Slave already has been stopped
|
||||||
SET GLOBAL debug_dbug=@old_debug;
|
|
||||||
RESET SLAVE;
|
RESET SLAVE;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
include/rpl_end.inc
|
include/rpl_end.inc
|
||||||
|
@ -75,7 +75,7 @@ FLUSH LOGS;
|
|||||||
-- source include/show_binary_logs.inc
|
-- source include/show_binary_logs.inc
|
||||||
|
|
||||||
### ACTION: clean up and move to next test
|
### ACTION: clean up and move to next test
|
||||||
SET GLOBAL debug_dbug="";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
-- echo ###################### TEST #3
|
-- echo ###################### TEST #3
|
||||||
@ -100,7 +100,7 @@ RESET MASTER;
|
|||||||
-- source include/show_binary_logs.inc
|
-- source include/show_binary_logs.inc
|
||||||
|
|
||||||
# clean up the table and the binlog to be used in next part of test
|
# 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;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
@ -121,7 +121,7 @@ SET GLOBAL debug_dbug="+d,error_unique_log_filename";
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
|
|
||||||
# clean up the table and the binlog to be used in next part of test
|
# 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;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
@ -139,7 +139,7 @@ SET GLOBAL debug_dbug="+d,error_unique_log_filename";
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
|
|
||||||
# clean up the table and the binlog to be used in next part of test
|
# 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;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
@ -165,7 +165,7 @@ SELECT count(*) FROM t2;
|
|||||||
|
|
||||||
### ACTION: clean up and move to the next test
|
### ACTION: clean up and move to the next test
|
||||||
SET AUTOCOMMIT= 1;
|
SET AUTOCOMMIT= 1;
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
DELETE FROM t2;
|
DELETE FROM t2;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
@ -185,7 +185,7 @@ SELECT count(*) FROM t4;
|
|||||||
SELECT count(*) FROM t4;
|
SELECT count(*) FROM t4;
|
||||||
|
|
||||||
-- echo ### check that the incident event is written to the current log
|
-- 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
|
-- let $binlog_limit= 4,1
|
||||||
-- source include/show_binlog_events.inc
|
-- source include/show_binlog_events.inc
|
||||||
|
|
||||||
@ -229,7 +229,7 @@ SELECT count(*) FROM t4;
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
|
|
||||||
# remove fault injection
|
# remove fault injection
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
|
|
||||||
-- echo ###################### TEST #9
|
-- echo ###################### TEST #9
|
||||||
|
|
||||||
@ -248,7 +248,7 @@ DELETE FROM t4;
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
SELECT count(*) FROM t4;
|
SELECT count(*) FROM t4;
|
||||||
SET SQL_LOG_BIN=1;
|
SET SQL_LOG_BIN=1;
|
||||||
SET GLOBAL debug_dbug="-d,error_unique_log_filename";
|
SET GLOBAL debug_dbug=@old_debug;
|
||||||
|
|
||||||
-- echo ###################### TEST #10
|
-- echo ###################### TEST #10
|
||||||
|
|
||||||
@ -340,7 +340,6 @@ DROP TABLE t5;
|
|||||||
--source include/rpl_restart_server.inc
|
--source include/rpl_restart_server.inc
|
||||||
|
|
||||||
## clean up
|
## clean up
|
||||||
SET GLOBAL debug_dbug= @old_debug;
|
|
||||||
DROP TABLE t1, t2, t4;
|
DROP TABLE t1, t2, t4;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
|
|
||||||
@ -398,7 +397,6 @@ call mtr.add_suppression("Can't generate a unique log-filename .*");
|
|||||||
|
|
||||||
### clean up
|
### clean up
|
||||||
-- source include/stop_slave_sql.inc
|
-- source include/stop_slave_sql.inc
|
||||||
SET GLOBAL debug_dbug=@old_debug;
|
|
||||||
RESET SLAVE;
|
RESET SLAVE;
|
||||||
RESET MASTER;
|
RESET MASTER;
|
||||||
--let $rpl_only_running_threads= 1
|
--let $rpl_only_running_threads= 1
|
||||||
|
Reference in New Issue
Block a user