mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-21360 save/restore debud_dbug instead of total reset at the end of the test
This commit is contained in:
@ -22,7 +22,7 @@ call mtr.add_suppression('Could not open .*');
|
||||
call mtr.add_suppression('MYSQL_BIN_LOG::purge_logs failed to clean registers before purging logs.');
|
||||
flush tables;
|
||||
|
||||
let $old=`select @@debug`;
|
||||
SET @saved_dbug = @@SESSION.debug_dbug;
|
||||
|
||||
RESET MASTER;
|
||||
|
||||
@ -273,6 +273,6 @@ SELECT @index;
|
||||
-- replace_regex /\.[\\\/]master/master/
|
||||
SELECT @index;
|
||||
|
||||
eval SET SESSION debug_dbug="$old";
|
||||
SET @@SESSION.debug_dbug = @saved_dbug;
|
||||
|
||||
--echo End of tests
|
||||
|
@ -74,6 +74,7 @@ while ($i) {
|
||||
# Emulate corruption in binlog file when SHOW BINLOG EVENTS is executing
|
||||
--echo # 2. Corruption in master binlog and SHOW BINLOG EVENTS
|
||||
set @saved_dbug = @@global.debug_dbug;
|
||||
|
||||
SET GLOBAL debug_dbug="+d,corrupt_read_log_event_char";
|
||||
--echo SHOW BINLOG EVENTS;
|
||||
--disable_query_log
|
||||
@ -131,12 +132,13 @@ let $slave_io_errno= 1595,1743; # ER_SLAVE_RELAY_LOG_WRITE_FAILURE, ER_NETWORK_R
|
||||
--source include/wait_for_slave_io_error.inc
|
||||
--connection master
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event2_set";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug;
|
||||
SET GLOBAL master_verify_checksum=1;
|
||||
|
||||
# Emulate corruption in network
|
||||
--echo # 5. Slave. Corruption in network
|
||||
--connection slave
|
||||
SET @saved_dbug_slave = @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug="+d,corrupt_queue_event";
|
||||
START SLAVE IO_THREAD;
|
||||
let $slave_io_errno= 1595,1743; # ER_SLAVE_RELAY_LOG_WRITE_FAILURE, ER_NETWORK_READ_EVENT_CHECKSUM_FAILURE
|
||||
@ -153,7 +155,7 @@ let $slave_sql_errno= 1593;
|
||||
--source include/wait_for_slave_sql_error.inc
|
||||
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event_char";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug_slave;
|
||||
|
||||
# Start normal replication and compare same table on master
|
||||
# and slave
|
||||
@ -172,6 +174,5 @@ set @@global.debug_dbug = @saved_dbug;
|
||||
SET GLOBAL master_verify_checksum = @old_master_verify_checksum;
|
||||
DROP TABLE t1;
|
||||
--sync_slave_with_master
|
||||
set @@global.debug_dbug = @saved_dbug;
|
||||
|
||||
--source include/rpl_end.inc
|
||||
|
@ -1651,7 +1651,6 @@ SELECT * FROM t2 WHERE a >= 40 ORDER BY a;
|
||||
--sync_with_master
|
||||
SELECT * FROM t2 WHERE a >= 40 ORDER BY a;
|
||||
--source include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug=@old_dbug;
|
||||
SET DEBUG_SYNC= 'RESET';
|
||||
SET GLOBAL slave_parallel_threads=0;
|
||||
SET GLOBAL slave_parallel_threads=10;
|
||||
@ -1951,7 +1950,6 @@ SELECT * FROM t2 WHERE a >= 1040 ORDER BY a;
|
||||
--source include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug=@old_dbug;
|
||||
|
||||
|
||||
--echo *** MDEV-6676 - test disabling domain-based parallel replication ***
|
||||
--connection server_1
|
||||
# Let's do a bunch of transactions that will conflict if run out-of-order in
|
||||
@ -2000,7 +1998,7 @@ SET GLOBAL debug_dbug= '+d,inject_analyze_table_sleep';
|
||||
# so sleep is ok here. And it's in general not possible to trigger reliably
|
||||
# the race with debug_sync, since the bugfix makes the race impossible).
|
||||
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
|
||||
# Group commit with cid=10000, two event groups.
|
||||
@ -2012,7 +2010,7 @@ INSERT INTO t3 VALUES (120, 0);
|
||||
SET @commit_id= 10001;
|
||||
INSERT INTO t3 VALUES (121, 0);
|
||||
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
|
||||
SELECT * FROM t3 WHERE a >= 120 ORDER BY a;
|
||||
--source include/save_master_gtid.inc
|
||||
@ -2044,7 +2042,7 @@ SET GLOBAL debug_dbug= '+d,inject_record_gtid_serverid_100_sleep';
|
||||
# We inject a small sleep in the corresponding record_gtid() to make the race
|
||||
# easier to hit.
|
||||
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
|
||||
# Group commit with cid=10010, two event groups.
|
||||
@ -2059,8 +2057,7 @@ INSERT INTO t3 VALUES (130, 0);
|
||||
SET @commit_id= 10011;
|
||||
INSERT INTO t3 VALUES (131, 0);
|
||||
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a >= 130 ORDER BY a;
|
||||
--source include/save_master_gtid.inc
|
||||
|
||||
@ -2097,7 +2094,7 @@ SET GLOBAL debug_dbug= '+d,inject_mdev8031';
|
||||
# complete. Finally an extra KILL check catches an unhandled, lingering
|
||||
# deadlock kill. So rather artificial, but at least it exercises the
|
||||
# relevant code paths.
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
|
||||
SET @commit_id= 10200;
|
||||
@ -2119,7 +2116,7 @@ UPDATE t3 SET b=b+1 WHERE a=204;
|
||||
UPDATE t3 SET b=b+1 WHERE a=203;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
--source include/save_master_gtid.inc
|
||||
@ -2144,7 +2141,7 @@ SET @old_max= @@GLOBAL.max_relay_log_size;
|
||||
SET GLOBAL max_relay_log_size= 4096;
|
||||
|
||||
--connection server_1
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
|
||||
--let $large= `SELECT REPEAT("*", 8192)`
|
||||
@ -2167,7 +2164,7 @@ eval UPDATE t3 SET b=b+1 WHERE a=203 /* $large */;
|
||||
eval UPDATE t3 SET b=b+1 WHERE a=205 /* $large */;
|
||||
eval UPDATE t3 SET b=b+1 WHERE a=205 /* $large */;
|
||||
--enable_query_log
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
--source include/save_master_gtid.inc
|
||||
@ -2178,7 +2175,7 @@ SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
--source include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug= @old_debg;
|
||||
SET GLOBAL debug_dbug= @old_dbug;
|
||||
SET GLOBAL max_relay_log_size= @old_max;
|
||||
--source include/start_slave.inc
|
||||
|
||||
|
@ -13,6 +13,7 @@ create table tm (a int auto_increment primary key) engine=myisam;
|
||||
create table ti (a int auto_increment primary key) engine=innodb;
|
||||
|
||||
sync_slave_with_master;
|
||||
SET @saved_dbug = @@GLOBAL.debug_dbug;
|
||||
set @@global.debug_dbug="+d,stop_slave_middle_group";
|
||||
|
||||
connection master;
|
||||
@ -135,8 +136,7 @@ eval SELECT "$error" AS Last_SQL_Error, @check as `true`;
|
||||
select max(a) as two from tm;
|
||||
select max(a) as one from ti;
|
||||
|
||||
set @@global.debug_dbug="-d";
|
||||
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
#
|
||||
# clean-up
|
||||
#
|
||||
|
@ -5,6 +5,7 @@ call mtr.add_suppression('Turning logging off for the whole duration of the MySQ
|
||||
call mtr.add_suppression('Could not open .*');
|
||||
call mtr.add_suppression('MYSQL_BIN_LOG::purge_logs failed to clean registers before purging logs.');
|
||||
flush tables;
|
||||
SET @saved_dbug = @@SESSION.debug_dbug;
|
||||
RESET MASTER;
|
||||
flush logs;
|
||||
flush logs;
|
||||
@ -183,5 +184,5 @@ master-bin.000011
|
||||
master-bin.000012
|
||||
master-bin.000013
|
||||
|
||||
SET SESSION debug_dbug="";
|
||||
SET @@SESSION.debug_dbug = @saved_dbug;
|
||||
End of tests
|
||||
|
@ -5,6 +5,7 @@ call mtr.add_suppression('Turning logging off for the whole duration of the MySQ
|
||||
call mtr.add_suppression('Could not open .*');
|
||||
call mtr.add_suppression('MYSQL_BIN_LOG::purge_logs failed to clean registers before purging logs.');
|
||||
flush tables;
|
||||
SET @saved_dbug = @@SESSION.debug_dbug;
|
||||
RESET MASTER;
|
||||
flush logs;
|
||||
flush logs;
|
||||
@ -183,5 +184,5 @@ master-bin.000011
|
||||
master-bin.000012
|
||||
master-bin.000013
|
||||
|
||||
SET SESSION debug_dbug="";
|
||||
SET @@SESSION.debug_dbug = @saved_dbug;
|
||||
End of tests
|
||||
|
@ -34,10 +34,11 @@ START SLAVE IO_THREAD;
|
||||
include/wait_for_slave_io_error.inc [errno=1595,1743]
|
||||
connection master;
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event2_set";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug;
|
||||
SET GLOBAL master_verify_checksum=1;
|
||||
# 5. Slave. Corruption in network
|
||||
connection slave;
|
||||
SET @saved_dbug_slave = @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug="+d,corrupt_queue_event";
|
||||
START SLAVE IO_THREAD;
|
||||
include/wait_for_slave_io_error.inc [errno=1595,1743]
|
||||
@ -47,7 +48,7 @@ SET GLOBAL debug_dbug="+d,corrupt_read_log_event_char";
|
||||
START SLAVE SQL_THREAD;
|
||||
include/wait_for_slave_sql_error.inc [errno=1593]
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event_char";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug_slave;
|
||||
# 7. Seek diff for tables on master and slave
|
||||
connection slave;
|
||||
include/start_slave.inc
|
||||
@ -60,5 +61,4 @@ set @@global.debug_dbug = @saved_dbug;
|
||||
SET GLOBAL master_verify_checksum = @old_master_verify_checksum;
|
||||
DROP TABLE t1;
|
||||
connection slave;
|
||||
set @@global.debug_dbug = @saved_dbug;
|
||||
include/rpl_end.inc
|
||||
|
@ -1227,7 +1227,6 @@ a
|
||||
45
|
||||
46
|
||||
include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug=@old_dbug;
|
||||
SET DEBUG_SYNC= 'RESET';
|
||||
SET GLOBAL slave_parallel_threads=0;
|
||||
SET GLOBAL slave_parallel_threads=10;
|
||||
@ -1513,7 +1512,7 @@ SET GLOBAL slave_parallel_threads=10;
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_analyze_table_sleep';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10000;
|
||||
ANALYZE TABLE t2;
|
||||
@ -1522,7 +1521,7 @@ test.t2 analyze status OK
|
||||
INSERT INTO t3 VALUES (120, 0);
|
||||
SET @commit_id= 10001;
|
||||
INSERT INTO t3 VALUES (121, 0);
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a >= 120 ORDER BY a;
|
||||
a b
|
||||
120 0
|
||||
@ -1544,7 +1543,7 @@ include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_record_gtid_serverid_100_sleep';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @old_server_id= @@SESSION.server_id;
|
||||
SET SESSION server_id= 100;
|
||||
@ -1554,7 +1553,7 @@ SET SESSION server_id= @old_server_id;
|
||||
INSERT INTO t3 VALUES (130, 0);
|
||||
SET @commit_id= 10011;
|
||||
INSERT INTO t3 VALUES (131, 0);
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a >= 130 ORDER BY a;
|
||||
a b
|
||||
130 0
|
||||
@ -1580,7 +1579,7 @@ include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_mdev8031';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10200;
|
||||
INSERT INTO t3 VALUES (203, 1);
|
||||
@ -1601,7 +1600,7 @@ UPDATE t3 SET b=b+1 WHERE a=204;
|
||||
UPDATE t3 SET b=b+1 WHERE a=203;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
a b
|
||||
201 3
|
||||
@ -1631,11 +1630,11 @@ SET GLOBAL debug_dbug= '+d,inject_retry_event_group_open_binlog_kill';
|
||||
SET @old_max= @@GLOBAL.max_relay_log_size;
|
||||
SET GLOBAL max_relay_log_size= 4096;
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10210;
|
||||
Omit long queries that cause relaylog rotations and transaction retries...
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
a b
|
||||
201 6
|
||||
@ -1655,7 +1654,7 @@ a b
|
||||
204 7
|
||||
205 5
|
||||
include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug= @old_debg;
|
||||
SET GLOBAL debug_dbug= @old_dbug;
|
||||
SET GLOBAL max_relay_log_size= @old_max;
|
||||
include/start_slave.inc
|
||||
*** MDEV-8725: Assertion on ROLLBACK statement in the binary log ***
|
||||
|
@ -4,7 +4,7 @@ connection server_2;
|
||||
include/stop_slave.inc
|
||||
SET @old_parallel_threads=@@GLOBAL.slave_parallel_threads;
|
||||
SET @old_parallel_mode=@@GLOBAL.slave_parallel_mode;
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL slave_parallel_mode='optimistic';
|
||||
SET GLOBAL slave_parallel_threads= 3;
|
||||
CHANGE MASTER TO master_use_gtid=slave_pos;
|
||||
|
@ -29,7 +29,7 @@ ALTER TABLE t2 drop index idx1;
|
||||
connection default;
|
||||
set DEBUG_SYNC= 'now SIGNAL fts_drop_index';
|
||||
connection con1;
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
drop table t1, t2;
|
||||
connection default;
|
||||
set DEBUG_SYNC=RESET;
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
|
@ -39,7 +39,7 @@ SLEEP(2)
|
||||
SELECT sql_text FROM mysql.slow_log WHERE query_time >= '00:00:02';
|
||||
sql_text
|
||||
INSERT INTO t1(title) VALUES('mysql database')
|
||||
SET GLOBAL debug_dbug = @old_debug_dbug;
|
||||
SET GLOBAL debug_dbug = @old_debug;
|
||||
TRUNCATE TABLE mysql.slow_log;
|
||||
DROP TABLE t1;
|
||||
# Case 2: Sync blocks DML(insert) on other tables.
|
||||
@ -71,7 +71,7 @@ SLEEP(2)
|
||||
# slow log results should be empty here.
|
||||
SELECT sql_text FROM mysql.slow_log WHERE query_time >= '00:00:02';
|
||||
sql_text
|
||||
SET GLOBAL debug_dbug = @old_debug_dbug;
|
||||
SET GLOBAL debug_dbug = @old_debug;
|
||||
TRUNCATE TABLE mysql.slow_log;
|
||||
DROP TABLE t1,t2;
|
||||
disconnect con1;
|
||||
|
@ -46,7 +46,7 @@ set DEBUG_SYNC= 'now SIGNAL fts_drop_index';
|
||||
|
||||
connection con1;
|
||||
reap;
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
drop table t1, t2;
|
||||
connection default;
|
||||
set DEBUG_SYNC=RESET;
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
|
@ -61,7 +61,7 @@ SELECT SLEEP(2);
|
||||
-- echo # slow log results should only contain INSERT INTO t1.
|
||||
SELECT sql_text FROM mysql.slow_log WHERE query_time >= '00:00:02';
|
||||
|
||||
SET GLOBAL debug_dbug = @old_debug_dbug;
|
||||
SET GLOBAL debug_dbug = @old_debug;
|
||||
TRUNCATE TABLE mysql.slow_log;
|
||||
|
||||
DROP TABLE t1;
|
||||
@ -107,7 +107,7 @@ SELECT SLEEP(2);
|
||||
-- echo # slow log results should be empty here.
|
||||
SELECT sql_text FROM mysql.slow_log WHERE query_time >= '00:00:02';
|
||||
|
||||
SET GLOBAL debug_dbug = @old_debug_dbug;
|
||||
SET GLOBAL debug_dbug = @old_debug;
|
||||
TRUNCATE TABLE mysql.slow_log;
|
||||
|
||||
DROP TABLE t1,t2;
|
||||
|
@ -47,7 +47,7 @@
|
||||
--source include/stop_slave.inc
|
||||
SET @old_parallel_threads=@@GLOBAL.slave_parallel_threads;
|
||||
SET @old_parallel_mode=@@GLOBAL.slave_parallel_mode;
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL slave_parallel_mode='optimistic';
|
||||
SET GLOBAL slave_parallel_threads= 3;
|
||||
CHANGE MASTER TO master_use_gtid=slave_pos;
|
||||
|
@ -1,9 +1,9 @@
|
||||
include/rpl_init.inc [topology=1->2->1]
|
||||
include/rpl_connect.inc [creating M4]
|
||||
include/rpl_connect.inc [creating M2]
|
||||
SET @old_debug= @@global.debug;
|
||||
connection M2;
|
||||
STOP SLAVE;
|
||||
SET @old_debug= @@global.debug;
|
||||
SET GLOBAL debug_dbug= "+d,dbug.rows_events_to_delay_relay_logging";
|
||||
START SLAVE IO_THREAD;
|
||||
include/wait_for_slave_io_to_start.inc
|
||||
|
@ -34,10 +34,11 @@ START SLAVE IO_THREAD;
|
||||
include/wait_for_slave_io_error.inc [errno=1595,1743]
|
||||
connection master;
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event2_set";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug;
|
||||
SET GLOBAL master_verify_checksum=1;
|
||||
# 5. Slave. Corruption in network
|
||||
connection slave;
|
||||
SET @saved_dbug_slave = @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug="+d,corrupt_queue_event";
|
||||
START SLAVE IO_THREAD;
|
||||
include/wait_for_slave_io_error.inc [errno=1595,1743]
|
||||
@ -47,7 +48,7 @@ SET GLOBAL debug_dbug="+d,corrupt_read_log_event_char";
|
||||
START SLAVE SQL_THREAD;
|
||||
include/wait_for_slave_sql_error.inc [errno=1593]
|
||||
SET GLOBAL debug_dbug="-d,corrupt_read_log_event_char";
|
||||
SET GLOBAL debug_dbug= "";
|
||||
SET GLOBAL debug_dbug=@saved_dbug_slave;
|
||||
# 7. Seek diff for tables on master and slave
|
||||
connection slave;
|
||||
include/start_slave.inc
|
||||
@ -60,5 +61,4 @@ set @@global.debug_dbug = @saved_dbug;
|
||||
SET GLOBAL master_verify_checksum = @old_master_verify_checksum;
|
||||
DROP TABLE t1;
|
||||
connection slave;
|
||||
set @@global.debug_dbug = @saved_dbug;
|
||||
include/rpl_end.inc
|
||||
|
@ -26,6 +26,7 @@ CHANGE MASTER TO IGNORE_DOMAIN_IDS=(), MASTER_USE_GTID=slave_pos;
|
||||
include/start_slave.inc
|
||||
DO_DOMAIN_IDS (AFTER) :
|
||||
IGNORE_DOMAIN_IDS (AFTER) :
|
||||
SET @saved_dbug = @@GLOBAL.debug_dbug;
|
||||
SET @@global.debug_dbug="+d,kill_slave_io_before_commit";
|
||||
connection master;
|
||||
START TRANSACTION;
|
||||
@ -414,4 +415,5 @@ connection slave;
|
||||
include/stop_slave.inc
|
||||
CHANGE MASTER TO DO_DOMAIN_IDS=(), IGNORE_DOMAIN_IDS=();
|
||||
include/start_slave.inc
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
include/rpl_end.inc
|
||||
|
@ -37,7 +37,6 @@ IGNORE_DOMAIN_IDS (AFTER) : 1
|
||||
connection master;
|
||||
include/rpl_start_server.inc [server_number=1]
|
||||
# Master has restarted successfully
|
||||
set @@global.debug_dbug="-d";
|
||||
connection slave;
|
||||
include/stop_slave.inc
|
||||
include/start_slave.inc
|
||||
|
@ -27,7 +27,7 @@ a
|
||||
connection server_1;
|
||||
include/kill_binlog_dump_threads.inc
|
||||
INSERT INTO t1 VALUES (10);
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug="+d,dummy_disable_default_dbug_output";
|
||||
SET GLOBAL debug_dbug="+d,gtid_force_reconnect_at_10_1_100";
|
||||
connection server_2;
|
||||
|
@ -2,10 +2,10 @@ include/master-slave.inc
|
||||
[connection master]
|
||||
connection master;
|
||||
set @old_master_binlog_checksum= @@global.binlog_checksum;
|
||||
set @old_slave_dbug= @@global.debug_dbug;
|
||||
connection slave;
|
||||
include/stop_slave.inc
|
||||
# Test slave with no capability gets dummy event, which is ignored.
|
||||
set @old_dbug= @@global.debug_dbug;
|
||||
SET @@global.debug_dbug='+d,simulate_slave_capability_none';
|
||||
include/start_slave.inc
|
||||
connection master;
|
||||
@ -50,7 +50,7 @@ slave-relay-bin.000005 # Annotate_rows # # INSERT INTO t1 /* A comment just to m
|
||||
slave-relay-bin.000005 # Table_map # # table_id: # (test.t1)
|
||||
slave-relay-bin.000005 # Write_rows_v1 # # table_id: # flags: STMT_END_F
|
||||
slave-relay-bin.000005 # Query # # COMMIT
|
||||
set @@global.debug_dbug= @old_slave_dbug;
|
||||
set @@global.debug_dbug= @old_dbug;
|
||||
# Test dummy event is checksummed correctly.
|
||||
connection master;
|
||||
set @@global.binlog_checksum = CRC32;
|
||||
@ -148,10 +148,10 @@ select @@global.log_slave_updates;
|
||||
select @@global.replicate_annotate_row_events;
|
||||
@@global.replicate_annotate_row_events
|
||||
1
|
||||
set @@global.debug_dbug= @old_slave_dbug;
|
||||
Clean up.
|
||||
connection master;
|
||||
set @@global.binlog_checksum = @old_master_binlog_checksum;
|
||||
DROP TABLE t1, t2;
|
||||
connection slave;
|
||||
set @@global.debug_dbug= @old_dbug;
|
||||
include/rpl_end.inc
|
||||
|
@ -1226,7 +1226,6 @@ a
|
||||
45
|
||||
46
|
||||
include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug=@old_dbug;
|
||||
SET DEBUG_SYNC= 'RESET';
|
||||
SET GLOBAL slave_parallel_threads=0;
|
||||
SET GLOBAL slave_parallel_threads=10;
|
||||
@ -1512,7 +1511,7 @@ SET GLOBAL slave_parallel_threads=10;
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_analyze_table_sleep';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10000;
|
||||
ANALYZE TABLE t2;
|
||||
@ -1521,7 +1520,7 @@ test.t2 analyze status OK
|
||||
INSERT INTO t3 VALUES (120, 0);
|
||||
SET @commit_id= 10001;
|
||||
INSERT INTO t3 VALUES (121, 0);
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a >= 120 ORDER BY a;
|
||||
a b
|
||||
120 0
|
||||
@ -1543,7 +1542,7 @@ include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_record_gtid_serverid_100_sleep';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @old_server_id= @@SESSION.server_id;
|
||||
SET SESSION server_id= 100;
|
||||
@ -1553,7 +1552,7 @@ SET SESSION server_id= @old_server_id;
|
||||
INSERT INTO t3 VALUES (130, 0);
|
||||
SET @commit_id= 10011;
|
||||
INSERT INTO t3 VALUES (131, 0);
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a >= 130 ORDER BY a;
|
||||
a b
|
||||
130 0
|
||||
@ -1579,7 +1578,7 @@ include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_mdev8031';
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10200;
|
||||
INSERT INTO t3 VALUES (203, 1);
|
||||
@ -1600,7 +1599,7 @@ UPDATE t3 SET b=b+1 WHERE a=204;
|
||||
UPDATE t3 SET b=b+1 WHERE a=203;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
UPDATE t3 SET b=b+1 WHERE a=205;
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
a b
|
||||
201 3
|
||||
@ -1630,11 +1629,11 @@ SET GLOBAL debug_dbug= '+d,inject_retry_event_group_open_binlog_kill';
|
||||
SET @old_max= @@GLOBAL.max_relay_log_size;
|
||||
SET GLOBAL max_relay_log_size= 4096;
|
||||
connection server_1;
|
||||
SET @old_dbug= @@SESSION.debug_dbug;
|
||||
SET @old_dbug_slave= @@SESSION.debug_dbug;
|
||||
SET SESSION debug_dbug="+d,binlog_force_commit_id";
|
||||
SET @commit_id= 10210;
|
||||
Omit long queries that cause relaylog rotations and transaction retries...
|
||||
SET SESSION debug_dbug=@old_dbug;
|
||||
SET SESSION debug_dbug=@old_dbug_slave;
|
||||
SELECT * FROM t3 WHERE a>=200 ORDER BY a;
|
||||
a b
|
||||
201 6
|
||||
@ -1654,7 +1653,7 @@ a b
|
||||
204 7
|
||||
205 5
|
||||
include/stop_slave.inc
|
||||
SET GLOBAL debug_dbug= @old_debg;
|
||||
SET GLOBAL debug_dbug= @old_dbug;
|
||||
SET GLOBAL max_relay_log_size= @old_max;
|
||||
include/start_slave.inc
|
||||
*** MDEV-8725: Assertion on ROLLBACK statement in the binary log ***
|
||||
|
@ -4,7 +4,7 @@ connection server_2;
|
||||
include/stop_slave.inc
|
||||
SET @old_parallel_threads=@@GLOBAL.slave_parallel_threads;
|
||||
SET @old_parallel_mode=@@GLOBAL.slave_parallel_mode;
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL slave_parallel_mode='optimistic';
|
||||
SET GLOBAL slave_parallel_threads= 3;
|
||||
CHANGE MASTER TO master_use_gtid=slave_pos;
|
||||
|
@ -352,7 +352,7 @@ include/save_master_gtid.inc
|
||||
connection server_2;
|
||||
include/sync_with_master_gtid.inc
|
||||
include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_analyze_table_sleep';
|
||||
connection server_1;
|
||||
ALTER TABLE t2 COMMENT "123abc";
|
||||
|
@ -6,6 +6,7 @@ call mtr.add_suppression("Unsafe statement written to the binary log using state
|
||||
create table tm (a int auto_increment primary key) engine=myisam;
|
||||
create table ti (a int auto_increment primary key) engine=innodb;
|
||||
connection slave;
|
||||
SET @saved_dbug = @@GLOBAL.debug_dbug;
|
||||
set @@global.debug_dbug="+d,stop_slave_middle_group";
|
||||
connection master;
|
||||
begin;
|
||||
@ -74,7 +75,7 @@ two
|
||||
select max(a) as one from ti;
|
||||
one
|
||||
1
|
||||
set @@global.debug_dbug="-d";
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
include/rpl_reset.inc
|
||||
connection master;
|
||||
drop table tm, ti;
|
||||
|
@ -22,10 +22,9 @@
|
||||
# The parameter reflects binlog-row-event-max-size @cnf.
|
||||
--let $row_size=1024
|
||||
|
||||
SET @old_debug= @@global.debug;
|
||||
|
||||
--connection M2
|
||||
STOP SLAVE;
|
||||
SET @old_debug= @@global.debug;
|
||||
SET GLOBAL debug_dbug= "+d,dbug.rows_events_to_delay_relay_logging";
|
||||
START SLAVE IO_THREAD;
|
||||
--source include/wait_for_slave_io_to_start.inc
|
||||
|
@ -35,6 +35,7 @@ let $ignore_domain_ids_after= query_get_value(SHOW SLAVE STATUS, Replicate_Ignor
|
||||
--echo DO_DOMAIN_IDS (AFTER) : $do_domain_ids_after
|
||||
--echo IGNORE_DOMAIN_IDS (AFTER) : $ignore_domain_ids_after
|
||||
|
||||
SET @saved_dbug = @@GLOBAL.debug_dbug;
|
||||
SET @@global.debug_dbug="+d,kill_slave_io_before_commit";
|
||||
|
||||
connection master;
|
||||
@ -379,5 +380,5 @@ connection slave;
|
||||
--source include/stop_slave.inc
|
||||
CHANGE MASTER TO DO_DOMAIN_IDS=(), IGNORE_DOMAIN_IDS=();
|
||||
--source include/start_slave.inc
|
||||
|
||||
SET @@GLOBAL.debug_dbug = @saved_dbug;
|
||||
--source include/rpl_end.inc
|
||||
|
@ -64,7 +64,6 @@ connection master;
|
||||
#--exec echo "restart" > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
|
||||
--source include/wait_until_connected_again.inc
|
||||
--echo # Master has restarted successfully
|
||||
set @@global.debug_dbug="-d";
|
||||
save_master_pos;
|
||||
|
||||
--connection slave
|
||||
|
@ -42,7 +42,7 @@ SELECT * FROM t1 ORDER BY a;
|
||||
# interfere with our DBUG error injection.
|
||||
--source include/kill_binlog_dump_threads.inc
|
||||
INSERT INTO t1 VALUES (10);
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug="+d,dummy_disable_default_dbug_output";
|
||||
SET GLOBAL debug_dbug="+d,gtid_force_reconnect_at_10_1_100";
|
||||
--save_master_pos
|
||||
|
@ -5,9 +5,7 @@
|
||||
--source include/master-slave.inc
|
||||
|
||||
connection master;
|
||||
|
||||
set @old_master_binlog_checksum= @@global.binlog_checksum;
|
||||
set @old_slave_dbug= @@global.debug_dbug;
|
||||
|
||||
# MDEV-4475: Cannot replicate to old server when binlog contains
|
||||
# empty Gtid_list event
|
||||
@ -16,6 +14,7 @@ set @old_slave_dbug= @@global.debug_dbug;
|
||||
connection slave;
|
||||
--source include/stop_slave.inc
|
||||
--echo # Test slave with no capability gets dummy event, which is ignored.
|
||||
set @old_dbug= @@global.debug_dbug;
|
||||
SET @@global.debug_dbug='+d,simulate_slave_capability_none';
|
||||
--source include/start_slave.inc
|
||||
|
||||
@ -52,7 +51,7 @@ let $binlog_file= query_get_value(SHOW SLAVE STATUS, Relay_Log_File, 1);
|
||||
let $binlog_start= $relaylog_start;
|
||||
let $binlog_limit=0,10;
|
||||
--source include/show_relaylog_events.inc
|
||||
set @@global.debug_dbug= @old_slave_dbug;
|
||||
set @@global.debug_dbug= @old_dbug;
|
||||
|
||||
--echo # Test dummy event is checksummed correctly.
|
||||
|
||||
@ -150,11 +149,10 @@ let $binlog_limit=0,5;
|
||||
select @@global.log_slave_updates;
|
||||
select @@global.replicate_annotate_row_events;
|
||||
|
||||
set @@global.debug_dbug= @old_slave_dbug;
|
||||
|
||||
--echo Clean up.
|
||||
connection master;
|
||||
set @@global.binlog_checksum = @old_master_binlog_checksum;
|
||||
DROP TABLE t1, t2;
|
||||
sync_slave_with_master;
|
||||
set @@global.debug_dbug= @old_dbug;
|
||||
--source include/rpl_end.inc
|
||||
|
@ -325,7 +325,7 @@ INSERT INTO t2 VALUES (1,1), (2,1), (3,1), (4,1), (5,1);
|
||||
--connection server_2
|
||||
--source include/sync_with_master_gtid.inc
|
||||
--source include/stop_slave.inc
|
||||
SET @old_dbug= @@GLOBAL.debug_dbug;
|
||||
SET @old_debug= @@GLOBAL.debug_dbug;
|
||||
SET GLOBAL debug_dbug= '+d,inject_analyze_table_sleep';
|
||||
|
||||
--connection server_1
|
||||
|
@ -3,10 +3,10 @@
|
||||
# For details look into extra/rpl_tests/rpl_lower_case_table_names.test
|
||||
#
|
||||
|
||||
-- source include/have_binlog_format_mixed_or_statement.inc
|
||||
-- source include/master-slave.inc
|
||||
-- source include/have_innodb.inc
|
||||
-- source include/not_windows.inc
|
||||
-- source include/have_binlog_format_mixed_or_statement.inc
|
||||
|
||||
-- let $engine=InnoDB
|
||||
-- source extra/rpl_tests/rpl_lower_case_table_names.test
|
||||
|
@ -1,55 +1,55 @@
|
||||
SET @old_debug = @@GLOBAL.debug;
|
||||
SET @old_debug = @@GLOBAL.debug_dbug;
|
||||
SET debug_dbug= 'T';
|
||||
select @@debug;
|
||||
@@debug
|
||||
select @@debug_dbug;
|
||||
@@debug_dbug
|
||||
T
|
||||
SET debug_dbug= '+P';
|
||||
select @@debug;
|
||||
@@debug
|
||||
select @@debug_dbug;
|
||||
@@debug_dbug
|
||||
P:T
|
||||
SET debug_dbug= '-P';
|
||||
select @@debug;
|
||||
@@debug
|
||||
select @@debug_dbug;
|
||||
@@debug_dbug
|
||||
T
|
||||
SELECT @@session.debug, @@global.debug;
|
||||
@@session.debug @@global.debug
|
||||
SELECT @@session.debug_dbug, @@global.debug_dbug;
|
||||
@@session.debug_dbug @@global.debug_dbug
|
||||
T
|
||||
SET SESSION debug_dbug= '';
|
||||
SELECT @@session.debug, @@global.debug;
|
||||
@@session.debug @@global.debug
|
||||
SELECT @@session.debug_dbug, @@global.debug_dbug;
|
||||
@@session.debug_dbug @@global.debug_dbug
|
||||
|
||||
#
|
||||
# Bug #52629: memory leak from sys_var_thd_dbug in
|
||||
# binlog.binlog_write_error
|
||||
#
|
||||
SET GLOBAL debug_dbug='d,injecting_fault_writing';
|
||||
SELECT @@global.debug;
|
||||
@@global.debug
|
||||
SELECT @@global.debug_dbug;
|
||||
@@global.debug_dbug
|
||||
d,injecting_fault_writing
|
||||
SET GLOBAL debug_dbug='';
|
||||
SELECT @@global.debug;
|
||||
@@global.debug
|
||||
SELECT @@global.debug_dbug;
|
||||
@@global.debug_dbug
|
||||
|
||||
SET GLOBAL debug_dbug=@old_debug;
|
||||
#
|
||||
# Bug #56709: Memory leaks at running the 5.1 test suite
|
||||
#
|
||||
SET @old_local_debug = @@debug;
|
||||
SET @old_local_debug = @@debug_dbug;
|
||||
SET @@debug_dbug='d,foo';
|
||||
SELECT @@debug;
|
||||
@@debug
|
||||
SELECT @@debug_dbug;
|
||||
@@debug_dbug
|
||||
d,foo
|
||||
SET @@debug_dbug='';
|
||||
SELECT @@debug;
|
||||
@@debug
|
||||
SELECT @@debug_dbug;
|
||||
@@debug_dbug
|
||||
|
||||
SET @@debug_dbug= @old_local_debug;
|
||||
End of 5.1 tests
|
||||
#
|
||||
# Bug#46165 server crash in dbug
|
||||
#
|
||||
SET @old_globaldebug = @@global.debug;
|
||||
SET @old_sessiondebug= @@session.debug;
|
||||
SET @old_globaldebug = @@global.debug_dbug;
|
||||
SET @old_sessiondebug= @@session.debug_dbug;
|
||||
# Test 1 - Bug test case, single connection
|
||||
SET GLOBAL debug_dbug= '+O,MYSQL_TMP_DIR/bug46165.1.trace';
|
||||
SET SESSION debug_dbug= '-d:-t:-i';
|
||||
|
@ -1,27 +1,27 @@
|
||||
--source include/have_debug.inc
|
||||
|
||||
SET @old_debug = @@GLOBAL.debug;
|
||||
SET @old_debug = @@GLOBAL.debug_dbug;
|
||||
|
||||
#
|
||||
# Bug#34678 @@debug variable's incremental mode
|
||||
# Bug#34678 @@debug_dbug variable's incremental mode
|
||||
#
|
||||
|
||||
SET debug_dbug= 'T';
|
||||
select @@debug;
|
||||
select @@debug_dbug;
|
||||
SET debug_dbug= '+P';
|
||||
select @@debug;
|
||||
select @@debug_dbug;
|
||||
SET debug_dbug= '-P';
|
||||
select @@debug;
|
||||
select @@debug_dbug;
|
||||
|
||||
#
|
||||
# Bug#38054: "SET SESSION debug" modifies @@global.debug variable
|
||||
# Bug#38054: "SET SESSION debug" modifies @@global.debug_dbug variable
|
||||
#
|
||||
|
||||
SELECT @@session.debug, @@global.debug;
|
||||
SELECT @@session.debug_dbug, @@global.debug_dbug;
|
||||
|
||||
SET SESSION debug_dbug= '';
|
||||
|
||||
SELECT @@session.debug, @@global.debug;
|
||||
SELECT @@session.debug_dbug, @@global.debug_dbug;
|
||||
|
||||
--echo #
|
||||
--echo # Bug #52629: memory leak from sys_var_thd_dbug in
|
||||
@ -29,9 +29,9 @@ SELECT @@session.debug, @@global.debug;
|
||||
--echo #
|
||||
|
||||
SET GLOBAL debug_dbug='d,injecting_fault_writing';
|
||||
SELECT @@global.debug;
|
||||
SELECT @@global.debug_dbug;
|
||||
SET GLOBAL debug_dbug='';
|
||||
SELECT @@global.debug;
|
||||
SELECT @@global.debug_dbug;
|
||||
|
||||
SET GLOBAL debug_dbug=@old_debug;
|
||||
|
||||
@ -39,12 +39,12 @@ SET GLOBAL debug_dbug=@old_debug;
|
||||
--echo # Bug #56709: Memory leaks at running the 5.1 test suite
|
||||
--echo #
|
||||
|
||||
SET @old_local_debug = @@debug;
|
||||
SET @old_local_debug = @@debug_dbug;
|
||||
|
||||
SET @@debug_dbug='d,foo';
|
||||
SELECT @@debug;
|
||||
SELECT @@debug_dbug;
|
||||
SET @@debug_dbug='';
|
||||
SELECT @@debug;
|
||||
SELECT @@debug_dbug;
|
||||
|
||||
SET @@debug_dbug= @old_local_debug;
|
||||
|
||||
@ -55,8 +55,8 @@ SET @@debug_dbug= @old_local_debug;
|
||||
--echo # Bug#46165 server crash in dbug
|
||||
--echo #
|
||||
|
||||
SET @old_globaldebug = @@global.debug;
|
||||
SET @old_sessiondebug= @@session.debug;
|
||||
SET @old_globaldebug = @@global.debug_dbug;
|
||||
SET @old_sessiondebug= @@session.debug_dbug;
|
||||
|
||||
--echo # Test 1 - Bug test case, single connection
|
||||
--replace_result $MYSQL_TMP_DIR MYSQL_TMP_DIR
|
||||
|
Reference in New Issue
Block a user