Commit 9303ecd0 authored by unknown's avatar unknown

MDEV-26: Global transaction ID.

Fix some test case races and .result file updates, found with Buildbot.
parent b0389850
...@@ -16,11 +16,12 @@ insert into t1 values (1, 1, 1);; ...@@ -16,11 +16,12 @@ insert into t1 values (1, 1, 1);;
set debug_sync='now SIGNAL go'; set debug_sync='now SIGNAL go';
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
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 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t2 values (1) master-bin.000001 # Query # # use `test`; insert into t2 values (1)
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; alter table t1 enable keys master-bin.000001 # Query # # use `test`; alter table t1 enable keys
master-bin.000001 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t1 values (1, 1, 1) master-bin.000001 # Query # # use `test`; insert into t1 values (1, 1, 1)
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
drop tables t1, t2; drop tables t1, t2;
...@@ -59,19 +60,28 @@ set debug_sync='alter_table_before_main_binlog SIGNAL parked WAIT_FOR go'; ...@@ -59,19 +60,28 @@ set debug_sync='alter_table_before_main_binlog SIGNAL parked WAIT_FOR go';
set debug_sync='RESET'; set debug_sync='RESET';
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
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 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; alter table t1 change i c char(10) default 'Test1' master-bin.000001 # Query # # use `test`; alter table t1 change i c char(10) default 'Test1'
master-bin.000001 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t1 values () master-bin.000001 # Query # # use `test`; insert into t1 values ()
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; alter table t1 change c vc varchar(100) default 'Test2' master-bin.000001 # Query # # use `test`; alter table t1 change c vc varchar(100) default 'Test2'
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; rename table t1 to t2 master-bin.000001 # Query # # use `test`; rename table t1 to t2
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; create table t1 (i int) master-bin.000001 # Query # # use `test`; create table t1 (i int)
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; alter table t1 change i c char(10) default 'Test3', rename to t2 master-bin.000001 # Query # # use `test`; alter table t1 change i c char(10) default 'Test3', rename to t2
master-bin.000001 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t2 values() master-bin.000001 # Query # # use `test`; insert into t2 values()
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; alter table t2 change c vc varchar(100) default 'Test2', rename to t1 master-bin.000001 # Query # # use `test`; alter table t2 change c vc varchar(100) default 'Test2', rename to t1
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; rename table t1 to t3 master-bin.000001 # Query # # use `test`; rename table t1 to t3
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t3` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t3` /* generated by server */
End of 5.1 tests End of 5.1 tests
...@@ -188,11 +188,14 @@ t2 CREATE TABLE `t2` ( ...@@ -188,11 +188,14 @@ t2 CREATE TABLE `t2` (
drop table t2; drop table t2;
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
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 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t1 values (1) master-bin.000001 # Query # # use `test`; insert into t1 values (1)
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; create table t2 like t1 master-bin.000001 # Query # # use `test`; create table t2 like t1
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
create table t1 (i int); create table t1 (i int);
set debug_sync='create_table_like_before_binlog SIGNAL parked WAIT_FOR go'; set debug_sync='create_table_like_before_binlog SIGNAL parked WAIT_FOR go';
...@@ -216,13 +219,20 @@ drop table t2; ...@@ -216,13 +219,20 @@ drop table t2;
set debug_sync='RESET'; set debug_sync='RESET';
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
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 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; create table t2 like t1 master-bin.000001 # Query # # use `test`; create table t2 like t1
master-bin.000001 # Query # # BEGIN master-bin.000001 # Gtid # # BEGIN GTID #-#-#
master-bin.000001 # Query # # use `test`; insert into t2 values (1) master-bin.000001 # Query # # use `test`; insert into t2 values (1)
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; create table t2 like t1 master-bin.000001 # Query # # use `test`; create table t2 like t1
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; create table t2 like t1 master-bin.000001 # Query # # use `test`; create table t2 like t1
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t1` /* generated by server */
master-bin.000001 # Gtid # # GTID #-#-#
master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */ master-bin.000001 # Query # # use `test`; DROP TABLE `t2` /* generated by server */
...@@ -154,6 +154,10 @@ def mysql proxies_priv Proxied_user 4 NO char 16 48 NULL NULL NULL utf8 utf8_bi ...@@ -154,6 +154,10 @@ def mysql proxies_priv Proxied_user 4 NO char 16 48 NULL NULL NULL utf8 utf8_bi
def mysql proxies_priv Timestamp 7 CURRENT_TIMESTAMP NO timestamp NULL NULL NULL NULL 0 NULL NULL timestamp on update CURRENT_TIMESTAMP def mysql proxies_priv Timestamp 7 CURRENT_TIMESTAMP NO timestamp NULL NULL NULL NULL 0 NULL NULL timestamp on update CURRENT_TIMESTAMP
def mysql proxies_priv User 2 NO char 16 48 NULL NULL NULL utf8 utf8_bin char(16) PRI def mysql proxies_priv User 2 NO char 16 48 NULL NULL NULL utf8 utf8_bin char(16) PRI
def mysql proxies_priv With_grant 5 0 NO tinyint NULL NULL 3 0 NULL NULL NULL tinyint(1) def mysql proxies_priv With_grant 5 0 NO tinyint NULL NULL 3 0 NULL NULL NULL tinyint(1)
def mysql rpl_slave_state domain_id 1 NULL NO int NULL NULL 10 0 NULL NULL NULL int(10) unsigned PRI
def mysql rpl_slave_state seq_no 4 NULL NO bigint NULL NULL 20 0 NULL NULL NULL bigint(20) unsigned
def mysql rpl_slave_state server_id 3 NULL NO int NULL NULL 10 0 NULL NULL NULL int(10) unsigned
def mysql rpl_slave_state sub_id 2 NULL NO bigint NULL NULL 20 0 NULL NULL NULL bigint(20) unsigned PRI
def mysql servers Db 3 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64) def mysql servers Db 3 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64)
def mysql servers Host 2 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64) def mysql servers Host 2 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64)
def mysql servers Owner 9 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64) def mysql servers Owner 9 NO char 64 192 NULL NULL NULL utf8 utf8_general_ci char(64)
...@@ -465,6 +469,10 @@ NULL mysql procs_priv Timestamp timestamp NULL NULL NULL NULL timestamp ...@@ -465,6 +469,10 @@ NULL mysql procs_priv Timestamp timestamp NULL NULL NULL NULL timestamp
NULL mysql proxies_priv With_grant tinyint NULL NULL NULL NULL tinyint(1) NULL mysql proxies_priv With_grant tinyint NULL NULL NULL NULL tinyint(1)
3.0000 mysql proxies_priv Grantor char 77 231 utf8 utf8_bin char(77) 3.0000 mysql proxies_priv Grantor char 77 231 utf8 utf8_bin char(77)
NULL mysql proxies_priv Timestamp timestamp NULL NULL NULL NULL timestamp NULL mysql proxies_priv Timestamp timestamp NULL NULL NULL NULL timestamp
NULL mysql rpl_slave_state domain_id int NULL NULL NULL NULL int(10) unsigned
NULL mysql rpl_slave_state sub_id bigint NULL NULL NULL NULL bigint(20) unsigned
NULL mysql rpl_slave_state server_id int NULL NULL NULL NULL int(10) unsigned
NULL mysql rpl_slave_state seq_no bigint NULL NULL NULL NULL bigint(20) unsigned
3.0000 mysql servers Server_name char 64 192 utf8 utf8_general_ci char(64) 3.0000 mysql servers Server_name char 64 192 utf8 utf8_general_ci char(64)
3.0000 mysql servers Host char 64 192 utf8 utf8_general_ci char(64) 3.0000 mysql servers Host char 64 192 utf8 utf8_general_ci char(64)
3.0000 mysql servers Db char 64 192 utf8 utf8_general_ci char(64) 3.0000 mysql servers Db char 64 192 utf8 utf8_general_ci char(64)
......
...@@ -52,6 +52,8 @@ def mysql proxies_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE ...@@ -52,6 +52,8 @@ def mysql proxies_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 2 User A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 2 User A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 3 Proxied_host A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 3 Proxied_host A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 4 Proxied_user A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 4 Proxied_user A #CARD# NULL NULL BTREE
def mysql rpl_slave_state 0 mysql PRIMARY 1 domain_id A #CARD# NULL NULL BTREE
def mysql rpl_slave_state 0 mysql PRIMARY 2 sub_id A #CARD# NULL NULL BTREE
def mysql servers 0 mysql PRIMARY 1 Server_name A #CARD# NULL NULL BTREE def mysql servers 0 mysql PRIMARY 1 Server_name A #CARD# NULL NULL BTREE
def mysql tables_priv 1 mysql Grantor 1 Grantor A #CARD# NULL NULL BTREE def mysql tables_priv 1 mysql Grantor 1 Grantor A #CARD# NULL NULL BTREE
def mysql tables_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE def mysql tables_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE
...@@ -119,6 +121,8 @@ def mysql proxies_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE ...@@ -119,6 +121,8 @@ def mysql proxies_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 2 User A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 2 User A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 3 Proxied_host A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 3 Proxied_host A #CARD# NULL NULL BTREE
def mysql proxies_priv 0 mysql PRIMARY 4 Proxied_user A #CARD# NULL NULL BTREE def mysql proxies_priv 0 mysql PRIMARY 4 Proxied_user A #CARD# NULL NULL BTREE
def mysql rpl_slave_state 0 mysql PRIMARY 1 domain_id A #CARD# NULL NULL BTREE
def mysql rpl_slave_state 0 mysql PRIMARY 2 sub_id A #CARD# NULL NULL BTREE
def mysql servers 0 mysql PRIMARY 1 Server_name A #CARD# NULL NULL BTREE def mysql servers 0 mysql PRIMARY 1 Server_name A #CARD# NULL NULL BTREE
def mysql tables_priv 1 mysql Grantor 1 Grantor A #CARD# NULL NULL BTREE def mysql tables_priv 1 mysql Grantor 1 Grantor A #CARD# NULL NULL BTREE
def mysql tables_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE def mysql tables_priv 0 mysql PRIMARY 1 Host A #CARD# NULL NULL BTREE
......
...@@ -26,6 +26,7 @@ def mysql PRIMARY mysql plugin PRIMARY KEY ...@@ -26,6 +26,7 @@ def mysql PRIMARY mysql plugin PRIMARY KEY
def mysql PRIMARY mysql proc PRIMARY KEY def mysql PRIMARY mysql proc PRIMARY KEY
def mysql PRIMARY mysql procs_priv PRIMARY KEY def mysql PRIMARY mysql procs_priv PRIMARY KEY
def mysql PRIMARY mysql proxies_priv PRIMARY KEY def mysql PRIMARY mysql proxies_priv PRIMARY KEY
def mysql PRIMARY mysql rpl_slave_state PRIMARY KEY
def mysql PRIMARY mysql servers PRIMARY KEY def mysql PRIMARY mysql servers PRIMARY KEY
def mysql PRIMARY mysql tables_priv PRIMARY KEY def mysql PRIMARY mysql tables_priv PRIMARY KEY
def mysql PRIMARY mysql table_stats PRIMARY KEY def mysql PRIMARY mysql table_stats PRIMARY KEY
...@@ -59,6 +60,7 @@ def mysql PRIMARY mysql plugin PRIMARY KEY ...@@ -59,6 +60,7 @@ def mysql PRIMARY mysql plugin PRIMARY KEY
def mysql PRIMARY mysql proc PRIMARY KEY def mysql PRIMARY mysql proc PRIMARY KEY
def mysql PRIMARY mysql procs_priv PRIMARY KEY def mysql PRIMARY mysql procs_priv PRIMARY KEY
def mysql PRIMARY mysql proxies_priv PRIMARY KEY def mysql PRIMARY mysql proxies_priv PRIMARY KEY
def mysql PRIMARY mysql rpl_slave_state PRIMARY KEY
def mysql PRIMARY mysql servers PRIMARY KEY def mysql PRIMARY mysql servers PRIMARY KEY
def mysql PRIMARY mysql tables_priv PRIMARY KEY def mysql PRIMARY mysql tables_priv PRIMARY KEY
def mysql PRIMARY mysql table_stats PRIMARY KEY def mysql PRIMARY mysql table_stats PRIMARY KEY
......
...@@ -405,6 +405,29 @@ user_comment User proxy privileges ...@@ -405,6 +405,29 @@ user_comment User proxy privileges
Separator ----------------------------------------------------- Separator -----------------------------------------------------
TABLE_CATALOG def TABLE_CATALOG def
TABLE_SCHEMA mysql TABLE_SCHEMA mysql
TABLE_NAME rpl_slave_state
TABLE_TYPE BASE TABLE
ENGINE MYISAM_OR_MARIA
VERSION 10
ROW_FORMAT Fixed
TABLE_ROWS #TBLR#
AVG_ROW_LENGTH #ARL#
DATA_LENGTH #DL#
MAX_DATA_LENGTH #MDL#
INDEX_LENGTH #IL#
DATA_FREE #DF#
AUTO_INCREMENT NULL
CREATE_TIME #CRT#
UPDATE_TIME #UT#
CHECK_TIME #CT#
TABLE_COLLATION latin1_swedish_ci
CHECKSUM NULL
CREATE_OPTIONS #CO#
TABLE_COMMENT #TC#
user_comment Replication slave GTID state
Separator -----------------------------------------------------
TABLE_CATALOG def
TABLE_SCHEMA mysql
TABLE_NAME servers TABLE_NAME servers
TABLE_TYPE BASE TABLE TABLE_TYPE BASE TABLE
ENGINE MYISAM_OR_MARIA ENGINE MYISAM_OR_MARIA
...@@ -1042,6 +1065,29 @@ user_comment User proxy privileges ...@@ -1042,6 +1065,29 @@ user_comment User proxy privileges
Separator ----------------------------------------------------- Separator -----------------------------------------------------
TABLE_CATALOG def TABLE_CATALOG def
TABLE_SCHEMA mysql TABLE_SCHEMA mysql
TABLE_NAME rpl_slave_state
TABLE_TYPE BASE TABLE
ENGINE MYISAM_OR_MARIA
VERSION 10
ROW_FORMAT Fixed
TABLE_ROWS #TBLR#
AVG_ROW_LENGTH #ARL#
DATA_LENGTH #DL#
MAX_DATA_LENGTH #MDL#
INDEX_LENGTH #IL#
DATA_FREE #DF#
AUTO_INCREMENT NULL
CREATE_TIME #CRT#
UPDATE_TIME #UT#
CHECK_TIME #CT#
TABLE_COLLATION latin1_swedish_ci
CHECKSUM NULL
CREATE_OPTIONS #CO#
TABLE_COMMENT #TC#
user_comment Replication slave GTID state
Separator -----------------------------------------------------
TABLE_CATALOG def
TABLE_SCHEMA mysql
TABLE_NAME servers TABLE_NAME servers
TABLE_TYPE BASE TABLE TABLE_TYPE BASE TABLE
ENGINE MYISAM_OR_MARIA ENGINE MYISAM_OR_MARIA
......
...@@ -23,6 +23,7 @@ where file_name like "%master-%" order by file_name; ...@@ -23,6 +23,7 @@ where file_name like "%master-%" order by file_name;
FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE
master-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY master-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY
master-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY master-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY
master-bin.state wait/io/file/sql/binlog_state NONE NONE NONE NONE
select * from performance_schema.file_summary_by_instance select * from performance_schema.file_summary_by_instance
where file_name like "%slave-%" order by file_name; where file_name like "%slave-%" order by file_name;
FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE
...@@ -39,6 +40,7 @@ where event_name like "%binlog%" order by file_name; ...@@ -39,6 +40,7 @@ where event_name like "%binlog%" order by file_name;
FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE
master-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY master-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY
master-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY master-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY
master-bin.state wait/io/file/sql/binlog_state NONE NONE NONE NONE
select select
EVENT_NAME, EVENT_NAME,
if (count_read > 0, "MANY", "NONE") as COUNT_READ, if (count_read > 0, "MANY", "NONE") as COUNT_READ,
...@@ -101,6 +103,7 @@ order by file_name; ...@@ -101,6 +103,7 @@ order by file_name;
FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE
slave-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY slave-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY
slave-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY slave-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY
slave-bin.state wait/io/file/sql/binlog_state NONE NONE NONE NONE
slave-relay-bin.000001 wait/io/file/sql/relaylog MANY MANY MANY MANY slave-relay-bin.000001 wait/io/file/sql/relaylog MANY MANY MANY MANY
slave-relay-bin.000002 wait/io/file/sql/relaylog MANY MANY MANY MANY slave-relay-bin.000002 wait/io/file/sql/relaylog MANY MANY MANY MANY
slave-relay-bin.index wait/io/file/sql/relaylog_index MANY MANY MANY MANY slave-relay-bin.index wait/io/file/sql/relaylog_index MANY MANY MANY MANY
...@@ -117,6 +120,7 @@ where event_name like "%binlog%" order by file_name; ...@@ -117,6 +120,7 @@ where event_name like "%binlog%" order by file_name;
FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE FILE_NAME EVENT_NAME COUNT_READ COUNT_WRITE SUM_NUMBER_OF_BYTES_READ SUM_NUMBER_OF_BYTES_WRITE
slave-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY slave-bin.000001 wait/io/file/sql/binlog MANY MANY MANY MANY
slave-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY slave-bin.index wait/io/file/sql/binlog_index NONE MANY NONE MANY
slave-bin.state wait/io/file/sql/binlog_state NONE NONE NONE NONE
select select
EVENT_NAME, EVENT_NAME,
if (count_read > 0, "MANY", "NONE") as COUNT_READ, if (count_read > 0, "MANY", "NONE") as COUNT_READ,
......
...@@ -99,12 +99,16 @@ connection server_2; ...@@ -99,12 +99,16 @@ connection server_2;
--replace_result $MASTER_MYPORT MASTER_MYPORT --replace_result $MASTER_MYPORT MASTER_MYPORT
eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $MASTER_MYPORT; eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $MASTER_MYPORT;
--source include/start_slave.inc --source include/start_slave.inc
--let $wait_condition= SELECT COUNT(*) = 7 FROM t2
--source include/wait_condition.inc
connection server_3; connection server_3;
--source include/stop_slave.inc --source include/stop_slave.inc
--replace_result $SLAVE_MYPORT SLAVE_MYPORT --replace_result $SLAVE_MYPORT SLAVE_MYPORT
eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SLAVE_MYPORT; eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SLAVE_MYPORT;
--source include/start_slave.inc --source include/start_slave.inc
--let $wait_condition= SELECT COUNT(*) = 7 FROM t2
--source include/wait_condition.inc
connection server_4; connection server_4;
--source include/stop_slave.inc --source include/stop_slave.inc
......
...@@ -35,6 +35,7 @@ SELECT * FROM t1; ...@@ -35,6 +35,7 @@ SELECT * FROM t1;
--echo *** Test that master gives error when slave asks for empty gtid pos and binlog files have been purged. *** --echo *** Test that master gives error when slave asks for empty gtid pos and binlog files have been purged. ***
--connection server_1 --connection server_1
FLUSH LOGS; FLUSH LOGS;
--source include/wait_for_binlog_checkpoint.inc
INSERT INTO t1 VALUES (2); INSERT INTO t1 VALUES (2);
--save_master_pos --save_master_pos
PURGE BINARY LOGS TO 'master-bin.000003'; PURGE BINARY LOGS TO 'master-bin.000003';
......
...@@ -32,6 +32,7 @@ EOF ...@@ -32,6 +32,7 @@ EOF
--connection server_1 --connection server_1
FLUSH LOGS; FLUSH LOGS;
--source include/wait_for_binlog_checkpoint.inc
PURGE BINARY LOGS TO 'master-bin.000002'; PURGE BINARY LOGS TO 'master-bin.000002';
--source include/show_binary_logs.inc --source include/show_binary_logs.inc
INSERT INTO t1 VALUES (2); INSERT INTO t1 VALUES (2);
......
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