mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge romeo.(none):/home/bkroot/mysql-5.1-new-rpl
into romeo.(none):/home/bk/b22583-mysql-5.1-new-rpl
This commit is contained in:
@ -22,7 +22,7 @@ commit;
|
|||||||
# first COMMIT must be Query_log_event, second - Xid_log_event
|
# first COMMIT must be Query_log_event, second - Xid_log_event
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
drop table t1,t2;
|
drop table t1,t2;
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -44,10 +44,10 @@ commit;
|
|||||||
drop table t1;
|
drop table t1;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events in 'master-bin.000001' from 102;
|
show binlog events in 'master-bin.000001' from 105;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events in 'master-bin.000002' from 102;
|
show binlog events in 'master-bin.000002' from 105;
|
||||||
|
|
||||||
# Test of a too big SET INSERT_ID: see if the truncated value goes
|
# Test of a too big SET INSERT_ID: see if the truncated value goes
|
||||||
# into binlog (right), or the too big value (wrong); we look at the
|
# into binlog (right), or the too big value (wrong); we look at the
|
||||||
@ -82,7 +82,7 @@ DELETE FROM user WHERE host='localhost' AND user='@#@';
|
|||||||
use test;
|
use test;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
drop table t1,t2,t3,tt1;
|
drop table t1,t2,t3,tt1;
|
||||||
|
|
||||||
-- source extra/binlog_tests/binlog_insert_delayed.test
|
-- source extra/binlog_tests/binlog_insert_delayed.test
|
||||||
|
@ -25,7 +25,7 @@ inc $count;
|
|||||||
# the way
|
# the way
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
insert delayed into t1 values (null),(null),(null),(null);
|
insert delayed into t1 values (null),(null),(null),(null);
|
||||||
inc $count; inc $count; inc $count; inc $count;
|
inc $count; inc $count; inc $count; inc $count;
|
||||||
|
@ -28,7 +28,7 @@ SET @var1= x'8300';
|
|||||||
EXECUTE stmt1 USING @var1;
|
EXECUTE stmt1 USING @var1;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 102;
|
SHOW BINLOG EVENTS FROM 105;
|
||||||
SELECT HEX(f1) FROM t1;
|
SELECT HEX(f1) FROM t1;
|
||||||
DROP table t1;
|
DROP table t1;
|
||||||
# end test for bug#11338
|
# end test for bug#11338
|
||||||
|
@ -10,7 +10,7 @@ set @v=convert('abc' using ucs2);
|
|||||||
reset master;
|
reset master;
|
||||||
insert into t2 values (@v);
|
insert into t2 values (@v);
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
# more important than SHOW BINLOG EVENTS, mysqlbinlog (where we
|
# more important than SHOW BINLOG EVENTS, mysqlbinlog (where we
|
||||||
# absolutely need variables names to be quoted and strings to be
|
# absolutely need variables names to be quoted and strings to be
|
||||||
# escaped).
|
# escaped).
|
||||||
|
@ -31,7 +31,7 @@ commit;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -45,7 +45,7 @@ rollback;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -61,7 +61,7 @@ commit;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -79,7 +79,7 @@ select a from t1 order by a; # check that savepoints work :)
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# and when ROLLBACK is not explicit?
|
# and when ROLLBACK is not explicit?
|
||||||
delete from t1;
|
delete from t1;
|
||||||
@ -101,7 +101,7 @@ connection con2;
|
|||||||
select get_lock("a",10);
|
select get_lock("a",10);
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# and when not in a transact1on?
|
# and when not in a transact1on?
|
||||||
delete from t1;
|
delete from t1;
|
||||||
@ -113,7 +113,7 @@ insert into t2 select * from t1;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# Check that when the query updat1ng the MyISAM table is the first in the
|
# Check that when the query updat1ng the MyISAM table is the first in the
|
||||||
# transaction, we log it immediately.
|
# transaction, we log it immediately.
|
||||||
@ -126,13 +126,13 @@ begin;
|
|||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
insert into t1 values(11);
|
insert into t1 values(11);
|
||||||
commit;
|
commit;
|
||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
|
|
||||||
# Check that things work like before this BEGIN/ROLLBACK code was added,
|
# Check that things work like before this BEGIN/ROLLBACK code was added,
|
||||||
@ -151,7 +151,7 @@ commit;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -164,7 +164,7 @@ rollback;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -180,7 +180,7 @@ commit;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -198,7 +198,7 @@ select a from t1 order by a; # check that savepoints work :)
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# Test for BUG#5714, where a MyISAM update in the transaction used to
|
# Test for BUG#5714, where a MyISAM update in the transaction used to
|
||||||
# release row-level locks in InnoDB
|
# release row-level locks in InnoDB
|
||||||
@ -259,7 +259,7 @@ connection con3;
|
|||||||
select get_lock("lock1",60);
|
select get_lock("lock1",60);
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
do release_lock("lock1");
|
do release_lock("lock1");
|
||||||
drop table t0,t2;
|
drop table t0,t2;
|
||||||
|
|
||||||
@ -326,7 +326,7 @@ SELECT * from t2;
|
|||||||
DROP TABLE t1,t2;
|
DROP TABLE t1,t2;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
--replace_regex /table_id: [0-9]+/table_id: #/ /\/\* xid=.* \*\//\/* xid= *\//
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# Test for BUG#16559 (ROLLBACK should always have a zero error code in
|
# Test for BUG#16559 (ROLLBACK should always have a zero error code in
|
||||||
# binlog). Has to be here and not earlier, as the SELECTs influence
|
# binlog). Has to be here and not earlier, as the SELECTs influence
|
||||||
|
@ -82,7 +82,7 @@ show slave status;
|
|||||||
|
|
||||||
stop slave;
|
stop slave;
|
||||||
delete from t3;
|
delete from t3;
|
||||||
change master to master_log_pos=544; # the BEGIN log event
|
change master to master_log_pos=547; # the BEGIN log event
|
||||||
begin;
|
begin;
|
||||||
select * from t2 for update; # hold lock
|
select * from t2 for update; # hold lock
|
||||||
start slave;
|
start slave;
|
||||||
@ -107,7 +107,7 @@ set global max_relay_log_size=0;
|
|||||||
# This is really copy-paste of 2) of above
|
# This is really copy-paste of 2) of above
|
||||||
stop slave;
|
stop slave;
|
||||||
delete from t3;
|
delete from t3;
|
||||||
change master to master_log_pos=544;
|
change master to master_log_pos=547;
|
||||||
begin;
|
begin;
|
||||||
select * from t2 for update;
|
select * from t2 for update;
|
||||||
start slave;
|
start slave;
|
||||||
|
@ -42,13 +42,13 @@ select count(*) from t1;
|
|||||||
show binlog events;
|
show binlog events;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102 limit 1;
|
show binlog events from 105 limit 1;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102 limit 2;
|
show binlog events from 105 limit 2;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102 limit 2,1;
|
show binlog events from 105 limit 2,1;
|
||||||
flush logs;
|
flush logs;
|
||||||
|
|
||||||
# We need an extra update before doing save_master_pos.
|
# We need an extra update before doing save_master_pos.
|
||||||
|
@ -25,6 +25,6 @@ select * from mysqltest.t1;
|
|||||||
connection master;
|
connection master;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
drop database mysqltest;
|
drop database mysqltest;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
|
@ -115,7 +115,7 @@ drop database mysqltest2;
|
|||||||
drop database mysqltest3;
|
drop database mysqltest3;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
|
|
||||||
# Check that we can change global.collation_server (since 5.0.3)
|
# Check that we can change global.collation_server (since 5.0.3)
|
||||||
|
@ -111,7 +111,7 @@ drop database mysqltest2;
|
|||||||
drop database mysqltest3;
|
drop database mysqltest3;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
|
|
||||||
# Check that we can change global.collation_server (since 5.0.3)
|
# Check that we can change global.collation_server (since 5.0.3)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
--let $binlog_start=102
|
--let $binlog_start=105
|
||||||
--replace_result $binlog_start <binlog_start>
|
--replace_result $binlog_start <binlog_start>
|
||||||
--replace_column 2 # 4 # 5 #
|
--replace_column 2 # 4 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
|
@ -8,7 +8,7 @@ commit;
|
|||||||
begin;
|
begin;
|
||||||
insert t2 values (5);
|
insert t2 values (5);
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (a int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t1 (a int) engine=innodb
|
||||||
master-bin.000001 # Query 1 # use `test`; create table t2 (a int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t2 (a int) engine=innodb
|
||||||
@ -26,7 +26,7 @@ create table t1 (n int) engine=innodb;
|
|||||||
begin;
|
begin;
|
||||||
commit;
|
commit;
|
||||||
drop table t1;
|
drop table t1;
|
||||||
show binlog events in 'master-bin.000001' from 102;
|
show binlog events in 'master-bin.000001' from 105;
|
||||||
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 1 # use `test`; create table t1 (n int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t1 (n int) engine=innodb
|
||||||
master-bin.000001 # Query 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
@ -232,7 +232,7 @@ master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
|||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
||||||
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
||||||
show binlog events in 'master-bin.000002' from 102;
|
show binlog events in 'master-bin.000002' from 105;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000002 # Query 1 # use `test`; drop table t1
|
master-bin.000002 # Query 1 # use `test`; drop table t1
|
||||||
reset master;
|
reset master;
|
||||||
@ -254,7 +254,7 @@ INSERT INTO user SET host='localhost', user='@#@', password=password('Just a tes
|
|||||||
UPDATE user SET password=password('Another password') WHERE host='localhost' AND user='@#@';
|
UPDATE user SET password=password('Another password') WHERE host='localhost' AND user='@#@';
|
||||||
DELETE FROM user WHERE host='localhost' AND user='@#@';
|
DELETE FROM user WHERE host='localhost' AND user='@#@';
|
||||||
use test;
|
use test;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
master-bin.000001 # Query 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -279,7 +279,7 @@ set @@session.auto_increment_increment=1, @@session.auto_increment_offset=1;
|
|||||||
insert delayed into t1 values (207);
|
insert delayed into t1 values (207);
|
||||||
insert delayed into t1 values (null);
|
insert delayed into t1 values (null);
|
||||||
insert delayed into t1 values (300);
|
insert delayed into t1 values (300);
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
master-bin.000001 # Query 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
|
@ -3,10 +3,10 @@ create table t2 (c char(30)) charset=ucs2;
|
|||||||
set @v=convert('abc' using ucs2);
|
set @v=convert('abc' using ucs2);
|
||||||
reset master;
|
reset master;
|
||||||
insert into t2 values (@v);
|
insert into t2 values (@v);
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 102 Table_map 1 141 table_id: # (test.t2)
|
master-bin.000001 105 Table_map 1 144 table_id: # (test.t2)
|
||||||
master-bin.000001 141 Write_rows 1 231 table_id: # flags: STMT_END_F
|
master-bin.000001 144 Write_rows 1 234 table_id: # flags: STMT_END_F
|
||||||
flush logs;
|
flush logs;
|
||||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||||
|
@ -8,9 +8,9 @@ insert into t1 select * from t2;
|
|||||||
ERROR 23000: Duplicate entry '2' for key 'a'
|
ERROR 23000: Duplicate entry '2' for key 'a'
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Table_map 1 141 table_id: # (test.t1)
|
master-bin.000001 105 Table_map 1 144 table_id: # (test.t1)
|
||||||
master-bin.000001 141 Write_rows 1 175 table_id: # flags: STMT_END_F
|
master-bin.000001 144 Write_rows 1 178 table_id: # flags: STMT_END_F
|
||||||
select * from t1;
|
select * from t1;
|
||||||
a
|
a
|
||||||
1
|
1
|
||||||
@ -23,5 +23,5 @@ create table t2(unique(a)) select a from t1;
|
|||||||
ERROR 23000: Duplicate entry '1' for key 'a'
|
ERROR 23000: Duplicate entry '1' for key 'a'
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
@ -6,7 +6,7 @@ begin;
|
|||||||
insert into t1 values(1);
|
insert into t1 values(1);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -23,7 +23,7 @@ insert into t2 select * from t1;
|
|||||||
rollback;
|
rollback;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -43,7 +43,7 @@ rollback to savepoint my_savepoint;
|
|||||||
Warnings:
|
Warnings:
|
||||||
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -72,7 +72,7 @@ select a from t1 order by a;
|
|||||||
a
|
a
|
||||||
5
|
5
|
||||||
7
|
7
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -98,7 +98,7 @@ insert into t2 select * from t1;
|
|||||||
select get_lock("a",10);
|
select get_lock("a",10);
|
||||||
get_lock("a",10)
|
get_lock("a",10)
|
||||||
1
|
1
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -111,7 +111,7 @@ delete from t2;
|
|||||||
reset master;
|
reset master;
|
||||||
insert into t1 values(9);
|
insert into t1 values(9);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
@ -124,7 +124,7 @@ reset master;
|
|||||||
insert into t1 values(10);
|
insert into t1 values(10);
|
||||||
begin;
|
begin;
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
@ -133,7 +133,7 @@ master-bin.000001 # Table_map 1 # table_id: # (test.t2)
|
|||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
insert into t1 values(11);
|
insert into t1 values(11);
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
@ -152,7 +152,7 @@ begin;
|
|||||||
insert into t1 values(12);
|
insert into t1 values(12);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -167,7 +167,7 @@ begin;
|
|||||||
insert into t1 values(13);
|
insert into t1 values(13);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
rollback;
|
rollback;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -179,7 +179,7 @@ insert into t1 values(15);
|
|||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
rollback to savepoint my_savepoint;
|
rollback to savepoint my_savepoint;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -200,7 +200,7 @@ select a from t1 order by a;
|
|||||||
a
|
a
|
||||||
16
|
16
|
||||||
18
|
18
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -252,7 +252,7 @@ insert into t2 values (3);
|
|||||||
select get_lock("lock1",60);
|
select get_lock("lock1",60);
|
||||||
get_lock("lock1",60)
|
get_lock("lock1",60)
|
||||||
1
|
1
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
@ -355,7 +355,7 @@ SELECT * from t2;
|
|||||||
a b
|
a b
|
||||||
100 100
|
100 100
|
||||||
DROP TABLE t1,t2;
|
DROP TABLE t1,t2;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
|
@ -4,11 +4,11 @@ insert into t1 values (1,2);
|
|||||||
commit;
|
commit;
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: #, Binlog ver: #
|
master-bin.000001 4 Format_desc 1 105 Server ver: #, Binlog ver: #
|
||||||
master-bin.000001 102 Query 1 209 use `test`; create table t1 (a int, b int) engine=innodb
|
master-bin.000001 105 Query 1 212 use `test`; create table t1 (a int, b int) engine=innodb
|
||||||
master-bin.000001 209 Query 1 277 use `test`; BEGIN
|
master-bin.000001 212 Query 1 280 use `test`; BEGIN
|
||||||
master-bin.000001 277 Query 1 90 use `test`; insert into t1 values (1,2)
|
master-bin.000001 280 Query 1 90 use `test`; insert into t1 values (1,2)
|
||||||
master-bin.000001 367 Xid 1 394 COMMIT /* XID */
|
master-bin.000001 370 Xid 1 397 COMMIT /* XID */
|
||||||
drop table t1;
|
drop table t1;
|
||||||
drop table if exists t1, t2;
|
drop table if exists t1, t2;
|
||||||
reset master;
|
reset master;
|
||||||
@ -20,7 +20,7 @@ commit;
|
|||||||
begin;
|
begin;
|
||||||
insert t2 values (5);
|
insert t2 values (5);
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (a int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t1 (a int) engine=innodb
|
||||||
master-bin.000001 # Query 1 # use `test`; create table t2 (a int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t2 (a int) engine=innodb
|
||||||
@ -36,7 +36,7 @@ create table t1 (n int) engine=innodb;
|
|||||||
begin;
|
begin;
|
||||||
commit;
|
commit;
|
||||||
drop table t1;
|
drop table t1;
|
||||||
show binlog events in 'master-bin.000001' from 102;
|
show binlog events in 'master-bin.000001' from 105;
|
||||||
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 1 # use `test`; create table t1 (n int) engine=innodb
|
master-bin.000001 # Query 1 # use `test`; create table t1 (n int) engine=innodb
|
||||||
master-bin.000001 # Query 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
@ -142,7 +142,7 @@ master-bin.000001 # Query 1 # use `test`; insert into t1 values(2 + 4)
|
|||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(1 + 4)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(1 + 4)
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
||||||
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
||||||
show binlog events in 'master-bin.000002' from 102;
|
show binlog events in 'master-bin.000002' from 105;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
master-bin.000002 # Query 1 # use `test`; drop table t1
|
master-bin.000002 # Query 1 # use `test`; drop table t1
|
||||||
reset master;
|
reset master;
|
||||||
@ -164,7 +164,7 @@ INSERT INTO user SET host='localhost', user='@#@', password=password('Just a tes
|
|||||||
UPDATE user SET password=password('Another password') WHERE host='localhost' AND user='@#@';
|
UPDATE user SET password=password('Another password') WHERE host='localhost' AND user='@#@';
|
||||||
DELETE FROM user WHERE host='localhost' AND user='@#@';
|
DELETE FROM user WHERE host='localhost' AND user='@#@';
|
||||||
use test;
|
use test;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
master-bin.000001 # Query 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
||||||
master-bin.000001 # Intvar 1 # INSERT_ID=127
|
master-bin.000001 # Intvar 1 # INSERT_ID=127
|
||||||
@ -183,7 +183,7 @@ set @@session.auto_increment_increment=1, @@session.auto_increment_offset=1;
|
|||||||
insert delayed into t1 values (207);
|
insert delayed into t1 values (207);
|
||||||
insert delayed into t1 values (null);
|
insert delayed into t1 values (null);
|
||||||
insert delayed into t1 values (300);
|
insert delayed into t1 values (300);
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
master-bin.000001 # Query 1 # use `test`; create table t1 (id tinyint auto_increment primary key)
|
||||||
master-bin.000001 # Intvar 1 # INSERT_ID=127
|
master-bin.000001 # Intvar 1 # INSERT_ID=127
|
||||||
|
@ -3,10 +3,10 @@ create table t2 (c char(30)) charset=ucs2;
|
|||||||
set @v=convert('abc' using ucs2);
|
set @v=convert('abc' using ucs2);
|
||||||
reset master;
|
reset master;
|
||||||
insert into t2 values (@v);
|
insert into t2 values (@v);
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 102 User var 1 142 @`v`=_ucs2 0x006100620063 COLLATE ucs2_general_ci
|
master-bin.000001 105 User var 1 145 @`v`=_ucs2 0x006100620063 COLLATE ucs2_general_ci
|
||||||
master-bin.000001 142 Query 1 231 use `test`; insert into t2 values (@v)
|
master-bin.000001 145 Query 1 234 use `test`; insert into t2 values (@v)
|
||||||
flush logs;
|
flush logs;
|
||||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||||
|
@ -8,8 +8,8 @@ insert into t1 select * from t2;
|
|||||||
ERROR 23000: Duplicate entry '2' for key 'a'
|
ERROR 23000: Duplicate entry '2' for key 'a'
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 196 use `test`; insert into t1 select * from t2
|
master-bin.000001 105 Query 1 199 use `test`; insert into t1 select * from t2
|
||||||
select * from t1;
|
select * from t1;
|
||||||
a
|
a
|
||||||
1
|
1
|
||||||
@ -22,5 +22,5 @@ create table t2(unique(a)) select a from t1;
|
|||||||
ERROR 23000: Duplicate entry '1' for key 'a'
|
ERROR 23000: Duplicate entry '1' for key 'a'
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
@ -6,7 +6,7 @@ begin;
|
|||||||
insert into t1 values(1);
|
insert into t1 values(1);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(1)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(1)
|
||||||
@ -21,7 +21,7 @@ insert into t2 select * from t1;
|
|||||||
rollback;
|
rollback;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(2)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(2)
|
||||||
@ -39,7 +39,7 @@ rollback to savepoint my_savepoint;
|
|||||||
Warnings:
|
Warnings:
|
||||||
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(3)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(3)
|
||||||
@ -65,7 +65,7 @@ select a from t1 order by a;
|
|||||||
a
|
a
|
||||||
5
|
5
|
||||||
7
|
7
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(5)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(5)
|
||||||
@ -87,7 +87,7 @@ insert into t2 select * from t1;
|
|||||||
select get_lock("a",10);
|
select get_lock("a",10);
|
||||||
get_lock("a",10)
|
get_lock("a",10)
|
||||||
1
|
1
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(8)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(8)
|
||||||
@ -98,7 +98,7 @@ delete from t2;
|
|||||||
reset master;
|
reset master;
|
||||||
insert into t1 values(9);
|
insert into t1 values(9);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; insert into t1 values(9)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(9)
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
||||||
@ -109,14 +109,14 @@ reset master;
|
|||||||
insert into t1 values(10);
|
insert into t1 values(10);
|
||||||
begin;
|
begin;
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; insert into t1 values(10)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(10)
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t2 select * from t1
|
master-bin.000001 # Query 1 # use `test`; insert into t2 select * from t1
|
||||||
insert into t1 values(11);
|
insert into t1 values(11);
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; insert into t1 values(10)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(10)
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
master-bin.000001 # Xid 1 # COMMIT /* xid= */
|
||||||
@ -132,7 +132,7 @@ begin;
|
|||||||
insert into t1 values(12);
|
insert into t1 values(12);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(12)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(12)
|
||||||
@ -145,7 +145,7 @@ begin;
|
|||||||
insert into t1 values(13);
|
insert into t1 values(13);
|
||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
rollback;
|
rollback;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
delete from t1;
|
delete from t1;
|
||||||
delete from t2;
|
delete from t2;
|
||||||
@ -157,7 +157,7 @@ insert into t1 values(15);
|
|||||||
insert into t2 select * from t1;
|
insert into t2 select * from t1;
|
||||||
rollback to savepoint my_savepoint;
|
rollback to savepoint my_savepoint;
|
||||||
commit;
|
commit;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(14)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(14)
|
||||||
@ -177,7 +177,7 @@ select a from t1 order by a;
|
|||||||
a
|
a
|
||||||
16
|
16
|
||||||
18
|
18
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(16)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(16)
|
||||||
@ -227,7 +227,7 @@ insert into t2 values (3);
|
|||||||
select get_lock("lock1",60);
|
select get_lock("lock1",60);
|
||||||
get_lock("lock1",60)
|
get_lock("lock1",60)
|
||||||
1
|
1
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; BEGIN
|
master-bin.000001 # Query 1 # use `test`; BEGIN
|
||||||
master-bin.000001 # Query 1 # use `test`; insert into t1 values(16)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values(16)
|
||||||
@ -331,7 +331,7 @@ SELECT * from t2;
|
|||||||
a b
|
a b
|
||||||
100 100
|
100 100
|
||||||
DROP TABLE t1,t2;
|
DROP TABLE t1,t2;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # use `test`; INSERT INTO t1 values (1,1),(1,2)
|
master-bin.000001 # Query 1 # use `test`; INSERT INTO t1 values (1,1),(1,2)
|
||||||
master-bin.000001 # Query 1 # use `test`; DROP TABLE if exists t2
|
master-bin.000001 # Query 1 # use `test`; DROP TABLE if exists t2
|
||||||
|
@ -6,7 +6,7 @@ CREATE TABLE t1(f1 blob);
|
|||||||
PREPARE stmt1 FROM 'INSERT INTO t1 VALUES(?)';
|
PREPARE stmt1 FROM 'INSERT INTO t1 VALUES(?)';
|
||||||
SET @var1= x'8300';
|
SET @var1= x'8300';
|
||||||
EXECUTE stmt1 USING @var1;
|
EXECUTE stmt1 USING @var1;
|
||||||
SHOW BINLOG EVENTS FROM 102;
|
SHOW BINLOG EVENTS FROM 105;
|
||||||
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 1 # use `test`; CREATE TABLE t1(f1 blob)
|
master-bin.000001 # Query 1 # use `test`; CREATE TABLE t1(f1 blob)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
|
@ -6,7 +6,7 @@ CREATE TABLE t1(f1 blob);
|
|||||||
PREPARE stmt1 FROM 'INSERT INTO t1 VALUES(?)';
|
PREPARE stmt1 FROM 'INSERT INTO t1 VALUES(?)';
|
||||||
SET @var1= x'8300';
|
SET @var1= x'8300';
|
||||||
EXECUTE stmt1 USING @var1;
|
EXECUTE stmt1 USING @var1;
|
||||||
SHOW BINLOG EVENTS FROM 102;
|
SHOW BINLOG EVENTS FROM 105;
|
||||||
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 1 # use `test`; CREATE TABLE t1(f1 blob)
|
master-bin.000001 # Query 1 # use `test`; CREATE TABLE t1(f1 blob)
|
||||||
master-bin.000001 # User var 1 # @`var1`=_binary 0x8300 COLLATE binary
|
master-bin.000001 # User var 1 # @`var1`=_binary 0x8300 COLLATE binary
|
||||||
@ -30,17 +30,17 @@ HEX(s1) HEX(s2) d
|
|||||||
466F6F2773206120426172 ED40ED41ED42 47.93
|
466F6F2773206120426172 ED40ED41ED42 47.93
|
||||||
DROP PROCEDURE bug18293|
|
DROP PROCEDURE bug18293|
|
||||||
DROP TABLE t4|
|
DROP TABLE t4|
|
||||||
SHOW BINLOG EVENTS FROM 406|
|
SHOW BINLOG EVENTS FROM 409|
|
||||||
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 406 Query 1 572 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
|
master-bin.000001 409 Query 1 575 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
|
||||||
s2 CHAR(50) CHARACTER SET cp932,
|
s2 CHAR(50) CHARACTER SET cp932,
|
||||||
d DECIMAL(10,2))
|
d DECIMAL(10,2))
|
||||||
master-bin.000001 572 Query 1 820 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE bug18293 (IN ins1 CHAR(50),
|
master-bin.000001 575 Query 1 823 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE bug18293 (IN ins1 CHAR(50),
|
||||||
IN ins2 CHAR(50) CHARACTER SET cp932,
|
IN ins2 CHAR(50) CHARACTER SET cp932,
|
||||||
IN ind DECIMAL(10,2))
|
IN ind DECIMAL(10,2))
|
||||||
BEGIN
|
BEGIN
|
||||||
INSERT INTO t4 VALUES (ins1, ins2, ind);
|
INSERT INTO t4 VALUES (ins1, ins2, ind);
|
||||||
END
|
END
|
||||||
master-bin.000001 820 Query 1 1039 use `test`; INSERT INTO t4 VALUES ( NAME_CONST('ins1',_latin1 0x466F6F2773206120426172), NAME_CONST('ins2',_cp932 0xED40ED41ED42), NAME_CONST('ind',47.93))
|
master-bin.000001 823 Query 1 1042 use `test`; INSERT INTO t4 VALUES ( NAME_CONST('ins1',_latin1 0x466F6F2773206120426172), NAME_CONST('ins2',_cp932 0xED40ED41ED42), NAME_CONST('ind',47.93))
|
||||||
master-bin.000001 1039 Query 1 1128 use `test`; DROP PROCEDURE bug18293
|
master-bin.000001 1042 Query 1 1131 use `test`; DROP PROCEDURE bug18293
|
||||||
master-bin.000001 1128 Query 1 1207 use `test`; DROP TABLE t4
|
master-bin.000001 1131 Query 1 1210 use `test`; DROP TABLE t4
|
||||||
|
@ -5,11 +5,11 @@ insert t1 values (1);
|
|||||||
flush tables with read lock;
|
flush tables with read lock;
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000001 102
|
master-bin.000001 105
|
||||||
commit;
|
commit;
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000001 102
|
master-bin.000001 105
|
||||||
unlock tables;
|
unlock tables;
|
||||||
drop table t1;
|
drop table t1;
|
||||||
set autocommit=1;
|
set autocommit=1;
|
||||||
|
@ -13,6 +13,7 @@ master-bin1.000001 # Query # # BEGIN
|
|||||||
master-bin1.000001 # Table_map # # table_id: # (test.t2)
|
master-bin1.000001 # Table_map # # table_id: # (test.t2)
|
||||||
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin1.000001 # Write_rows # # table_id: #
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||||
master-bin1.000001 # Query # # COMMIT
|
master-bin1.000001 # Query # # COMMIT
|
||||||
select * from t2 order by a;
|
select * from t2 order by a;
|
||||||
@ -35,6 +36,7 @@ master-bin.000001 # Query # # BEGIN
|
|||||||
master-bin.000001 # Table_map # # table_id: # (test.t2)
|
master-bin.000001 # Table_map # # table_id: # (test.t2)
|
||||||
master-bin.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 # Write_rows # # table_id: #
|
master-bin.000001 # Write_rows # # table_id: #
|
||||||
|
master-bin.000001 # Write_rows # # table_id: #
|
||||||
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 # Query # # COMMIT
|
master-bin.000001 # Query # # COMMIT
|
||||||
master-bin.000001 # Query # # use `test`; DROP TABLE t2
|
master-bin.000001 # Query # # use `test`; DROP TABLE t2
|
||||||
@ -53,6 +55,7 @@ master-bin1.000001 # Query # # BEGIN
|
|||||||
master-bin1.000001 # Table_map # # table_id: # (test.t1)
|
master-bin1.000001 # Table_map # # table_id: # (test.t1)
|
||||||
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin1.000001 # Write_rows # # table_id: #
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||||
master-bin1.000001 # Query # # COMMIT
|
master-bin1.000001 # Query # # COMMIT
|
||||||
SELECT @the_epoch2:=epoch,inserts,updates,deletes,schemaops FROM
|
SELECT @the_epoch2:=epoch,inserts,updates,deletes,schemaops FROM
|
||||||
@ -71,6 +74,7 @@ master-bin1.000001 # Query # # BEGIN
|
|||||||
master-bin1.000001 # Table_map # # table_id: # (test.t1)
|
master-bin1.000001 # Table_map # # table_id: # (test.t1)
|
||||||
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
master-bin1.000001 # Table_map # # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin1.000001 # Write_rows # # table_id: #
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
|
master-bin1.000001 # Write_rows # # table_id: #
|
||||||
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
master-bin1.000001 # Write_rows # # table_id: # flags: STMT_END_F
|
||||||
master-bin1.000001 # Query # # COMMIT
|
master-bin1.000001 # Query # # COMMIT
|
||||||
master-bin1.000001 # Query # # use `test`; drop table t1
|
master-bin1.000001 # Query # # use `test`; drop table t1
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
reset master;
|
reset master;
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000001 102
|
master-bin.000001 105
|
||||||
reset slave;
|
reset slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
@ -17,7 +17,7 @@ Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 7 master-bin.000001 102 # # master-bin.000001 Yes Yes 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 7 master-bin.000001 105 # # master-bin.000001 Yes Yes 0 0 105 # None 0 No #
|
||||||
drop table if exists t1;
|
drop table if exists t1;
|
||||||
create table t1 (n int, PRIMARY KEY(n));
|
create table t1 (n int, PRIMARY KEY(n));
|
||||||
insert into t1 values (10),(45),(90);
|
insert into t1 values (10),(45),(90);
|
||||||
|
@ -13,11 +13,11 @@ insert into t1 values(2);
|
|||||||
stop slave;
|
stop slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 187 # None 0 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 190 # None 0 No #
|
||||||
change master to master_user='root';
|
change master to master_user='root';
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 187 # None 0 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 190 # None 0 No #
|
||||||
start slave;
|
start slave;
|
||||||
select * from t1;
|
select * from t1;
|
||||||
n
|
n
|
||||||
|
@ -80,7 +80,7 @@ Master_SSL_Key
|
|||||||
Seconds_Behind_Master #
|
Seconds_Behind_Master #
|
||||||
stop slave;
|
stop slave;
|
||||||
delete from t3;
|
delete from t3;
|
||||||
change master to master_log_pos=544;
|
change master to master_log_pos=547;
|
||||||
begin;
|
begin;
|
||||||
select * from t2 for update;
|
select * from t2 for update;
|
||||||
a
|
a
|
||||||
@ -136,7 +136,7 @@ set @my_max_relay_log_size= @@global.max_relay_log_size;
|
|||||||
set global max_relay_log_size=0;
|
set global max_relay_log_size=0;
|
||||||
stop slave;
|
stop slave;
|
||||||
delete from t3;
|
delete from t3;
|
||||||
change master to master_log_pos=544;
|
change master to master_log_pos=547;
|
||||||
begin;
|
begin;
|
||||||
select * from t2 for update;
|
select * from t2 for update;
|
||||||
a
|
a
|
||||||
|
@ -24,7 +24,7 @@ Master_User root
|
|||||||
Master_Port SLAVE_PORT
|
Master_Port SLAVE_PORT
|
||||||
Connect_Retry 60
|
Connect_Retry 60
|
||||||
Master_Log_File slave-bin.000001
|
Master_Log_File slave-bin.000001
|
||||||
Read_Master_Log_Pos 212
|
Read_Master_Log_Pos 215
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File slave-bin.000001
|
Relay_Master_Log_File slave-bin.000001
|
||||||
@ -39,7 +39,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 212
|
Exec_Master_Log_Pos 215
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
|
@ -33,7 +33,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 1105
|
Last_Errno 1105
|
||||||
Last_Error Error 'master may suffer from http://bugs.mysql.com/bug.php?id=24432 so slave stops; check error log on slave for more info' on query. Default database: 'test'. Query: 'INSERT INTO t1(b) VALUES(1),(1),(2) ON DUPLICATE KEY UPDATE t1.b=10'
|
Last_Error Error 'master may suffer from http://bugs.mysql.com/bug.php?id=24432 so slave stops; check error log on slave for more info' on query. Default database: 'test'. Query: 'INSERT INTO t1(b) VALUES(1),(1),(2) ON DUPLICATE KEY UPDATE t1.b=10'
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 242
|
Exec_Master_Log_Pos 245
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -115,7 +115,7 @@ FROM t2
|
|||||||
ON DUPLICATE KEY UPDATE
|
ON DUPLICATE KEY UPDATE
|
||||||
t1.field_3 = t2.field_c'
|
t1.field_3 = t2.field_c'
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 1274
|
Exec_Master_Log_Pos 1277
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
|
@ -28,7 +28,7 @@ day id category name
|
|||||||
2003-03-22 2416 a bbbbb
|
2003-03-22 2416 a bbbbb
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
slave-bin.000001 1276
|
slave-bin.000001 1279
|
||||||
drop table t1;
|
drop table t1;
|
||||||
drop table t2;
|
drop table t2;
|
||||||
drop table t3;
|
drop table t3;
|
||||||
@ -39,7 +39,7 @@ set global sql_slave_skip_counter=1;
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 1793 # # master-bin.000001 Yes Yes # 0 0 1793 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 1796 # # master-bin.000001 Yes Yes # 0 0 1796 # None 0 No #
|
||||||
set sql_log_bin=0;
|
set sql_log_bin=0;
|
||||||
delete from t1;
|
delete from t1;
|
||||||
set sql_log_bin=1;
|
set sql_log_bin=1;
|
||||||
@ -49,7 +49,7 @@ change master to master_user='test';
|
|||||||
change master to master_user='root';
|
change master to master_user='root';
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 1828 # # master-bin.000001 No No # 0 0 1828 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 1831 # # master-bin.000001 No No # 0 0 1831 # None 0 No #
|
||||||
set global sql_slave_skip_counter=1;
|
set global sql_slave_skip_counter=1;
|
||||||
start slave;
|
start slave;
|
||||||
set sql_log_bin=0;
|
set sql_log_bin=0;
|
||||||
|
@ -10,6 +10,6 @@ load data infile '../std_data_ln/rpl_loaddata.dat' into table test.t1;
|
|||||||
select count(*) from test.t1;
|
select count(*) from test.t1;
|
||||||
count(*)
|
count(*)
|
||||||
2
|
2
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
drop table test.t1;
|
drop table test.t1;
|
||||||
|
@ -6,10 +6,10 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
|||||||
start slave;
|
start slave;
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000001 102 <Binlog_Ignore_DB>
|
master-bin.000001 105 <Binlog_Ignore_DB>
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 Yes Yes 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 Yes Yes 0 0 105 # None 0 No #
|
||||||
stop slave;
|
stop slave;
|
||||||
change master to master_log_pos=74;
|
change master to master_log_pos=74;
|
||||||
start slave;
|
start slave;
|
||||||
@ -30,13 +30,13 @@ Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File
|
|||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 177 # # master-bin.000001 No Yes 0 0 177 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 177 # # master-bin.000001 No Yes 0 0 177 # None 0 No #
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000001 102 <Binlog_Ignore_DB>
|
master-bin.000001 105 <Binlog_Ignore_DB>
|
||||||
create table if not exists t1 (n int);
|
create table if not exists t1 (n int);
|
||||||
drop table if exists t1;
|
drop table if exists t1;
|
||||||
create table t1 (n int);
|
create table t1 (n int);
|
||||||
insert into t1 values (1),(2),(3);
|
insert into t1 values (1),(2),(3);
|
||||||
stop slave;
|
stop slave;
|
||||||
change master to master_log_pos=102;
|
change master to master_log_pos=105;
|
||||||
start slave;
|
start slave;
|
||||||
select * from t1 ORDER BY n;
|
select * from t1 ORDER BY n;
|
||||||
n
|
n
|
||||||
|
@ -109,7 +109,7 @@ a b
|
|||||||
1 cp850_general_ci
|
1 cp850_general_ci
|
||||||
drop database mysqltest2;
|
drop database mysqltest2;
|
||||||
drop database mysqltest3;
|
drop database mysqltest3;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest2
|
master-bin.000001 # Query 1 # drop database if exists mysqltest2
|
||||||
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
||||||
|
@ -28,9 +28,9 @@ a b c
|
|||||||
*** Select from slave ***
|
*** Select from slave ***
|
||||||
SELECT * FROM t1 ORDER BY a;
|
SELECT * FROM t1 ORDER BY a;
|
||||||
a b c d e
|
a b c d e
|
||||||
1 2 TEXAS 2 TEST
|
1 2 TEXAS NULL NULL
|
||||||
2 1 AUSTIN 2 TEST
|
2 1 AUSTIN NULL NULL
|
||||||
3 4 QA 2 TEST
|
3 4 QA NULL NULL
|
||||||
*** Drop t1 ***
|
*** Drop t1 ***
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
*** Create t3 on slave ***
|
*** Create t3 on slave ***
|
||||||
@ -289,9 +289,9 @@ a b c
|
|||||||
*** Select from slave ***
|
*** Select from slave ***
|
||||||
SELECT * FROM t7 ORDER BY a;
|
SELECT * FROM t7 ORDER BY a;
|
||||||
a b c d e
|
a b c d e
|
||||||
1 b1b1 Kyle 0000-00-00 00:00:00 Extra Column Testing
|
1 b1b1 Kyle NULL NULL
|
||||||
2 b1b1 JOE 0000-00-00 00:00:00 Extra Column Testing
|
2 b1b1 JOE NULL NULL
|
||||||
3 b1b1 QA 0000-00-00 00:00:00 Extra Column Testing
|
3 b1b1 QA NULL NULL
|
||||||
*** Drop t7 ***
|
*** Drop t7 ***
|
||||||
DROP TABLE t7;
|
DROP TABLE t7;
|
||||||
*** Create t8 on slave ***
|
*** Create t8 on slave ***
|
||||||
@ -447,9 +447,9 @@ a b c
|
|||||||
*** Select on Slave ***
|
*** Select on Slave ***
|
||||||
SELECT * FROM t12 ORDER BY a;
|
SELECT * FROM t12 ORDER BY a;
|
||||||
a b f c e
|
a b f c e
|
||||||
1 b1b1b1b1b1b1b1b1 Kyle test 1
|
1 b1b1b1b1b1b1b1b1 Kyle NULL NULL
|
||||||
2 b1b1b1b1b1b1b1b1 JOE test 1
|
2 b1b1b1b1b1b1b1b1 JOE NULL NULL
|
||||||
3 b1b1b1b1b1b1b1b1 QA test 1
|
3 b1b1b1b1b1b1b1b1 QA NULL NULL
|
||||||
*** Drop t12 ***
|
*** Drop t12 ***
|
||||||
DROP TABLE t12;
|
DROP TABLE t12;
|
||||||
**** Extra Colums End ****
|
**** Extra Colums End ****
|
||||||
@ -479,9 +479,9 @@ a b c
|
|||||||
*** Select on Slave ****
|
*** Select on Slave ****
|
||||||
SELECT * FROM t13 ORDER BY a;
|
SELECT * FROM t13 ORDER BY a;
|
||||||
a b c d e
|
a b c d e
|
||||||
1 b1b1b1b1b1b1b1b1 Kyle 1 CURRENT_TIMESTAMP
|
1 b1b1b1b1b1b1b1b1 Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 b1b1b1b1b1b1b1b1 JOE 1 CURRENT_TIMESTAMP
|
2 b1b1b1b1b1b1b1b1 JOE NULL CURRENT_TIMESTAMP
|
||||||
3 b1b1b1b1b1b1b1b1 QA 1 CURRENT_TIMESTAMP
|
3 b1b1b1b1b1b1b1b1 QA NULL CURRENT_TIMESTAMP
|
||||||
*** Drop t13 ***
|
*** Drop t13 ***
|
||||||
DROP TABLE t13;
|
DROP TABLE t13;
|
||||||
*** 22117 END ***
|
*** 22117 END ***
|
||||||
@ -515,9 +515,9 @@ c1 c2 c3 c4 c5
|
|||||||
*** Select on Slave ****
|
*** Select on Slave ****
|
||||||
SELECT * FROM t14 ORDER BY c1;
|
SELECT * FROM t14 ORDER BY c1;
|
||||||
c1 c2 c3 c4 c5 c6 c7
|
c1 c2 c3 c4 c5 c6 c7
|
||||||
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle 1 CURRENT_TIMESTAMP
|
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE 1 CURRENT_TIMESTAMP
|
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE NULL CURRENT_TIMESTAMP
|
||||||
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA 1 CURRENT_TIMESTAMP
|
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA NULL CURRENT_TIMESTAMP
|
||||||
*** connect to master and drop columns ***
|
*** connect to master and drop columns ***
|
||||||
ALTER TABLE t14 DROP COLUMN c2;
|
ALTER TABLE t14 DROP COLUMN c2;
|
||||||
ALTER TABLE t14 DROP COLUMN c4;
|
ALTER TABLE t14 DROP COLUMN c4;
|
||||||
@ -530,9 +530,9 @@ c1 c3 c5
|
|||||||
*** Select from Slave ***
|
*** Select from Slave ***
|
||||||
SELECT * FROM t14 ORDER BY c1;
|
SELECT * FROM t14 ORDER BY c1;
|
||||||
c1 c3 c5 c6 c7
|
c1 c3 c5 c6 c7
|
||||||
1 Replication Testing Extra Col Kyle 1 CURRENT_TIMESTAMP
|
1 Replication Testing Extra Col Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 This Test Should work JOE 1 CURRENT_TIMESTAMP
|
2 This Test Should work JOE NULL CURRENT_TIMESTAMP
|
||||||
3 If is does not, I will open a bug QA 1 CURRENT_TIMESTAMP
|
3 If is does not, I will open a bug QA NULL CURRENT_TIMESTAMP
|
||||||
*** Drop t14 ***
|
*** Drop t14 ***
|
||||||
DROP TABLE t14;
|
DROP TABLE t14;
|
||||||
*** Create t15 on slave ***
|
*** Create t15 on slave ***
|
||||||
@ -563,9 +563,9 @@ c1 c2 c3 c4 c5
|
|||||||
*** Select on Slave ****
|
*** Select on Slave ****
|
||||||
SELECT * FROM t15 ORDER BY c1;
|
SELECT * FROM t15 ORDER BY c1;
|
||||||
c1 c2 c3 c4 c5 c6 c7
|
c1 c2 c3 c4 c5 c6 c7
|
||||||
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle 1 CURRENT_TIMESTAMP
|
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE 1 CURRENT_TIMESTAMP
|
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE NULL CURRENT_TIMESTAMP
|
||||||
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA 1 CURRENT_TIMESTAMP
|
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA NULL CURRENT_TIMESTAMP
|
||||||
*** Add column on master that is a Extra on Slave ***
|
*** Add column on master that is a Extra on Slave ***
|
||||||
ALTER TABLE t15 ADD COLUMN c6 INT AFTER c5;
|
ALTER TABLE t15 ADD COLUMN c6 INT AFTER c5;
|
||||||
********************************************
|
********************************************
|
||||||
@ -618,9 +618,9 @@ c1 c2 c3 c4 c5 c6
|
|||||||
*** Try to select from slave ****
|
*** Try to select from slave ****
|
||||||
SELECT * FROM t15 ORDER BY c1;
|
SELECT * FROM t15 ORDER BY c1;
|
||||||
c1 c2 c3 c4 c5 c6 c7
|
c1 c2 c3 c4 c5 c6 c7
|
||||||
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle 1 CURRENT_TIMESTAMP
|
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE 1 CURRENT_TIMESTAMP
|
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE NULL CURRENT_TIMESTAMP
|
||||||
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA 1 CURRENT_TIMESTAMP
|
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA NULL CURRENT_TIMESTAMP
|
||||||
5 2.00 Replication Testing b1b1b1b1b1b1b1b1 Buda 2 CURRENT_TIMESTAMP
|
5 2.00 Replication Testing b1b1b1b1b1b1b1b1 Buda 2 CURRENT_TIMESTAMP
|
||||||
*** DROP TABLE t15 ***
|
*** DROP TABLE t15 ***
|
||||||
DROP TABLE t15;
|
DROP TABLE t15;
|
||||||
@ -652,9 +652,9 @@ c1 c2 c3 c4 c5
|
|||||||
*** Select on Slave ****
|
*** Select on Slave ****
|
||||||
SELECT * FROM t16 ORDER BY c1;
|
SELECT * FROM t16 ORDER BY c1;
|
||||||
c1 c2 c3 c4 c5 c6 c7
|
c1 c2 c3 c4 c5 c6 c7
|
||||||
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle 1 CURRENT_TIMESTAMP
|
1 1.00 Replication Testing Extra Col b1b1b1b1b1b1b1b1 Kyle NULL CURRENT_TIMESTAMP
|
||||||
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE 1 CURRENT_TIMESTAMP
|
2 2.00 This Test Should work b1b1b1b1b1b1b1b1 JOE NULL CURRENT_TIMESTAMP
|
||||||
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA 1 CURRENT_TIMESTAMP
|
3 3.00 If is does not, I will open a bug b1b1b1b1b1b1b1b1 QA NULL CURRENT_TIMESTAMP
|
||||||
*** Add Partition on master ***
|
*** Add Partition on master ***
|
||||||
ALTER TABLE t16 PARTITION BY KEY(c1) PARTITIONS 4;
|
ALTER TABLE t16 PARTITION BY KEY(c1) PARTITIONS 4;
|
||||||
INSERT INTO t16 () VALUES(4,1.00,'Replication Rocks',@b1,'Omer');
|
INSERT INTO t16 () VALUES(4,1.00,'Replication Rocks',@b1,'Omer');
|
||||||
|
@ -32,16 +32,17 @@ master-bin.000001 # Query 1 # BEGIN
|
|||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 # Table_map 1 # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: #
|
master-bin.000001 # Write_rows 1 # table_id: #
|
||||||
|
master-bin.000001 # Write_rows 1 # table_id: #
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 # Query 1 # COMMIT
|
master-bin.000001 # Query 1 # COMMIT
|
||||||
show binlog events from 102 limit 1;
|
show binlog events from 105 limit 1;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=NDB
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=NDB
|
||||||
show binlog events from 102 limit 2;
|
show binlog events from 105 limit 2;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=NDB
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=NDB
|
||||||
master-bin.000001 # Query 1 # BEGIN
|
master-bin.000001 # Query 1 # BEGIN
|
||||||
show binlog events from 102 limit 2,1;
|
show binlog events from 105 limit 2,1;
|
||||||
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 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
flush logs;
|
flush logs;
|
||||||
@ -71,6 +72,7 @@ master-bin.000001 # Query 1 # BEGIN
|
|||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 # Table_map 1 # table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: #
|
master-bin.000001 # Write_rows 1 # table_id: #
|
||||||
|
master-bin.000001 # Write_rows 1 # table_id: #
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 # Query 1 # COMMIT
|
master-bin.000001 # Query 1 # COMMIT
|
||||||
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
master-bin.000001 # Rotate 1 # master-bin.000002;pos=4
|
||||||
@ -87,13 +89,13 @@ master-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
|||||||
master-bin.000002 # Query 1 # COMMIT
|
master-bin.000002 # Query 1 # COMMIT
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 1702
|
master-bin.000001 1734
|
||||||
master-bin.000002 593
|
master-bin.000002 596
|
||||||
start slave;
|
start slave;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
slave-bin.000001 1797
|
slave-bin.000001 1829
|
||||||
slave-bin.000002 198
|
slave-bin.000002 201
|
||||||
show binlog events in 'slave-bin.000001' from 4;
|
show binlog events in 'slave-bin.000001' from 4;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
||||||
@ -110,6 +112,7 @@ slave-bin.000001 # Query 2 # BEGIN
|
|||||||
slave-bin.000001 # Table_map 2 # table_id: # (test.t1)
|
slave-bin.000001 # Table_map 2 # table_id: # (test.t1)
|
||||||
slave-bin.000001 # Table_map 2 # table_id: # (mysql.ndb_apply_status)
|
slave-bin.000001 # Table_map 2 # table_id: # (mysql.ndb_apply_status)
|
||||||
slave-bin.000001 # Write_rows 2 # table_id: #
|
slave-bin.000001 # Write_rows 2 # table_id: #
|
||||||
|
slave-bin.000001 # Write_rows 2 # table_id: #
|
||||||
slave-bin.000001 # Write_rows 2 # table_id: # flags: STMT_END_F
|
slave-bin.000001 # Write_rows 2 # table_id: # flags: STMT_END_F
|
||||||
slave-bin.000001 # Query 2 # COMMIT
|
slave-bin.000001 # Query 2 # COMMIT
|
||||||
slave-bin.000001 # Query 1 # use `test`; create table t3 (a int)ENGINE=NDB
|
slave-bin.000001 # Query 1 # use `test`; create table t3 (a int)ENGINE=NDB
|
||||||
@ -126,7 +129,7 @@ slave-bin.000002 # Write_rows 2 # table_id: # flags: STMT_END_F
|
|||||||
slave-bin.000002 # Query 2 # COMMIT
|
slave-bin.000002 # Query 2 # COMMIT
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 593 # # master-bin.000002 Yes Yes # 0 0 593 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 596 # # master-bin.000002 Yes Yes # 0 0 596 # None 0 No #
|
||||||
show binlog events in 'slave-bin.000005' from 4;
|
show binlog events in 'slave-bin.000005' from 4;
|
||||||
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -26,11 +26,11 @@ stop slave;
|
|||||||
SELECT @the_pos:=Position,@the_file:=SUBSTRING_INDEX(FILE, '/', -1)
|
SELECT @the_pos:=Position,@the_file:=SUBSTRING_INDEX(FILE, '/', -1)
|
||||||
FROM mysql.ndb_binlog_index WHERE epoch = <the_epoch> ;
|
FROM mysql.ndb_binlog_index WHERE epoch = <the_epoch> ;
|
||||||
@the_pos:=Position @the_file:=SUBSTRING_INDEX(FILE, '/', -1)
|
@the_pos:=Position @the_file:=SUBSTRING_INDEX(FILE, '/', -1)
|
||||||
102 master-bin1.000001
|
105 master-bin1.000001
|
||||||
CHANGE MASTER TO
|
CHANGE MASTER TO
|
||||||
master_port=<MASTER_PORT1>,
|
master_port=<MASTER_PORT1>,
|
||||||
master_log_file = 'master-bin1.000001',
|
master_log_file = 'master-bin1.000001',
|
||||||
master_log_pos = 102 ;
|
master_log_pos = 105 ;
|
||||||
start slave;
|
start slave;
|
||||||
INSERT INTO t1 VALUES ("row2","will go away",2),("row3","will change",3),("row4","D",4);
|
INSERT INTO t1 VALUES ("row2","will go away",2),("row3","will change",3),("row4","D",4);
|
||||||
DELETE FROM t1 WHERE c3 = 1;
|
DELETE FROM t1 WHERE c3 = 1;
|
||||||
|
@ -28,7 +28,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 450
|
Read_Master_Log_Pos 453
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -43,7 +43,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 450
|
Exec_Master_Log_Pos 453
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
|
@ -16,7 +16,7 @@ create table t1 (s text);
|
|||||||
insert into t1 values('Could not break slave'),('Tried hard');
|
insert into t1 values('Could not break slave'),('Tried hard');
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 60 master-bin.000001 552 # # master-bin.000001 Yes Yes # 0 0 552 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 60 master-bin.000001 555 # # master-bin.000001 Yes Yes # 0 0 555 # None 0 No #
|
||||||
select * from t1;
|
select * from t1;
|
||||||
s
|
s
|
||||||
Could not break slave
|
Could not break slave
|
||||||
@ -27,9 +27,9 @@ insert into t2 values (34),(67),(123);
|
|||||||
flush logs;
|
flush logs;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 596
|
master-bin.000001 599
|
||||||
master-bin.000002 367
|
master-bin.000002 370
|
||||||
master-bin.000003 102
|
master-bin.000003 105
|
||||||
create table t3 select * from temp_table;
|
create table t3 select * from temp_table;
|
||||||
select * from t3;
|
select * from t3;
|
||||||
a
|
a
|
||||||
@ -43,21 +43,21 @@ start slave;
|
|||||||
purge master logs to 'master-bin.000002';
|
purge master logs to 'master-bin.000002';
|
||||||
show master logs;
|
show master logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000002 367
|
master-bin.000002 370
|
||||||
master-bin.000003 411
|
master-bin.000003 414
|
||||||
purge binary logs to 'master-bin.000002';
|
purge binary logs to 'master-bin.000002';
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000002 367
|
master-bin.000002 370
|
||||||
master-bin.000003 411
|
master-bin.000003 414
|
||||||
purge master logs before now();
|
purge master logs before now();
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000003 411
|
master-bin.000003 414
|
||||||
insert into t2 values (65);
|
insert into t2 values (65);
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 60 master-bin.000003 500 # # master-bin.000003 Yes Yes # 0 0 500 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 60 master-bin.000003 503 # # master-bin.000003 Yes Yes # 0 0 503 # None 0 No #
|
||||||
select * from t2;
|
select * from t2;
|
||||||
m
|
m
|
||||||
34
|
34
|
||||||
@ -74,18 +74,18 @@ count(*)
|
|||||||
create table t4 select * from temp_table;
|
create table t4 select * from temp_table;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000003 4189
|
master-bin.000003 4192
|
||||||
master-bin.000004 4194
|
master-bin.000004 4197
|
||||||
master-bin.000005 2036
|
master-bin.000005 2039
|
||||||
show master status;
|
show master status;
|
||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000005 2036
|
master-bin.000005 2039
|
||||||
select * from t4;
|
select * from t4;
|
||||||
a
|
a
|
||||||
testing temporary tables part 2
|
testing temporary tables part 2
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 60 master-bin.000005 2036 # # master-bin.000005 Yes Yes # 0 0 2036 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 60 master-bin.000005 2039 # # master-bin.000005 Yes Yes # 0 0 2039 # None 0 No #
|
||||||
lock tables t3 read;
|
lock tables t3 read;
|
||||||
select count(*) from t3 where n >= 4;
|
select count(*) from t3 where n >= 4;
|
||||||
count(*)
|
count(*)
|
||||||
|
1
mysql-test/r/rpl_row_basic_11bugs-master.opt
Normal file
1
mysql-test/r/rpl_row_basic_11bugs-master.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--innodb
|
1
mysql-test/r/rpl_row_basic_11bugs-slave.opt
Normal file
1
mysql-test/r/rpl_row_basic_11bugs-slave.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--innodb
|
@ -24,11 +24,11 @@ SHOW TABLES;
|
|||||||
Tables_in_test_ignore
|
Tables_in_test_ignore
|
||||||
t2
|
t2
|
||||||
INSERT INTO t2 VALUES (3,3), (4,4);
|
INSERT INTO t2 VALUES (3,3), (4,4);
|
||||||
SHOW BINLOG EVENTS FROM 102;
|
SHOW BINLOG EVENTS FROM 105;
|
||||||
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 102 Query 1 195 use `test`; CREATE TABLE t1 (a INT, b INT)
|
master-bin.000001 105 Query 1 198 use `test`; CREATE TABLE t1 (a INT, b INT)
|
||||||
master-bin.000001 195 Table_map 1 235 table_id: # (test.t1)
|
master-bin.000001 198 Table_map 1 238 table_id: # (test.t1)
|
||||||
master-bin.000001 235 Write_rows 1 282 table_id: # flags: STMT_END_F
|
master-bin.000001 238 Write_rows 1 285 table_id: # flags: STMT_END_F
|
||||||
**** On Slave ****
|
**** On Slave ****
|
||||||
SHOW DATABASES;
|
SHOW DATABASES;
|
||||||
Database
|
Database
|
||||||
@ -54,10 +54,10 @@ DELETE FROM t1 WHERE a = 0;
|
|||||||
UPDATE t1 SET a=99 WHERE a = 0;
|
UPDATE t1 SET a=99 WHERE a = 0;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 188 use `test`; CREATE TABLE t1 (a INT)
|
master-bin.000001 105 Query 1 191 use `test`; CREATE TABLE t1 (a INT)
|
||||||
master-bin.000001 188 Table_map 1 227 table_id: # (test.t1)
|
master-bin.000001 191 Table_map 1 230 table_id: # (test.t1)
|
||||||
master-bin.000001 227 Write_rows 1 266 table_id: # flags: STMT_END_F
|
master-bin.000001 230 Write_rows 1 269 table_id: # flags: STMT_END_F
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
================ Test for BUG#17620 ================
|
================ Test for BUG#17620 ================
|
||||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||||
@ -119,4 +119,102 @@ HEX(a) b
|
|||||||
SELECT HEX(a),b FROM t1;
|
SELECT HEX(a),b FROM t1;
|
||||||
HEX(a) b
|
HEX(a) b
|
||||||
0 2
|
0 2
|
||||||
DROP TABLE t1;
|
DROP TABLE IF EXISTS t1;
|
||||||
|
================ Test for BUG#22583 ================
|
||||||
|
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||||
|
reset master;
|
||||||
|
reset slave;
|
||||||
|
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||||
|
start slave;
|
||||||
|
**** On Master ****
|
||||||
|
CREATE TABLE t1_myisam (k INT, a BIT(1), b BIT(9)) ENGINE=MYISAM;
|
||||||
|
CREATE TABLE t1_innodb (k INT, a BIT(1), b BIT(9)) ENGINE=INNODB;
|
||||||
|
CREATE TABLE t2_myisam (k INT, a BIT(1) NOT NULL, b BIT(4) NOT NULL) ENGINE=MYISAM;
|
||||||
|
CREATE TABLE t2_innodb (k INT, a BIT(1) NOT NULL, b BIT(4) NOT NULL) ENGINE=INNODB;
|
||||||
|
**** On Slave ****
|
||||||
|
ALTER TABLE t1_myisam ENGINE=INNODB;
|
||||||
|
ALTER TABLE t1_innodb ENGINE=MYISAM;
|
||||||
|
ALTER TABLE t2_myisam ENGINE=INNODB;
|
||||||
|
ALTER TABLE t2_innodb ENGINE=MYISAM;
|
||||||
|
**** On Master ****
|
||||||
|
INSERT INTO t1_myisam VALUES(1, b'0', 257);
|
||||||
|
INSERT INTO t1_myisam VALUES(2, b'1', 256);
|
||||||
|
INSERT INTO t1_innodb VALUES(1, b'0', 257);
|
||||||
|
INSERT INTO t1_innodb VALUES(2, b'1', 256);
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 1 100
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 1 100
|
||||||
|
INSERT INTO t2_myisam VALUES(1, b'0', 9);
|
||||||
|
INSERT INTO t2_myisam VALUES(2, b'1', 8);
|
||||||
|
INSERT INTO t2_innodb VALUES(1, b'0', 9);
|
||||||
|
INSERT INTO t2_innodb VALUES(2, b'1', 8);
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 1 8
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 1 8
|
||||||
|
**** On Slave ****
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 1 100
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 1 100
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 1 8
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 1 8
|
||||||
|
**** On Master ****
|
||||||
|
UPDATE t1_myisam SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 0 100
|
||||||
|
UPDATE t1_innodb SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 0 100
|
||||||
|
UPDATE t2_myisam SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 0 8
|
||||||
|
UPDATE t2_innodb SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 0 8
|
||||||
|
**** On Slave ****
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 0 100
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 101
|
||||||
|
2 0 100
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 0 8
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
k HEX(a) HEX(b)
|
||||||
|
1 0 9
|
||||||
|
2 0 8
|
||||||
|
**** On Master ****
|
||||||
|
DROP TABLE IF EXISTS t1_myisam, t1_innodb, t2_myisam, t2_innodb;
|
||||||
|
@ -109,7 +109,7 @@ a b
|
|||||||
1 cp850_general_ci
|
1 cp850_general_ci
|
||||||
drop database mysqltest2;
|
drop database mysqltest2;
|
||||||
drop database mysqltest3;
|
drop database mysqltest3;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest2
|
master-bin.000001 # Query 1 # drop database if exists mysqltest2
|
||||||
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
||||||
|
@ -8,30 +8,30 @@ CREATE TABLE t1 (a INT, b INT);
|
|||||||
CREATE TABLE t2 (a INT, b INT) ENGINE=Merge;
|
CREATE TABLE t2 (a INT, b INT) ENGINE=Merge;
|
||||||
CREATE TABLE t3 (a INT, b INT) CHARSET=utf8;
|
CREATE TABLE t3 (a INT, b INT) CHARSET=utf8;
|
||||||
CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8;
|
CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8;
|
||||||
SHOW BINLOG EVENTS FROM 212;
|
SHOW BINLOG EVENTS FROM 215;
|
||||||
Log_name #
|
Log_name #
|
||||||
Pos 212
|
Pos 215
|
||||||
Event_type Query
|
Event_type Query
|
||||||
Server_id #
|
Server_id #
|
||||||
End_log_pos #
|
End_log_pos 308
|
||||||
Info use `test`; CREATE TABLE t1 (a INT, b INT)
|
Info use `test`; CREATE TABLE t1 (a INT, b INT)
|
||||||
Log_name #
|
Log_name #
|
||||||
Pos 305
|
Pos 308
|
||||||
Event_type Query
|
Event_type Query
|
||||||
Server_id #
|
Server_id #
|
||||||
End_log_pos #
|
End_log_pos 414
|
||||||
Info use `test`; CREATE TABLE t2 (a INT, b INT) ENGINE=Merge
|
Info use `test`; CREATE TABLE t2 (a INT, b INT) ENGINE=Merge
|
||||||
Log_name #
|
Log_name #
|
||||||
Pos 411
|
Pos 414
|
||||||
Event_type Query
|
Event_type Query
|
||||||
Server_id #
|
Server_id #
|
||||||
End_log_pos #
|
End_log_pos 520
|
||||||
Info use `test`; CREATE TABLE t3 (a INT, b INT) CHARSET=utf8
|
Info use `test`; CREATE TABLE t3 (a INT, b INT) CHARSET=utf8
|
||||||
Log_name #
|
Log_name #
|
||||||
Pos 517
|
Pos 520
|
||||||
Event_type Query
|
Event_type Query
|
||||||
Server_id #
|
Server_id #
|
||||||
End_log_pos #
|
End_log_pos 639
|
||||||
Info use `test`; CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8
|
Info use `test`; CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SHOW CREATE TABLE t1;
|
SHOW CREATE TABLE t1;
|
||||||
@ -127,7 +127,7 @@ NULL 5 10
|
|||||||
NULL 6 12
|
NULL 6 12
|
||||||
CREATE TABLE t7 (UNIQUE(b)) SELECT a,b FROM tt3;
|
CREATE TABLE t7 (UNIQUE(b)) SELECT a,b FROM tt3;
|
||||||
ERROR 23000: Duplicate entry '2' for key 'b'
|
ERROR 23000: Duplicate entry '2' for key 'b'
|
||||||
SHOW BINLOG EVENTS FROM 1118;
|
SHOW BINLOG EVENTS FROM 1097;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
CREATE TABLE t7 (a INT, b INT UNIQUE);
|
CREATE TABLE t7 (a INT, b INT UNIQUE);
|
||||||
INSERT INTO t7 SELECT a,b FROM tt3;
|
INSERT INTO t7 SELECT a,b FROM tt3;
|
||||||
@ -137,11 +137,11 @@ a b
|
|||||||
1 2
|
1 2
|
||||||
2 4
|
2 4
|
||||||
3 6
|
3 6
|
||||||
SHOW BINLOG EVENTS FROM 1118;
|
SHOW BINLOG EVENTS FROM 1097;
|
||||||
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 1118 Query 1 1218 use `test`; CREATE TABLE t7 (a INT, b INT UNIQUE)
|
# 1097 Query # 1197 use `test`; CREATE TABLE t7 (a INT, b INT UNIQUE)
|
||||||
master-bin.000001 1218 Table_map 1 1258 table_id: # (test.t7)
|
# 1197 Table_map # 1237 table_id: # (test.t7)
|
||||||
master-bin.000001 1258 Write_rows 1 1314 table_id: # flags: STMT_END_F
|
# 1237 Write_rows # 1293 table_id: # flags: STMT_END_F
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
a b
|
a b
|
||||||
1 2
|
1 2
|
||||||
@ -154,10 +154,10 @@ INSERT INTO t7 SELECT a,b FROM tt4;
|
|||||||
ROLLBACK;
|
ROLLBACK;
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
Warning 1196 Some non-transactional changed tables couldn't be rolled back
|
||||||
SHOW BINLOG EVENTS FROM 1314;
|
SHOW BINLOG EVENTS FROM 1293;
|
||||||
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 1314 Table_map 1 1354 table_id: # (test.t7)
|
# 1293 Table_map # 1333 table_id: # (test.t7)
|
||||||
master-bin.000001 1354 Write_rows 1 1410 table_id: # flags: STMT_END_F
|
# 1333 Write_rows # 1389 table_id: # flags: STMT_END_F
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
a b
|
a b
|
||||||
1 2
|
1 2
|
||||||
@ -192,10 +192,10 @@ Create Table CREATE TABLE `t9` (
|
|||||||
`a` int(11) DEFAULT NULL,
|
`a` int(11) DEFAULT NULL,
|
||||||
`b` int(11) DEFAULT NULL
|
`b` int(11) DEFAULT NULL
|
||||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||||
SHOW BINLOG EVENTS FROM 1410;
|
SHOW BINLOG EVENTS FROM 1389;
|
||||||
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 1410 Query 1 1496 use `test`; CREATE TABLE t8 LIKE t4
|
# 1389 Query # 1475 use `test`; CREATE TABLE t8 LIKE t4
|
||||||
master-bin.000001 1496 Query 1 1635 use `test`; CREATE TABLE `t9` (
|
# 1475 Query # 1614 use `test`; CREATE TABLE `t9` (
|
||||||
`a` int(11) DEFAULT NULL,
|
`a` int(11) DEFAULT NULL,
|
||||||
`b` int(11) DEFAULT NULL
|
`b` int(11) DEFAULT NULL
|
||||||
)
|
)
|
||||||
@ -274,33 +274,33 @@ a
|
|||||||
3
|
3
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: #, Binlog ver: #
|
# 4 Format_desc # 105 Server ver: #, Binlog ver: #
|
||||||
master-bin.000001 102 Query 1 188 use `test`; CREATE TABLE t1 (a INT)
|
# 105 Query # 191 use `test`; CREATE TABLE t1 (a INT)
|
||||||
master-bin.000001 188 Table_map 1 227 table_id: # (test.t1)
|
# 191 Table_map # 230 table_id: # (test.t1)
|
||||||
master-bin.000001 227 Write_rows 1 271 table_id: # flags: STMT_END_F
|
# 230 Write_rows # 274 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 271 Query 1 339 use `test`; BEGIN
|
# 274 Query # 342 use `test`; BEGIN
|
||||||
master-bin.000001 339 Query 1 125 use `test`; CREATE TABLE `t2` (
|
# 342 Query # 125 use `test`; CREATE TABLE `t2` (
|
||||||
`a` int(11) DEFAULT NULL
|
`a` int(11) DEFAULT NULL
|
||||||
) ENGINE=InnoDB
|
) ENGINE=InnoDB
|
||||||
master-bin.000001 464 Table_map 1 164 table_id: # (test.t2)
|
# 467 Table_map # 164 table_id: # (test.t2)
|
||||||
master-bin.000001 503 Write_rows 1 208 table_id: # flags: STMT_END_F
|
# 506 Write_rows # 208 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 547 Xid 1 574 COMMIT /* XID */
|
# 550 Xid # 577 COMMIT /* XID */
|
||||||
master-bin.000001 574 Query 1 642 use `test`; BEGIN
|
# 577 Query # 645 use `test`; BEGIN
|
||||||
master-bin.000001 642 Query 1 125 use `test`; CREATE TABLE `t3` (
|
# 645 Query # 125 use `test`; CREATE TABLE `t3` (
|
||||||
`a` int(11) DEFAULT NULL
|
`a` int(11) DEFAULT NULL
|
||||||
) ENGINE=InnoDB
|
) ENGINE=InnoDB
|
||||||
master-bin.000001 767 Table_map 1 164 table_id: # (test.t3)
|
# 770 Table_map # 164 table_id: # (test.t3)
|
||||||
master-bin.000001 806 Write_rows 1 208 table_id: # flags: STMT_END_F
|
# 809 Write_rows # 208 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 850 Xid 1 877 COMMIT /* XID */
|
# 853 Xid # 880 COMMIT /* XID */
|
||||||
master-bin.000001 877 Query 1 945 use `test`; BEGIN
|
# 880 Query # 948 use `test`; BEGIN
|
||||||
master-bin.000001 945 Query 1 125 use `test`; CREATE TABLE `t4` (
|
# 948 Query # 125 use `test`; CREATE TABLE `t4` (
|
||||||
`a` int(11) DEFAULT NULL
|
`a` int(11) DEFAULT NULL
|
||||||
) ENGINE=InnoDB
|
) ENGINE=InnoDB
|
||||||
master-bin.000001 1070 Table_map 1 164 table_id: # (test.t4)
|
# 1073 Table_map # 164 table_id: # (test.t4)
|
||||||
master-bin.000001 1109 Write_rows 1 208 table_id: # flags: STMT_END_F
|
# 1112 Write_rows # 208 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 1153 Xid 1 1180 COMMIT /* XID */
|
# 1156 Xid # 1183 COMMIT /* XID */
|
||||||
master-bin.000001 1180 Table_map 1 1219 table_id: # (test.t1)
|
# 1183 Table_map # 1222 table_id: # (test.t1)
|
||||||
master-bin.000001 1219 Write_rows 1 1263 table_id: # flags: STMT_END_F
|
# 1222 Write_rows # 1266 table_id: # flags: STMT_END_F
|
||||||
SHOW TABLES;
|
SHOW TABLES;
|
||||||
Tables_in_test
|
Tables_in_test
|
||||||
t1
|
t1
|
||||||
@ -365,17 +365,17 @@ a
|
|||||||
9
|
9
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: #, Binlog ver: #
|
# 4 Format_desc # 105 Server ver: #, Binlog ver: #
|
||||||
master-bin.000001 102 Query 1 188 use `test`; CREATE TABLE t1 (a INT)
|
# 105 Query # 191 use `test`; CREATE TABLE t1 (a INT)
|
||||||
master-bin.000001 188 Table_map 1 227 table_id: # (test.t1)
|
# 191 Table_map # 230 table_id: # (test.t1)
|
||||||
master-bin.000001 227 Write_rows 1 271 table_id: # flags: STMT_END_F
|
# 230 Write_rows # 274 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 271 Query 1 371 use `test`; CREATE TABLE t2 (a INT) ENGINE=INNODB
|
# 274 Query # 374 use `test`; CREATE TABLE t2 (a INT) ENGINE=INNODB
|
||||||
master-bin.000001 371 Query 1 439 use `test`; BEGIN
|
# 374 Query # 442 use `test`; BEGIN
|
||||||
master-bin.000001 439 Table_map 1 39 table_id: # (test.t2)
|
# 442 Table_map # 39 table_id: # (test.t2)
|
||||||
master-bin.000001 478 Write_rows 1 83 table_id: # flags: STMT_END_F
|
# 481 Write_rows # 83 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 522 Table_map 1 122 table_id: # (test.t2)
|
# 525 Table_map # 122 table_id: # (test.t2)
|
||||||
master-bin.000001 561 Write_rows 1 161 table_id: # flags: STMT_END_F
|
# 564 Write_rows # 161 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 600 Xid 1 627 COMMIT /* XID */
|
# 603 Xid # 630 COMMIT /* XID */
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
a
|
a
|
||||||
1
|
1
|
||||||
@ -394,10 +394,10 @@ INSERT INTO t2 SELECT a+2 FROM tt2;
|
|||||||
ROLLBACK;
|
ROLLBACK;
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
a
|
a
|
||||||
SHOW BINLOG EVENTS FROM 627;
|
SHOW BINLOG EVENTS FROM 630;
|
||||||
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 627 Query 1 80 use `test`; TRUNCATE TABLE t2
|
# 630 Query # 80 use `test`; TRUNCATE TABLE t2
|
||||||
master-bin.000001 707 Xid 1 734 COMMIT /* XID */
|
# 710 Xid # 737 COMMIT /* XID */
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
a
|
a
|
||||||
DROP TABLE t1,t2;
|
DROP TABLE t1,t2;
|
||||||
|
@ -16,15 +16,15 @@ a
|
|||||||
3
|
3
|
||||||
show binlog events;
|
show binlog events;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 222 use `test`; create table t1(a int not null primary key) engine=myisam
|
master-bin.000001 105 Query 1 225 use `test`; create table t1(a int not null primary key) engine=myisam
|
||||||
master-bin.000001 222 Table_map 1 261 table_id: # (test.t1)
|
master-bin.000001 225 Table_map 1 264 table_id: # (test.t1)
|
||||||
master-bin.000001 261 Write_rows 1 295 table_id: # flags: STMT_END_F
|
master-bin.000001 264 Write_rows 1 298 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 295 Table_map 1 334 table_id: # (test.t1)
|
master-bin.000001 298 Table_map 1 337 table_id: # (test.t1)
|
||||||
master-bin.000001 334 Write_rows 1 368 table_id: # flags: STMT_END_F
|
master-bin.000001 337 Write_rows 1 371 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 368 Table_map 1 407 table_id: # (test.t1)
|
master-bin.000001 371 Table_map 1 410 table_id: # (test.t1)
|
||||||
master-bin.000001 407 Write_rows 1 441 table_id: # flags: STMT_END_F
|
master-bin.000001 410 Write_rows 1 444 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 441 Query 1 516 use `test`; flush tables
|
master-bin.000001 444 Query 1 519 use `test`; flush tables
|
||||||
SELECT * FROM t1 ORDER BY a;
|
SELECT * FROM t1 ORDER BY a;
|
||||||
a
|
a
|
||||||
1
|
1
|
||||||
|
@ -43,10 +43,10 @@ t2
|
|||||||
DROP TABLE t1,t2;
|
DROP TABLE t1,t2;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 188 use `test`; CREATE TABLE t1 (a int)
|
master-bin.000001 105 Query 1 191 use `test`; CREATE TABLE t1 (a int)
|
||||||
master-bin.000001 188 Query 1 274 use `test`; CREATE TABLE t2 (a int)
|
master-bin.000001 191 Query 1 277 use `test`; CREATE TABLE t2 (a int)
|
||||||
master-bin.000001 274 Query 1 378 use `test`; DROP TABLE `t1` /* generated by server */
|
master-bin.000001 277 Query 1 381 use `test`; DROP TABLE `t1` /* generated by server */
|
||||||
SHOW TABLES;
|
SHOW TABLES;
|
||||||
Tables_in_test
|
Tables_in_test
|
||||||
t2
|
t2
|
||||||
|
@ -12,13 +12,13 @@ create table t4 (a int);
|
|||||||
insert into t4 select * from t3;
|
insert into t4 select * from t3;
|
||||||
rename table t1 to t5, t2 to t1;
|
rename table t1 to t5, t2 to t1;
|
||||||
flush no_write_to_binlog tables;
|
flush no_write_to_binlog tables;
|
||||||
SHOW BINLOG EVENTS FROM 615 ;
|
SHOW BINLOG EVENTS FROM 618 ;
|
||||||
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 1 # use `test`; rename table t1 to t5, t2 to t1
|
master-bin.000001 # Query 1 # use `test`; rename table t1 to t5, t2 to t1
|
||||||
select * from t3;
|
select * from t3;
|
||||||
a
|
a
|
||||||
flush tables;
|
flush tables;
|
||||||
SHOW BINLOG EVENTS FROM 615 ;
|
SHOW BINLOG EVENTS FROM 618 ;
|
||||||
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 1 # use `test`; rename table t1 to t5, t2 to t1
|
master-bin.000001 # Query 1 # use `test`; rename table t1 to t5, t2 to t1
|
||||||
master-bin.000001 # Query 1 # use `test`; flush tables
|
master-bin.000001 # Query 1 # use `test`; flush tables
|
||||||
|
@ -39,7 +39,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 1146
|
Last_Errno 1146
|
||||||
Last_Error Error 'Table 'test.t1' doesn't exist' on opening table `test`.`t1`
|
Last_Error Error 'Table 'test.t1' doesn't exist' on opening table `test`.`t1`
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 519
|
Exec_Master_Log_Pos 522
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
|
@ -26,14 +26,14 @@ master-bin.000001 # Query 1 # use `test`; drop table t1
|
|||||||
master-bin.000001 # Query 1 # use `test`; create table t1 (word char(20) not null)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1 (word char(20) not null)ENGINE=MyISAM
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
show binlog events from 102 limit 1;
|
show binlog events from 105 limit 1;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
||||||
show binlog events from 102 limit 2;
|
show binlog events from 105 limit 2;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
show binlog events from 102 limit 2,1;
|
show binlog events from 105 limit 2,1;
|
||||||
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 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
flush logs;
|
flush logs;
|
||||||
@ -67,13 +67,13 @@ master-bin.000002 # Table_map 1 # table_id: # (test.t2)
|
|||||||
master-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 1256
|
master-bin.000001 1259
|
||||||
master-bin.000002 373
|
master-bin.000002 376
|
||||||
start slave;
|
start slave;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
slave-bin.000001 1354
|
slave-bin.000001 1357
|
||||||
slave-bin.000002 274
|
slave-bin.000002 277
|
||||||
show binlog events in 'slave-bin.000001' from 4;
|
show binlog events in 'slave-bin.000001' from 4;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
||||||
@ -94,7 +94,7 @@ slave-bin.000002 # Table_map 1 # table_id: # (test.t2)
|
|||||||
slave-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
slave-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 373 # # master-bin.000002 Yes Yes # 0 0 373 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 376 # # master-bin.000002 Yes Yes # 0 0 376 # None 0 No #
|
||||||
show binlog events in 'slave-bin.000005' from 4;
|
show binlog events in 'slave-bin.000005' from 4;
|
||||||
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -28,14 +28,14 @@ master-bin.000001 # Query 1 # use `test`; create table t1 (word char(20) not nul
|
|||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 # Xid 1 # COMMIT /* XID */
|
master-bin.000001 # Xid 1 # COMMIT /* XID */
|
||||||
show binlog events from 102 limit 1;
|
show binlog events from 105 limit 1;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=InnoDB
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=InnoDB
|
||||||
show binlog events from 102 limit 2;
|
show binlog events from 105 limit 2;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=InnoDB
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=InnoDB
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
||||||
show binlog events from 102 limit 2,1;
|
show binlog events from 105 limit 2,1;
|
||||||
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 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
flush logs;
|
flush logs;
|
||||||
@ -72,13 +72,13 @@ master-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
|||||||
master-bin.000002 # Xid 1 # COMMIT /* XID */
|
master-bin.000002 # Xid 1 # COMMIT /* XID */
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 1310
|
master-bin.000001 1313
|
||||||
master-bin.000002 400
|
master-bin.000002 403
|
||||||
start slave;
|
start slave;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
slave-bin.000001 1408
|
slave-bin.000001 1411
|
||||||
slave-bin.000002 301
|
slave-bin.000002 304
|
||||||
show binlog events in 'slave-bin.000001' from 4;
|
show binlog events in 'slave-bin.000001' from 4;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
||||||
@ -102,7 +102,7 @@ slave-bin.000002 # Write_rows 1 # table_id: # flags: STMT_END_F
|
|||||||
slave-bin.000002 # Xid 1 # COMMIT /* XID */
|
slave-bin.000002 # Xid 1 # COMMIT /* XID */
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 400 # # master-bin.000002 Yes Yes # 0 0 400 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 403 # # master-bin.000002 Yes Yes # 0 0 403 # None 0 No #
|
||||||
show binlog events in 'slave-bin.000005' from 4;
|
show binlog events in 'slave-bin.000005' from 4;
|
||||||
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -30,7 +30,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 58664
|
Read_Master_Log_Pos 58667
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -45,7 +45,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 58664
|
Exec_Master_Log_Pos 58667
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -73,7 +73,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 58664
|
Read_Master_Log_Pos 58667
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -88,7 +88,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 58664
|
Exec_Master_Log_Pos 58667
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -116,7 +116,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 58664
|
Read_Master_Log_Pos 58667
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -131,7 +131,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 58664
|
Exec_Master_Log_Pos 58667
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -197,7 +197,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 58750
|
Read_Master_Log_Pos 58753
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -212,7 +212,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 58750
|
Exec_Master_Log_Pos 58753
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -236,7 +236,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 58826
|
Read_Master_Log_Pos 58829
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -251,7 +251,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 58826
|
Exec_Master_Log_Pos 58829
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -266,7 +266,7 @@ Seconds_Behind_Master #
|
|||||||
flush logs;
|
flush logs;
|
||||||
show master status;
|
show master status;
|
||||||
File master-bin.000002
|
File master-bin.000002
|
||||||
Position 102
|
Position 105
|
||||||
Binlog_Do_DB <Binlog_Ignore_DB>
|
Binlog_Do_DB <Binlog_Ignore_DB>
|
||||||
Binlog_Ignore_DB
|
Binlog_Ignore_DB
|
||||||
set global max_binlog_size= @my_max_binlog_size;
|
set global max_binlog_size= @my_max_binlog_size;
|
||||||
|
@ -6,12 +6,12 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 Yes Yes # 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 Yes Yes # 0 0 105 # None 0 No #
|
||||||
stop slave;
|
stop slave;
|
||||||
change master to master_user='test';
|
change master to master_user='test';
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 test MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 No No # 0 0 102 # None 0 No #
|
# 127.0.0.1 test MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 No No # 0 0 105 # None 0 No #
|
||||||
reset slave;
|
reset slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
@ -19,7 +19,7 @@ Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 Yes Yes # 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 Yes Yes # 0 0 105 # None 0 No #
|
||||||
stop slave;
|
stop slave;
|
||||||
reset slave;
|
reset slave;
|
||||||
start slave;
|
start slave;
|
||||||
|
@ -21,7 +21,7 @@ n
|
|||||||
4
|
4
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 740 slave-relay-bin.000004 # master-bin.000001 # No 0 0 311 # Master master-bin.000001 311 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 743 slave-relay-bin.000004 # master-bin.000001 # No 0 0 314 # Master master-bin.000001 311 No #
|
||||||
start slave until master_log_file='master-no-such-bin.000001', master_log_pos=291;
|
start slave until master_log_file='master-no-such-bin.000001', master_log_pos=291;
|
||||||
select * from t1;
|
select * from t1;
|
||||||
n
|
n
|
||||||
@ -31,7 +31,7 @@ n
|
|||||||
4
|
4
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 740 slave-relay-bin.000004 # master-bin.000001 # No 0 0 311 # Master master-no-such-bin.000001 291 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 743 slave-relay-bin.000004 # master-bin.000001 # No 0 0 314 # Master master-no-such-bin.000001 291 No #
|
||||||
start slave until relay_log_file='slave-relay-bin.000004', relay_log_pos=728;
|
start slave until relay_log_file='slave-relay-bin.000004', relay_log_pos=728;
|
||||||
select * from t2;
|
select * from t2;
|
||||||
n
|
n
|
||||||
@ -39,13 +39,13 @@ n
|
|||||||
2
|
2
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 740 slave-relay-bin.000004 # master-bin.000001 # No 0 0 586 # Relay slave-relay-bin.000004 728 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 743 slave-relay-bin.000004 # master-bin.000001 # No 0 0 589 # Relay slave-relay-bin.000004 728 No #
|
||||||
start slave;
|
start slave;
|
||||||
stop slave;
|
stop slave;
|
||||||
start slave until master_log_file='master-bin.000001', master_log_pos=740;
|
start slave until master_log_file='master-bin.000001', master_log_pos=740;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 740 slave-relay-bin.000004 # master-bin.000001 Yes No 0 0 740 # Master master-bin.000001 740 No #
|
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 743 slave-relay-bin.000004 # master-bin.000001 Yes No 0 0 743 # Master master-bin.000001 740 No #
|
||||||
start slave until master_log_file='master-bin', master_log_pos=561;
|
start slave until master_log_file='master-bin', master_log_pos=561;
|
||||||
ERROR HY000: Incorrect parameter or combination of parameters for START SLAVE UNTIL
|
ERROR HY000: Incorrect parameter or combination of parameters for START SLAVE UNTIL
|
||||||
start slave until master_log_file='master-bin.000001', master_log_pos=561, relay_log_pos=12;
|
start slave until master_log_file='master-bin.000001', master_log_pos=561, relay_log_pos=12;
|
||||||
|
@ -10,7 +10,7 @@ stop slave;
|
|||||||
change master to master_port=SLAVE_PORT;
|
change master to master_port=SLAVE_PORT;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # # 0 0 0 102 None 0 No NULL
|
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # # 0 0 0 105 None 0 No NULL
|
||||||
start slave;
|
start slave;
|
||||||
insert into t1 values (1);
|
insert into t1 values (1);
|
||||||
show status like "slave_running";
|
show status like "slave_running";
|
||||||
|
@ -10,7 +10,7 @@ stop slave;
|
|||||||
change master to master_port=SLAVE_PORT;
|
change master to master_port=SLAVE_PORT;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # 0 0 0 102 None 0 No NULL
|
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # 0 0 0 105 None 0 No NULL
|
||||||
start slave;
|
start slave;
|
||||||
insert into t1 values (1);
|
insert into t1 values (1);
|
||||||
select * from t1;
|
select * from t1;
|
||||||
|
@ -381,7 +381,7 @@ return 0;
|
|||||||
end|
|
end|
|
||||||
use mysqltest;
|
use mysqltest;
|
||||||
set @a:= mysqltest2.f1();
|
set @a:= mysqltest2.f1();
|
||||||
show binlog events in 'master-bin.000001' from 102;
|
show binlog events in 'master-bin.000001' from 105;
|
||||||
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 1 # drop database if exists mysqltest1
|
master-bin.000001 # Query 1 # drop database if exists mysqltest1
|
||||||
master-bin.000001 # Query 1 # create database mysqltest1
|
master-bin.000001 # Query 1 # create database mysqltest1
|
||||||
|
@ -103,7 +103,7 @@ a b
|
|||||||
1 cp850_general_ci
|
1 cp850_general_ci
|
||||||
drop database mysqltest2;
|
drop database mysqltest2;
|
||||||
drop database mysqltest3;
|
drop database mysqltest3;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest2
|
master-bin.000001 # Query 1 # drop database if exists mysqltest2
|
||||||
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
master-bin.000001 # Query 1 # drop database if exists mysqltest3
|
||||||
|
@ -12,13 +12,13 @@ create table t4 (a int);
|
|||||||
insert into t4 select * from t3;
|
insert into t4 select * from t3;
|
||||||
rename table t1 to t5, t2 to t1;
|
rename table t1 to t5, t2 to t1;
|
||||||
flush no_write_to_binlog tables;
|
flush no_write_to_binlog tables;
|
||||||
SHOW BINLOG EVENTS FROM 652 ;
|
SHOW BINLOG EVENTS FROM 655 ;
|
||||||
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 1 # use `test`; rename table t1 to t5, t2 to t1
|
master-bin.000001 # Query 1 # use `test`; rename table t1 to t5, t2 to t1
|
||||||
select * from t3;
|
select * from t3;
|
||||||
a
|
a
|
||||||
flush tables;
|
flush tables;
|
||||||
SHOW BINLOG EVENTS FROM 652 ;
|
SHOW BINLOG EVENTS FROM 655 ;
|
||||||
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 1 # use `test`; rename table t1 to t5, t2 to t1
|
master-bin.000001 # Query 1 # use `test`; rename table t1 to t5, t2 to t1
|
||||||
master-bin.000001 # Query 1 # use `test`; flush tables
|
master-bin.000001 # Query 1 # use `test`; flush tables
|
||||||
|
@ -26,14 +26,14 @@ master-bin.000001 # Query 1 # use `test`; drop table t1
|
|||||||
master-bin.000001 # Query 1 # use `test`; create table t1 (word char(20) not null)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1 (word char(20) not null)ENGINE=MyISAM
|
||||||
master-bin.000001 # Begin_load_query 1 # ;file_id=1;block_len=581
|
master-bin.000001 # Begin_load_query 1 # ;file_id=1;block_len=581
|
||||||
master-bin.000001 # Execute_load_query 1 # use `test`; load data infile '../std_data_ln/words.dat' into table t1 ignore 1 lines ;file_id=1
|
master-bin.000001 # Execute_load_query 1 # use `test`; load data infile '../std_data_ln/words.dat' into table t1 ignore 1 lines ;file_id=1
|
||||||
show binlog events from 102 limit 1;
|
show binlog events from 105 limit 1;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
||||||
show binlog events from 102 limit 2;
|
show binlog events from 105 limit 2;
|
||||||
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 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
master-bin.000001 # Query 1 # use `test`; create table t1(n int not null auto_increment primary key)ENGINE=MyISAM
|
||||||
master-bin.000001 # Intvar 1 # INSERT_ID=1
|
master-bin.000001 # Intvar 1 # INSERT_ID=1
|
||||||
show binlog events from 102 limit 2,1;
|
show binlog events from 105 limit 2,1;
|
||||||
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 1 # use `test`; insert into t1 values (NULL)
|
master-bin.000001 # Query 1 # use `test`; insert into t1 values (NULL)
|
||||||
flush logs;
|
flush logs;
|
||||||
@ -66,13 +66,13 @@ master-bin.000002 # Query 1 # use `test`; create table t2 (n int)ENGINE=MyISAM
|
|||||||
master-bin.000002 # Query 1 # use `test`; insert into t2 values (1)
|
master-bin.000002 # Query 1 # use `test`; insert into t2 values (1)
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
master-bin.000001 1343
|
master-bin.000001 1346
|
||||||
master-bin.000002 388
|
master-bin.000002 391
|
||||||
start slave;
|
start slave;
|
||||||
show binary logs;
|
show binary logs;
|
||||||
Log_name File_size
|
Log_name File_size
|
||||||
slave-bin.000001 1443
|
slave-bin.000001 1446
|
||||||
slave-bin.000002 289
|
slave-bin.000002 292
|
||||||
show binlog events in 'slave-bin.000001' from 4;
|
show binlog events in 'slave-bin.000001' from 4;
|
||||||
Log_name Pos Event_type Server_id End_log_pos Info
|
Log_name Pos Event_type Server_id End_log_pos Info
|
||||||
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
||||||
@ -92,7 +92,7 @@ slave-bin.000002 # Query 1 # use `test`; create table t2 (n int)ENGINE=MyISAM
|
|||||||
slave-bin.000002 # Query 1 # use `test`; insert into t2 values (1)
|
slave-bin.000002 # Query 1 # use `test`; insert into t2 values (1)
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 388 # # master-bin.000002 Yes Yes # 0 0 388 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 391 # # master-bin.000002 Yes Yes # 0 0 391 # None 0 No #
|
||||||
show binlog events in 'slave-bin.000005' from 4;
|
show binlog events in 'slave-bin.000005' from 4;
|
||||||
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -28,7 +28,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 72956
|
Read_Master_Log_Pos 72959
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -43,7 +43,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 72956
|
Exec_Master_Log_Pos 72959
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -71,7 +71,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 72956
|
Read_Master_Log_Pos 72959
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -86,7 +86,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 72956
|
Exec_Master_Log_Pos 72959
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -114,7 +114,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 72956
|
Read_Master_Log_Pos 72959
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -129,7 +129,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 72956
|
Exec_Master_Log_Pos 72959
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -195,7 +195,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 73042
|
Read_Master_Log_Pos 73045
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -210,7 +210,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 73042
|
Exec_Master_Log_Pos 73045
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -234,7 +234,7 @@ Master_User root
|
|||||||
Master_Port MASTER_PORT
|
Master_Port MASTER_PORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 73118
|
Read_Master_Log_Pos 73121
|
||||||
Relay_Log_File #
|
Relay_Log_File #
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -249,7 +249,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 73118
|
Exec_Master_Log_Pos 73121
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition None
|
Until_Condition None
|
||||||
Until_Log_File
|
Until_Log_File
|
||||||
@ -264,7 +264,7 @@ Seconds_Behind_Master #
|
|||||||
flush logs;
|
flush logs;
|
||||||
show master status;
|
show master status;
|
||||||
File master-bin.000002
|
File master-bin.000002
|
||||||
Position 102
|
Position 105
|
||||||
Binlog_Do_DB <Binlog_Ignore_DB>
|
Binlog_Do_DB <Binlog_Ignore_DB>
|
||||||
Binlog_Ignore_DB
|
Binlog_Ignore_DB
|
||||||
set global max_binlog_size= @my_max_binlog_size;
|
set global max_binlog_size= @my_max_binlog_size;
|
||||||
|
@ -19,7 +19,7 @@ n
|
|||||||
3
|
3
|
||||||
4
|
4
|
||||||
5
|
5
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest
|
master-bin.000001 # Query 1 # drop database if exists mysqltest
|
||||||
master-bin.000001 # Query 1 # create database mysqltest
|
master-bin.000001 # Query 1 # create database mysqltest
|
||||||
|
@ -6,12 +6,12 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 Yes Yes # 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 Yes Yes # 0 0 105 # None 0 No #
|
||||||
stop slave;
|
stop slave;
|
||||||
change master to master_user='test';
|
change master to master_user='test';
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 test MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 No No # 0 0 102 # None 0 No #
|
# 127.0.0.1 test MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 No No # 0 0 105 # None 0 No #
|
||||||
reset slave;
|
reset slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
@ -19,7 +19,7 @@ Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File
|
|||||||
start slave;
|
start slave;
|
||||||
show slave status;
|
show slave status;
|
||||||
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master
|
||||||
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 102 # # master-bin.000001 Yes Yes # 0 0 102 # None 0 No #
|
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 105 # # master-bin.000001 Yes Yes # 0 0 105 # None 0 No #
|
||||||
stop slave;
|
stop slave;
|
||||||
reset slave;
|
reset slave;
|
||||||
start slave;
|
start slave;
|
||||||
|
@ -26,7 +26,7 @@ Master_User root
|
|||||||
Master_Port MASTER_MYPORT
|
Master_Port MASTER_MYPORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 780
|
Read_Master_Log_Pos 783
|
||||||
Relay_Log_File slave-relay-bin.000004
|
Relay_Log_File slave-relay-bin.000004
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -41,7 +41,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 323
|
Exec_Master_Log_Pos 326
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition Master
|
Until_Condition Master
|
||||||
Until_Log_File master-bin.000001
|
Until_Log_File master-bin.000001
|
||||||
@ -67,7 +67,7 @@ Master_User root
|
|||||||
Master_Port MASTER_MYPORT
|
Master_Port MASTER_MYPORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 780
|
Read_Master_Log_Pos 783
|
||||||
Relay_Log_File slave-relay-bin.000004
|
Relay_Log_File slave-relay-bin.000004
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -82,7 +82,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 323
|
Exec_Master_Log_Pos 326
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition Master
|
Until_Condition Master
|
||||||
Until_Log_File master-no-such-bin.000001
|
Until_Log_File master-no-such-bin.000001
|
||||||
@ -106,7 +106,7 @@ Master_User root
|
|||||||
Master_Port MASTER_MYPORT
|
Master_Port MASTER_MYPORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 780
|
Read_Master_Log_Pos 783
|
||||||
Relay_Log_File slave-relay-bin.000004
|
Relay_Log_File slave-relay-bin.000004
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -121,7 +121,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 612
|
Exec_Master_Log_Pos 615
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition Relay
|
Until_Condition Relay
|
||||||
Until_Log_File slave-relay-bin.000004
|
Until_Log_File slave-relay-bin.000004
|
||||||
@ -143,7 +143,7 @@ Master_User root
|
|||||||
Master_Port MASTER_MYPORT
|
Master_Port MASTER_MYPORT
|
||||||
Connect_Retry 1
|
Connect_Retry 1
|
||||||
Master_Log_File master-bin.000001
|
Master_Log_File master-bin.000001
|
||||||
Read_Master_Log_Pos 780
|
Read_Master_Log_Pos 783
|
||||||
Relay_Log_File slave-relay-bin.000004
|
Relay_Log_File slave-relay-bin.000004
|
||||||
Relay_Log_Pos #
|
Relay_Log_Pos #
|
||||||
Relay_Master_Log_File master-bin.000001
|
Relay_Master_Log_File master-bin.000001
|
||||||
@ -158,7 +158,7 @@ Replicate_Wild_Ignore_Table
|
|||||||
Last_Errno 0
|
Last_Errno 0
|
||||||
Last_Error
|
Last_Error
|
||||||
Skip_Counter 0
|
Skip_Counter 0
|
||||||
Exec_Master_Log_Pos 780
|
Exec_Master_Log_Pos 783
|
||||||
Relay_Log_Space #
|
Relay_Log_Space #
|
||||||
Until_Condition Master
|
Until_Condition Master
|
||||||
Until_Log_File master-bin.000001
|
Until_Log_File master-bin.000001
|
||||||
|
@ -405,7 +405,7 @@ CREATE TABLE t12 (data LONG);
|
|||||||
LOCK TABLES t12 WRITE;
|
LOCK TABLES t12 WRITE;
|
||||||
INSERT INTO t12 VALUES(UUID());
|
INSERT INTO t12 VALUES(UUID());
|
||||||
UNLOCK TABLES;
|
UNLOCK TABLES;
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest1
|
master-bin.000001 # Query 1 # drop database if exists mysqltest1
|
||||||
master-bin.000001 # Query 1 # create database mysqltest1
|
master-bin.000001 # Query 1 # create database mysqltest1
|
||||||
@ -715,7 +715,7 @@ master-bin.000001 # Query 1 # use `mysqltest1`; DROP TABLE IF EXISTS t12
|
|||||||
master-bin.000001 # Query 1 # use `mysqltest1`; CREATE TABLE t12 (data LONG)
|
master-bin.000001 # Query 1 # use `mysqltest1`; CREATE TABLE t12 (data LONG)
|
||||||
master-bin.000001 # Table_map 1 # table_id: # (mysqltest1.t12)
|
master-bin.000001 # Table_map 1 # table_id: # (mysqltest1.t12)
|
||||||
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 1 # drop database if exists mysqltest1
|
master-bin.000001 # Query 1 # drop database if exists mysqltest1
|
||||||
master-bin.000001 # Query 1 # create database mysqltest1
|
master-bin.000001 # Query 1 # create database mysqltest1
|
||||||
|
@ -31,11 +31,11 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Query 1 307 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 310 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Query 1 387 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 310 Query 1 390 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 387 Query 1 463 use `test`; DROP TABLE t1
|
master-bin.000001 390 Query 1 466 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=MIXED;
|
SET SESSION BINLOG_FORMAT=MIXED;
|
||||||
SET GLOBAL BINLOG_FORMAT=MIXED;
|
SET GLOBAL BINLOG_FORMAT=MIXED;
|
||||||
@ -63,11 +63,11 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Query 1 307 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 310 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Query 1 387 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 310 Query 1 390 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 387 Query 1 463 use `test`; DROP TABLE t1
|
master-bin.000001 390 Query 1 466 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=ROW;
|
SET SESSION BINLOG_FORMAT=ROW;
|
||||||
SET GLOBAL BINLOG_FORMAT=ROW;
|
SET GLOBAL BINLOG_FORMAT=ROW;
|
||||||
@ -95,12 +95,12 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Table_map 1 250 table_id: # (test.t1)
|
master-bin.000001 213 Table_map 1 253 table_id: # (test.t1)
|
||||||
master-bin.000001 250 Write_rows 1 297 table_id: # flags: STMT_END_F
|
master-bin.000001 253 Write_rows 1 300 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 297 Query 1 377 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 300 Query 1 380 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 377 Query 1 453 use `test`; DROP TABLE t1
|
master-bin.000001 380 Query 1 456 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=STATEMENT;
|
SET SESSION BINLOG_FORMAT=STATEMENT;
|
||||||
SET GLOBAL BINLOG_FORMAT=STATEMENT;
|
SET GLOBAL BINLOG_FORMAT=STATEMENT;
|
||||||
@ -128,11 +128,11 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Query 1 307 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 310 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Query 1 384 use `test`; DELETE FROM t1
|
master-bin.000001 310 Query 1 387 use `test`; DELETE FROM t1
|
||||||
master-bin.000001 384 Query 1 460 use `test`; DROP TABLE t1
|
master-bin.000001 387 Query 1 463 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=MIXED;
|
SET SESSION BINLOG_FORMAT=MIXED;
|
||||||
SET GLOBAL BINLOG_FORMAT=MIXED;
|
SET GLOBAL BINLOG_FORMAT=MIXED;
|
||||||
@ -160,11 +160,11 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Query 1 307 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 310 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Query 1 384 use `test`; DELETE FROM t1
|
master-bin.000001 310 Query 1 387 use `test`; DELETE FROM t1
|
||||||
master-bin.000001 384 Query 1 460 use `test`; DROP TABLE t1
|
master-bin.000001 387 Query 1 463 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=ROW;
|
SET SESSION BINLOG_FORMAT=ROW;
|
||||||
SET GLOBAL BINLOG_FORMAT=ROW;
|
SET GLOBAL BINLOG_FORMAT=ROW;
|
||||||
@ -193,10 +193,10 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=MyISAM
|
||||||
master-bin.000001 210 Table_map 1 250 table_id: # (test.t1)
|
master-bin.000001 213 Table_map 1 253 table_id: # (test.t1)
|
||||||
master-bin.000001 250 Write_rows 1 297 table_id: # flags: STMT_END_F
|
master-bin.000001 253 Write_rows 1 300 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 297 Table_map 1 337 table_id: # (test.t1)
|
master-bin.000001 300 Table_map 1 340 table_id: # (test.t1)
|
||||||
master-bin.000001 337 Delete_rows 1 384 table_id: # flags: STMT_END_F
|
master-bin.000001 340 Delete_rows 1 387 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 384 Query 1 460 use `test`; DROP TABLE t1
|
master-bin.000001 387 Query 1 463 use `test`; DROP TABLE t1
|
||||||
|
@ -31,13 +31,13 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Xid 1 334 COMMIT /* xid= */
|
master-bin.000001 310 Xid 1 337 COMMIT /* xid= */
|
||||||
master-bin.000001 334 Query 1 80 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 337 Query 1 80 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 414 Xid 1 441 COMMIT /* xid= */
|
master-bin.000001 417 Xid 1 444 COMMIT /* xid= */
|
||||||
master-bin.000001 441 Query 1 517 use `test`; DROP TABLE t1
|
master-bin.000001 444 Query 1 520 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=MIXED;
|
SET SESSION BINLOG_FORMAT=MIXED;
|
||||||
SET GLOBAL BINLOG_FORMAT=MIXED;
|
SET GLOBAL BINLOG_FORMAT=MIXED;
|
||||||
@ -65,13 +65,13 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Xid 1 334 COMMIT /* xid= */
|
master-bin.000001 310 Xid 1 337 COMMIT /* xid= */
|
||||||
master-bin.000001 334 Query 1 80 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 337 Query 1 80 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 414 Xid 1 441 COMMIT /* xid= */
|
master-bin.000001 417 Xid 1 444 COMMIT /* xid= */
|
||||||
master-bin.000001 441 Query 1 517 use `test`; DROP TABLE t1
|
master-bin.000001 444 Query 1 520 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=ROW;
|
SET SESSION BINLOG_FORMAT=ROW;
|
||||||
SET GLOBAL BINLOG_FORMAT=ROW;
|
SET GLOBAL BINLOG_FORMAT=ROW;
|
||||||
@ -99,14 +99,14 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 213 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 250 Write_rows 1 87 table_id: # flags: STMT_END_F
|
master-bin.000001 253 Write_rows 1 87 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 297 Xid 1 324 COMMIT /* xid= */
|
master-bin.000001 300 Xid 1 327 COMMIT /* xid= */
|
||||||
master-bin.000001 324 Query 1 80 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 327 Query 1 80 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 404 Xid 1 431 COMMIT /* xid= */
|
master-bin.000001 407 Xid 1 434 COMMIT /* xid= */
|
||||||
master-bin.000001 431 Query 1 507 use `test`; DROP TABLE t1
|
master-bin.000001 434 Query 1 510 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=STATEMENT;
|
SET SESSION BINLOG_FORMAT=STATEMENT;
|
||||||
SET GLOBAL BINLOG_FORMAT=STATEMENT;
|
SET GLOBAL BINLOG_FORMAT=STATEMENT;
|
||||||
@ -134,13 +134,13 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Xid 1 334 COMMIT /* xid= */
|
master-bin.000001 310 Xid 1 337 COMMIT /* xid= */
|
||||||
master-bin.000001 334 Query 1 77 use `test`; DELETE FROM t1
|
master-bin.000001 337 Query 1 77 use `test`; DELETE FROM t1
|
||||||
master-bin.000001 411 Xid 1 438 COMMIT /* xid= */
|
master-bin.000001 414 Xid 1 441 COMMIT /* xid= */
|
||||||
master-bin.000001 438 Query 1 514 use `test`; DROP TABLE t1
|
master-bin.000001 441 Query 1 517 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=MIXED;
|
SET SESSION BINLOG_FORMAT=MIXED;
|
||||||
SET GLOBAL BINLOG_FORMAT=MIXED;
|
SET GLOBAL BINLOG_FORMAT=MIXED;
|
||||||
@ -168,13 +168,13 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
master-bin.000001 213 Query 1 97 use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
||||||
master-bin.000001 307 Xid 1 334 COMMIT /* xid= */
|
master-bin.000001 310 Xid 1 337 COMMIT /* xid= */
|
||||||
master-bin.000001 334 Query 1 77 use `test`; DELETE FROM t1
|
master-bin.000001 337 Query 1 77 use `test`; DELETE FROM t1
|
||||||
master-bin.000001 411 Xid 1 438 COMMIT /* xid= */
|
master-bin.000001 414 Xid 1 441 COMMIT /* xid= */
|
||||||
master-bin.000001 438 Query 1 514 use `test`; DROP TABLE t1
|
master-bin.000001 441 Query 1 517 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
SET SESSION BINLOG_FORMAT=ROW;
|
SET SESSION BINLOG_FORMAT=ROW;
|
||||||
SET GLOBAL BINLOG_FORMAT=ROW;
|
SET GLOBAL BINLOG_FORMAT=ROW;
|
||||||
@ -203,12 +203,12 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 210 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
master-bin.000001 105 Query 1 213 use `test`; CREATE TABLE t1 (a INT, b LONG) ENGINE=InnoDB
|
||||||
master-bin.000001 210 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 213 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 250 Write_rows 1 87 table_id: # flags: STMT_END_F
|
master-bin.000001 253 Write_rows 1 87 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 297 Xid 1 324 COMMIT /* xid= */
|
master-bin.000001 300 Xid 1 327 COMMIT /* xid= */
|
||||||
master-bin.000001 324 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 327 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 364 Delete_rows 1 87 table_id: # flags: STMT_END_F
|
master-bin.000001 367 Delete_rows 1 87 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 411 Xid 1 438 COMMIT /* xid= */
|
master-bin.000001 414 Xid 1 441 COMMIT /* xid= */
|
||||||
master-bin.000001 438 Query 1 514 use `test`; DROP TABLE t1
|
master-bin.000001 441 Query 1 517 use `test`; DROP TABLE t1
|
||||||
|
@ -29,16 +29,17 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 219 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
master-bin.000001 105 Query 1 222 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
||||||
master-bin.000001 219 Query 1 283 BEGIN
|
master-bin.000001 222 Query 1 286 BEGIN
|
||||||
master-bin.000001 283 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 286 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 323 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 326 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 378 Write_rows 1 137 table_id: #
|
master-bin.000001 381 Write_rows 1 137 table_id: #
|
||||||
master-bin.000001 420 Write_rows 1 184 table_id: # flags: STMT_END_F
|
master-bin.000001 423 Write_rows 1 175 table_id: #
|
||||||
master-bin.000001 467 Query 1 532 COMMIT
|
master-bin.000001 461 Write_rows 1 213 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 532 Query 1 612 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 499 Query 1 564 COMMIT
|
||||||
master-bin.000001 612 Query 1 688 use `test`; DROP TABLE t1
|
master-bin.000001 564 Query 1 644 use `test`; TRUNCATE TABLE t1
|
||||||
|
master-bin.000001 644 Query 1 720 use `test`; DROP TABLE t1
|
||||||
**** On Master ****
|
**** On Master ****
|
||||||
CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB;
|
CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB;
|
||||||
INSERT INTO t1 VALUES (1,1), (2,2);
|
INSERT INTO t1 VALUES (1,1), (2,2);
|
||||||
@ -65,27 +66,30 @@ a b
|
|||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
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 4 Format_desc 1 102 Server ver: SERVER_VERSION, Binlog ver: 4
|
master-bin.000001 4 Format_desc 1 105 Server ver: SERVER_VERSION, Binlog ver: 4
|
||||||
master-bin.000001 102 Query 1 219 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
master-bin.000001 105 Query 1 222 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
||||||
master-bin.000001 219 Query 1 283 BEGIN
|
master-bin.000001 222 Query 1 286 BEGIN
|
||||||
master-bin.000001 283 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 286 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 323 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 326 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 378 Write_rows 1 137 table_id: #
|
master-bin.000001 381 Write_rows 1 137 table_id: #
|
||||||
master-bin.000001 420 Write_rows 1 184 table_id: # flags: STMT_END_F
|
master-bin.000001 423 Write_rows 1 175 table_id: #
|
||||||
master-bin.000001 467 Query 1 532 COMMIT
|
master-bin.000001 461 Write_rows 1 213 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 532 Query 1 612 use `test`; TRUNCATE TABLE t1
|
master-bin.000001 499 Query 1 564 COMMIT
|
||||||
master-bin.000001 612 Query 1 688 use `test`; DROP TABLE t1
|
master-bin.000001 564 Query 1 644 use `test`; TRUNCATE TABLE t1
|
||||||
master-bin.000001 688 Query 1 805 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
master-bin.000001 644 Query 1 720 use `test`; DROP TABLE t1
|
||||||
master-bin.000001 805 Query 1 869 BEGIN
|
master-bin.000001 720 Query 1 837 use `test`; CREATE TABLE t1 (a INT PRIMARY KEY, b LONG) ENGINE=NDB
|
||||||
master-bin.000001 869 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 837 Query 1 901 BEGIN
|
||||||
master-bin.000001 909 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 901 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 964 Write_rows 1 137 table_id: #
|
master-bin.000001 941 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 1006 Write_rows 1 184 table_id: # flags: STMT_END_F
|
master-bin.000001 996 Write_rows 1 137 table_id: #
|
||||||
master-bin.000001 1053 Query 1 1118 COMMIT
|
master-bin.000001 1038 Write_rows 1 175 table_id: #
|
||||||
master-bin.000001 1118 Query 1 1182 BEGIN
|
master-bin.000001 1076 Write_rows 1 213 table_id: # flags: STMT_END_F
|
||||||
master-bin.000001 1182 Table_map 1 40 table_id: # (test.t1)
|
master-bin.000001 1114 Query 1 1179 COMMIT
|
||||||
master-bin.000001 1222 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
master-bin.000001 1179 Query 1 1243 BEGIN
|
||||||
master-bin.000001 1277 Write_rows 1 137 table_id: #
|
master-bin.000001 1243 Table_map 1 40 table_id: # (test.t1)
|
||||||
master-bin.000001 1319 Delete_rows 1 176 table_id: # flags: STMT_END_F
|
master-bin.000001 1283 Table_map 1 95 table_id: # (mysql.ndb_apply_status)
|
||||||
master-bin.000001 1358 Query 1 1423 COMMIT
|
master-bin.000001 1338 Write_rows 1 137 table_id: #
|
||||||
master-bin.000001 1423 Query 1 1499 use `test`; DROP TABLE t1
|
master-bin.000001 1380 Delete_rows 1 171 table_id: #
|
||||||
|
master-bin.000001 1414 Delete_rows 1 205 table_id: # flags: STMT_END_F
|
||||||
|
master-bin.000001 1448 Query 1 1513 COMMIT
|
||||||
|
master-bin.000001 1513 Query 1 1589 use `test`; DROP TABLE t1
|
||||||
|
@ -6,7 +6,7 @@ INSERT INTO t1 VALUES(@`a b`);
|
|||||||
set @var1= "';aaa";
|
set @var1= "';aaa";
|
||||||
SET @var2=char(ascii('a'));
|
SET @var2=char(ascii('a'));
|
||||||
insert into t1 values (@var1),(@var2);
|
insert into t1 values (@var1),(@var2);
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
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 # User var 1 # @`a b`=_latin1 0x68656C6C6F COLLATE latin1_swedish_ci
|
master-bin.000001 # User var 1 # @`a b`=_latin1 0x68656C6C6F COLLATE latin1_swedish_ci
|
||||||
master-bin.000001 # Query 1 # use `test`; INSERT INTO t1 VALUES(@`a b`)
|
master-bin.000001 # Query 1 # use `test`; INSERT INTO t1 VALUES(@`a b`)
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
# ER_SERVER_SHUTDOWN (i.e. disconnection just rolls back transaction
|
# ER_SERVER_SHUTDOWN (i.e. disconnection just rolls back transaction
|
||||||
# and does not make slave to stop)
|
# and does not make slave to stop)
|
||||||
flush logs;
|
flush logs;
|
||||||
--exec $MYSQL_BINLOG --start-position=516 $MYSQLTEST_VARDIR/log/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
--exec $MYSQL_BINLOG --start-position=519 $MYSQLTEST_VARDIR/log/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
eval select
|
eval select
|
||||||
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
# ER_SERVER_SHUTDOWN (i.e. disconnection just rolls back transaction
|
# ER_SERVER_SHUTDOWN (i.e. disconnection just rolls back transaction
|
||||||
# and does not make slave to stop)
|
# and does not make slave to stop)
|
||||||
flush logs;
|
flush logs;
|
||||||
--exec $MYSQL_BINLOG --start-position=551 $MYSQLTEST_VARDIR/log/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
--exec $MYSQL_BINLOG --start-position=554 $MYSQLTEST_VARDIR/log/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
eval select
|
eval select
|
||||||
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
||||||
|
@ -22,7 +22,7 @@ CALL bug18293("Foo's a Bar", _cp932 0xED40ED41ED42, 47.93)|
|
|||||||
SELECT HEX(s1),HEX(s2),d FROM t4|
|
SELECT HEX(s1),HEX(s2),d FROM t4|
|
||||||
DROP PROCEDURE bug18293|
|
DROP PROCEDURE bug18293|
|
||||||
DROP TABLE t4|
|
DROP TABLE t4|
|
||||||
SHOW BINLOG EVENTS FROM 406|
|
SHOW BINLOG EVENTS FROM 409|
|
||||||
delimiter ;|
|
delimiter ;|
|
||||||
|
|
||||||
# End of 5.0 tests
|
# End of 5.0 tests
|
||||||
|
@ -65,7 +65,7 @@ select "--- --database --" as "";
|
|||||||
select "--- --position --" as "";
|
select "--- --position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --position=235 $MYSQLTEST_VARDIR/log/master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --position=238 $MYSQLTEST_VARDIR/log/master-bin.000002
|
||||||
|
|
||||||
# These are tests for remote binlog.
|
# These are tests for remote binlog.
|
||||||
# They should return the same as previous test.
|
# They should return the same as previous test.
|
||||||
@ -97,7 +97,7 @@ select "--- --database --" as "";
|
|||||||
select "--- --position --" as "";
|
select "--- --position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --read-from-remote-server --position=235 --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --read-from-remote-server --position=238 --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000002
|
||||||
|
|
||||||
# Bug#7853 (mysqlbinlog does not accept input from stdin)
|
# Bug#7853 (mysqlbinlog does not accept input from stdin)
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
|
@ -52,11 +52,11 @@ select "--- offset --" as "";
|
|||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-position --" as "";
|
select "--- start-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --start-position=604 $MYSQLTEST_VARDIR/log/master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --start-position=607 $MYSQLTEST_VARDIR/log/master-bin.000001
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- stop-position --" as "";
|
select "--- stop-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --stop-position=604 $MYSQLTEST_VARDIR/log/master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --stop-position=607 $MYSQLTEST_VARDIR/log/master-bin.000001
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-datetime --" as "";
|
select "--- start-datetime --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
@ -82,11 +82,11 @@ select "--- offset --" as "";
|
|||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-position --" as "";
|
select "--- start-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --start-position=604 $MYSQLTEST_VARDIR/log/master-bin.000001 $MYSQLTEST_VARDIR/log/master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --start-position=607 $MYSQLTEST_VARDIR/log/master-bin.000001 $MYSQLTEST_VARDIR/log/master-bin.000002
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- stop-position --" as "";
|
select "--- stop-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --stop-position=130 $MYSQLTEST_VARDIR/log/master-bin.000001 $MYSQLTEST_VARDIR/log/master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --stop-position=133 $MYSQLTEST_VARDIR/log/master-bin.000001 $MYSQLTEST_VARDIR/log/master-bin.000002
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-datetime --" as "";
|
select "--- start-datetime --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
@ -109,11 +109,11 @@ select "--- offset --" as "";
|
|||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-position --" as "";
|
select "--- start-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --start-position=604 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --start-position=607 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- stop-position --" as "";
|
select "--- stop-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --stop-position=604 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --stop-position=607 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-datetime --" as "";
|
select "--- start-datetime --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
@ -136,11 +136,11 @@ select "--- offset --" as "";
|
|||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-position --" as "";
|
select "--- start-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --start-position=604 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001 master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --start-position=607 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001 master-bin.000002
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- stop-position --" as "";
|
select "--- stop-position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--exec $MYSQL_BINLOG --short-form --stop-position=130 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001 master-bin.000002
|
--exec $MYSQL_BINLOG --short-form --stop-position=133 --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001 master-bin.000002
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
select "--- start-datetime --" as "";
|
select "--- start-datetime --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
|
@ -22,7 +22,7 @@ sync_with_master;
|
|||||||
select count(*) from test.t1; # check that LOAD was replicated
|
select count(*) from test.t1; # check that LOAD was replicated
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102; # should be nothing
|
show binlog events from 105; # should be nothing
|
||||||
|
|
||||||
# Cleanup
|
# Cleanup
|
||||||
connection master;
|
connection master;
|
||||||
|
@ -49,7 +49,7 @@ insert into t1 values (1),(2),(3);
|
|||||||
save_master_pos;
|
save_master_pos;
|
||||||
connection slave;
|
connection slave;
|
||||||
stop slave;
|
stop slave;
|
||||||
change master to master_log_pos=102;
|
change master to master_log_pos=105;
|
||||||
start slave;
|
start slave;
|
||||||
sync_with_master;
|
sync_with_master;
|
||||||
select * from t1 ORDER BY n;
|
select * from t1 ORDER BY n;
|
||||||
|
@ -1 +1,2 @@
|
|||||||
--binlog_ignore_db=test_ignore
|
--binlog_ignore_db=test_ignore --innodb
|
||||||
|
|
||||||
|
1
mysql-test/t/rpl_row_basic_11bugs-slave.opt
Normal file
1
mysql-test/t/rpl_row_basic_11bugs-slave.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--innodb
|
@ -25,7 +25,7 @@ CREATE TABLE t2 (a INT, b INT);
|
|||||||
SHOW TABLES;
|
SHOW TABLES;
|
||||||
INSERT INTO t2 VALUES (3,3), (4,4);
|
INSERT INTO t2 VALUES (3,3), (4,4);
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 102;
|
SHOW BINLOG EVENTS FROM 105;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
--echo **** On Slave ****
|
--echo **** On Slave ****
|
||||||
SHOW DATABASES;
|
SHOW DATABASES;
|
||||||
@ -117,5 +117,69 @@ sync_slave_with_master;
|
|||||||
SELECT HEX(a),b FROM t1;
|
SELECT HEX(a),b FROM t1;
|
||||||
|
|
||||||
connection master;
|
connection master;
|
||||||
DROP TABLE t1;
|
DROP TABLE IF EXISTS t1;
|
||||||
|
sync_slave_with_master;
|
||||||
|
|
||||||
|
# BUG#22583: RBR between MyISAM and non-MyISAM tables containing a BIT
|
||||||
|
# field does not work
|
||||||
|
|
||||||
|
--echo ================ Test for BUG#22583 ================
|
||||||
|
--disable_query_log
|
||||||
|
--source include/master-slave-reset.inc
|
||||||
|
--enable_query_log
|
||||||
|
|
||||||
|
--echo **** On Master ****
|
||||||
|
connection master;
|
||||||
|
CREATE TABLE t1_myisam (k INT, a BIT(1), b BIT(9)) ENGINE=MYISAM;
|
||||||
|
CREATE TABLE t1_innodb (k INT, a BIT(1), b BIT(9)) ENGINE=INNODB;
|
||||||
|
CREATE TABLE t2_myisam (k INT, a BIT(1) NOT NULL, b BIT(4) NOT NULL) ENGINE=MYISAM;
|
||||||
|
CREATE TABLE t2_innodb (k INT, a BIT(1) NOT NULL, b BIT(4) NOT NULL) ENGINE=INNODB;
|
||||||
|
--echo **** On Slave ****
|
||||||
|
sync_slave_with_master;
|
||||||
|
ALTER TABLE t1_myisam ENGINE=INNODB;
|
||||||
|
ALTER TABLE t1_innodb ENGINE=MYISAM;
|
||||||
|
ALTER TABLE t2_myisam ENGINE=INNODB;
|
||||||
|
ALTER TABLE t2_innodb ENGINE=MYISAM;
|
||||||
|
|
||||||
|
--echo **** On Master ****
|
||||||
|
connection master;
|
||||||
|
INSERT INTO t1_myisam VALUES(1, b'0', 257);
|
||||||
|
INSERT INTO t1_myisam VALUES(2, b'1', 256);
|
||||||
|
INSERT INTO t1_innodb VALUES(1, b'0', 257);
|
||||||
|
INSERT INTO t1_innodb VALUES(2, b'1', 256);
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
INSERT INTO t2_myisam VALUES(1, b'0', 9);
|
||||||
|
INSERT INTO t2_myisam VALUES(2, b'1', 8);
|
||||||
|
INSERT INTO t2_innodb VALUES(1, b'0', 9);
|
||||||
|
INSERT INTO t2_innodb VALUES(2, b'1', 8);
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
--echo **** On Slave ****
|
||||||
|
sync_slave_with_master;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
|
||||||
|
--echo **** On Master ****
|
||||||
|
connection master;
|
||||||
|
UPDATE t1_myisam SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
UPDATE t1_innodb SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
UPDATE t2_myisam SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
UPDATE t2_innodb SET a=0 WHERE k=2;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
--echo **** On Slave ****
|
||||||
|
sync_slave_with_master;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t1_innodb;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_myisam;
|
||||||
|
SELECT k, HEX(a),HEX(b) FROM t2_innodb;
|
||||||
|
|
||||||
|
--echo **** On Master ****
|
||||||
|
connection master;
|
||||||
|
DROP TABLE IF EXISTS t1_myisam, t1_innodb, t2_myisam, t2_innodb;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
|
@ -34,9 +34,9 @@ CREATE TABLE t1 (a INT, b INT);
|
|||||||
CREATE TABLE t2 (a INT, b INT) ENGINE=Merge;
|
CREATE TABLE t2 (a INT, b INT) ENGINE=Merge;
|
||||||
CREATE TABLE t3 (a INT, b INT) CHARSET=utf8;
|
CREATE TABLE t3 (a INT, b INT) CHARSET=utf8;
|
||||||
CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8;
|
CREATE TABLE t4 (a INT, b INT) ENGINE=Merge CHARSET=utf8;
|
||||||
--replace_column 1 # 4 # 5 #
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
--query_vertical SHOW BINLOG EVENTS FROM 212
|
--query_vertical SHOW BINLOG EVENTS FROM 215
|
||||||
--echo **** On Master ****
|
--echo **** On Master ****
|
||||||
--query_vertical SHOW CREATE TABLE t1
|
--query_vertical SHOW CREATE TABLE t1
|
||||||
--query_vertical SHOW CREATE TABLE t2
|
--query_vertical SHOW CREATE TABLE t2
|
||||||
@ -70,8 +70,9 @@ connection master;
|
|||||||
--error ER_DUP_ENTRY_WITH_KEY_NAME
|
--error ER_DUP_ENTRY_WITH_KEY_NAME
|
||||||
CREATE TABLE t7 (UNIQUE(b)) SELECT a,b FROM tt3;
|
CREATE TABLE t7 (UNIQUE(b)) SELECT a,b FROM tt3;
|
||||||
# Shouldn't be written to the binary log
|
# Shouldn't be written to the binary log
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 1118;
|
SHOW BINLOG EVENTS FROM 1097;
|
||||||
|
|
||||||
# Test that INSERT-SELECT works the same way as for SBR.
|
# Test that INSERT-SELECT works the same way as for SBR.
|
||||||
CREATE TABLE t7 (a INT, b INT UNIQUE);
|
CREATE TABLE t7 (a INT, b INT UNIQUE);
|
||||||
@ -79,8 +80,9 @@ CREATE TABLE t7 (a INT, b INT UNIQUE);
|
|||||||
INSERT INTO t7 SELECT a,b FROM tt3;
|
INSERT INTO t7 SELECT a,b FROM tt3;
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
# Should be written to the binary log
|
# Should be written to the binary log
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 1118;
|
SHOW BINLOG EVENTS FROM 1097;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
|
|
||||||
@ -90,8 +92,9 @@ INSERT INTO tt4 VALUES (4,8), (5,10), (6,12);
|
|||||||
BEGIN;
|
BEGIN;
|
||||||
INSERT INTO t7 SELECT a,b FROM tt4;
|
INSERT INTO t7 SELECT a,b FROM tt4;
|
||||||
ROLLBACK;
|
ROLLBACK;
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 1314;
|
SHOW BINLOG EVENTS FROM 1293;
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
SELECT * FROM t7 ORDER BY a,b;
|
SELECT * FROM t7 ORDER BY a,b;
|
||||||
@ -105,8 +108,9 @@ CREATE TEMPORARY TABLE tt7 SELECT 1;
|
|||||||
--echo **** On Master ****
|
--echo **** On Master ****
|
||||||
--query_vertical SHOW CREATE TABLE t8
|
--query_vertical SHOW CREATE TABLE t8
|
||||||
--query_vertical SHOW CREATE TABLE t9
|
--query_vertical SHOW CREATE TABLE t9
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 1410;
|
SHOW BINLOG EVENTS FROM 1389;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
--echo **** On Slave ****
|
--echo **** On Slave ****
|
||||||
--query_vertical SHOW CREATE TABLE t8
|
--query_vertical SHOW CREATE TABLE t8
|
||||||
@ -156,6 +160,7 @@ SELECT * FROM t1 ORDER BY a;
|
|||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
SELECT * FROM t3 ORDER BY a;
|
SELECT * FROM t3 ORDER BY a;
|
||||||
SELECT * FROM t4 ORDER BY a;
|
SELECT * FROM t4 ORDER BY a;
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
@ -201,6 +206,7 @@ INSERT INTO t2 SELECT a+2 FROM tt1;
|
|||||||
COMMIT;
|
COMMIT;
|
||||||
|
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS;
|
SHOW BINLOG EVENTS;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
@ -219,8 +225,9 @@ INSERT INTO t2 SELECT a+2 FROM tt2;
|
|||||||
ROLLBACK;
|
ROLLBACK;
|
||||||
|
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
|
--replace_column 1 # 4 #
|
||||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /Server ver: .*, Binlog ver: .*/Server ver: #, Binlog ver: #/ /table_id: [0-9]+/table_id: #/
|
||||||
SHOW BINLOG EVENTS FROM 627;
|
SHOW BINLOG EVENTS FROM 630;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
SELECT * FROM t2 ORDER BY a;
|
SELECT * FROM t2 ORDER BY a;
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
# depends on the binlog output
|
# depends on the binlog output
|
||||||
-- source include/have_binlog_format_row.inc
|
-- source include/have_binlog_format_row.inc
|
||||||
|
|
||||||
let $rename_event_pos= 615;
|
let $rename_event_pos= 618;
|
||||||
|
|
||||||
# Bug#18326: Do not lock table for writing during prepare of statement
|
# Bug#18326: Do not lock table for writing during prepare of statement
|
||||||
# The use of the ps protocol causes extra table maps in the binlog, so
|
# The use of the ps protocol causes extra table maps in the binlog, so
|
||||||
|
@ -167,7 +167,7 @@ connection master;
|
|||||||
select "--- Test 2 position test --" as "";
|
select "--- Test 2 position test --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --position=412 $MYSQLTEST_VARDIR/log/master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --position=415 $MYSQLTEST_VARDIR/log/master-bin.000001
|
||||||
|
|
||||||
# These are tests for remote binlog.
|
# These are tests for remote binlog.
|
||||||
# They should return the same as previous test.
|
# They should return the same as previous test.
|
||||||
@ -263,7 +263,7 @@ select "--- Test 6 reading stdin --" as "";
|
|||||||
select "--- Test 7 reading stdin w/position --" as "";
|
select "--- Test 7 reading stdin w/position --" as "";
|
||||||
--enable_query_log
|
--enable_query_log
|
||||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
||||||
--exec $MYSQL_BINLOG --short-form --position=412 - < $MYSQLTEST_VARDIR/log/master-bin.000001
|
--exec $MYSQL_BINLOG --short-form --position=415 - < $MYSQLTEST_VARDIR/log/master-bin.000001
|
||||||
|
|
||||||
# Bug#16217 (mysql client did not know how not switch its internal charset)
|
# Bug#16217 (mysql client did not know how not switch its internal charset)
|
||||||
--disable_query_log
|
--disable_query_log
|
||||||
|
@ -566,7 +566,7 @@ connection master;
|
|||||||
# were written to the binary log.
|
# were written to the binary log.
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events in 'master-bin.000001' from 102;
|
show binlog events in 'master-bin.000001' from 105;
|
||||||
|
|
||||||
|
|
||||||
# Restore log_bin_trust_function_creators to its original value.
|
# Restore log_bin_trust_function_creators to its original value.
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
# depends on the binlog output
|
# depends on the binlog output
|
||||||
--source include/have_binlog_format_mixed_or_statement.inc
|
--source include/have_binlog_format_mixed_or_statement.inc
|
||||||
|
|
||||||
let $rename_event_pos= 652;
|
let $rename_event_pos= 655;
|
||||||
-- source extra/rpl_tests/rpl_flsh_tbls.test
|
-- source extra/rpl_tests/rpl_flsh_tbls.test
|
||||||
|
|
||||||
# End of 4.1 tests
|
# End of 4.1 tests
|
||||||
|
@ -521,7 +521,7 @@ UNLOCK TABLES;
|
|||||||
|
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
sync_slave_with_master;
|
sync_slave_with_master;
|
||||||
|
|
||||||
# as we're using UUID we don't SELECT but use "diff" like in rpl_row_UUID
|
# as we're using UUID we don't SELECT but use "diff" like in rpl_row_UUID
|
||||||
@ -538,7 +538,7 @@ diff_files $MYSQLTEST_VARDIR/tmp/rpl_switch_stm_row_mixed_master.sql $MYSQLTEST_
|
|||||||
connection master;
|
connection master;
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
|
|
||||||
# Now test that mysqlbinlog works fine on a binlog generated by the
|
# Now test that mysqlbinlog works fine on a binlog generated by the
|
||||||
# mixed mode
|
# mixed mode
|
||||||
|
@ -15,7 +15,7 @@ SET @var2=char(ascii('a'));
|
|||||||
insert into t1 values (@var1),(@var2);
|
insert into t1 values (@var1),(@var2);
|
||||||
--replace_column 2 # 5 #
|
--replace_column 2 # 5 #
|
||||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||||
show binlog events from 102;
|
show binlog events from 105;
|
||||||
# more important than SHOW BINLOG EVENTS, mysqlbinlog (where we
|
# more important than SHOW BINLOG EVENTS, mysqlbinlog (where we
|
||||||
# absolutely need variables names to be quoted and strings to be
|
# absolutely need variables names to be quoted and strings to be
|
||||||
# escaped).
|
# escaped).
|
||||||
|
220
sql/log_event.cc
220
sql/log_event.cc
@ -1000,7 +1000,8 @@ Log_event* Log_event::read_log_event(const char* buf, uint event_len,
|
|||||||
ev = new Execute_load_query_log_event(buf, event_len, description_event);
|
ev = new Execute_load_query_log_event(buf, event_len, description_event);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
DBUG_PRINT("error",("Unknown evernt code: %d",(int) buf[EVENT_TYPE_OFFSET]));
|
DBUG_PRINT("error",("Unknown event code: %d",
|
||||||
|
(int) buf[EVENT_TYPE_OFFSET]));
|
||||||
ev= NULL;
|
ev= NULL;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -5595,10 +5596,10 @@ int Rows_log_event::do_add_row_data(byte *const row_data,
|
|||||||
row_end Pointer to variable that will hold the value of the
|
row_end Pointer to variable that will hold the value of the
|
||||||
one-after-end position for the row
|
one-after-end position for the row
|
||||||
master_reclength
|
master_reclength
|
||||||
Pointer to variable that will be set to the length of the
|
Pointer to variable that will be set to the length of the
|
||||||
record on the master side
|
record on the master side
|
||||||
rw_set Pointer to bitmap that holds either the read_set or the
|
rw_set Pointer to bitmap that holds either the read_set or the
|
||||||
write_set of the table
|
write_set of the table
|
||||||
|
|
||||||
DESCRIPTION
|
DESCRIPTION
|
||||||
|
|
||||||
@ -5626,68 +5627,81 @@ int Rows_log_event::do_add_row_data(byte *const row_data,
|
|||||||
static int
|
static int
|
||||||
unpack_row(RELAY_LOG_INFO *rli,
|
unpack_row(RELAY_LOG_INFO *rli,
|
||||||
TABLE *table, uint const colcnt,
|
TABLE *table, uint const colcnt,
|
||||||
char const *row, MY_BITMAP const *cols,
|
char const *const row_data, MY_BITMAP const *cols,
|
||||||
char const **row_end, ulong *master_reclength,
|
char const **const row_end, ulong *const master_reclength,
|
||||||
MY_BITMAP* const rw_set, Log_event_type const event_type)
|
MY_BITMAP* const rw_set, Log_event_type const event_type)
|
||||||
{
|
{
|
||||||
byte *const record= table->record[0];
|
|
||||||
DBUG_ENTER("unpack_row");
|
DBUG_ENTER("unpack_row");
|
||||||
DBUG_ASSERT(record && row);
|
DBUG_ASSERT(row_data);
|
||||||
DBUG_PRINT("enter", ("row: 0x%lx table->record[0]: 0x%lx", (long) row, (long) record));
|
my_size_t const master_null_byte_count= (bitmap_bits_set(cols) + 7) / 8;
|
||||||
my_size_t master_null_bytes= table->s->null_bytes;
|
|
||||||
|
|
||||||
if (colcnt != table->s->fields)
|
|
||||||
{
|
|
||||||
Field **fptr= &table->field[colcnt-1];
|
|
||||||
do
|
|
||||||
master_null_bytes= (*fptr)->last_null_byte();
|
|
||||||
while (master_null_bytes == Field::LAST_NULL_BYTE_UNDEF &&
|
|
||||||
fptr-- > table->field);
|
|
||||||
|
|
||||||
/*
|
|
||||||
If master_null_bytes is LAST_NULL_BYTE_UNDEF (0) at this time,
|
|
||||||
there were no nullable fields nor BIT fields at all in the
|
|
||||||
columns that are common to the master and the slave. In that
|
|
||||||
case, there is only one null byte holding the X bit.
|
|
||||||
|
|
||||||
OBSERVE! There might still be nullable columns following the
|
|
||||||
common columns, so table->s->null_bytes might be greater than 1.
|
|
||||||
*/
|
|
||||||
if (master_null_bytes == Field::LAST_NULL_BYTE_UNDEF)
|
|
||||||
master_null_bytes= 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
DBUG_ASSERT(master_null_bytes <= table->s->null_bytes);
|
|
||||||
memcpy(record, row, master_null_bytes); // [1]
|
|
||||||
int error= 0;
|
int error= 0;
|
||||||
|
|
||||||
bitmap_set_all(rw_set);
|
char const *null_ptr= row_data;
|
||||||
|
char const *pack_ptr= row_data + master_null_byte_count;
|
||||||
|
|
||||||
|
bitmap_clear_all(rw_set);
|
||||||
|
|
||||||
|
empty_record(table);
|
||||||
|
|
||||||
Field **const begin_ptr = table->field;
|
Field **const begin_ptr = table->field;
|
||||||
Field **field_ptr;
|
Field **field_ptr;
|
||||||
char const *ptr= row + master_null_bytes;
|
|
||||||
Field **const end_ptr= begin_ptr + colcnt;
|
Field **const end_ptr= begin_ptr + colcnt;
|
||||||
|
|
||||||
|
DBUG_ASSERT(null_ptr < row_data + master_null_byte_count);
|
||||||
|
|
||||||
|
// Mask to mask out the correct bit among the null bits
|
||||||
|
unsigned int null_mask= 1U;
|
||||||
|
// The "current" null bits
|
||||||
|
unsigned int null_bits= *null_ptr++;
|
||||||
for (field_ptr= begin_ptr ; field_ptr < end_ptr ; ++field_ptr)
|
for (field_ptr= begin_ptr ; field_ptr < end_ptr ; ++field_ptr)
|
||||||
{
|
{
|
||||||
Field *const f= *field_ptr;
|
Field *const f= *field_ptr;
|
||||||
|
|
||||||
|
/*
|
||||||
|
No need to bother about columns that does not exist: they have
|
||||||
|
gotten default values when being emptied above.
|
||||||
|
*/
|
||||||
if (bitmap_is_set(cols, field_ptr - begin_ptr))
|
if (bitmap_is_set(cols, field_ptr - begin_ptr))
|
||||||
{
|
{
|
||||||
DBUG_ASSERT((const char *)table->record[0] <= f->ptr);
|
if ((null_mask & 0xFF) == 0)
|
||||||
DBUG_ASSERT(f->ptr < (char*)(table->record[0] + table->s->reclength +
|
{
|
||||||
(f->pack_length_in_rec() == 0)));
|
DBUG_ASSERT(null_ptr < row_data + master_null_byte_count);
|
||||||
|
null_mask= 1U;
|
||||||
|
null_bits= *null_ptr++;
|
||||||
|
}
|
||||||
|
|
||||||
|
DBUG_ASSERT(null_mask & 0xFF); // One of the 8 LSB should be set
|
||||||
|
|
||||||
DBUG_PRINT("info", ("unpacking column '%s' to 0x%lx", f->field_name,
|
|
||||||
(long) f->ptr));
|
|
||||||
ptr= f->unpack(f->ptr, ptr);
|
|
||||||
/* Field...::unpack() cannot return 0 */
|
/* Field...::unpack() cannot return 0 */
|
||||||
DBUG_ASSERT(ptr != NULL);
|
DBUG_ASSERT(pack_ptr != NULL);
|
||||||
|
|
||||||
|
if ((null_bits & null_mask) && f->maybe_null())
|
||||||
|
f->set_null();
|
||||||
|
else
|
||||||
|
{
|
||||||
|
f->set_notnull();
|
||||||
|
|
||||||
|
/*
|
||||||
|
We only unpack the field if it was non-null
|
||||||
|
*/
|
||||||
|
const char *const old_ptr= pack_ptr;
|
||||||
|
pack_ptr= f->unpack(f->ptr, pack_ptr);
|
||||||
|
DBUG_PRINT("debug", ("Unpacking field '%s' from %d bytes",
|
||||||
|
f->field_name, pack_ptr - old_ptr));
|
||||||
|
}
|
||||||
|
|
||||||
|
bitmap_set_bit(rw_set, f->field_index);
|
||||||
|
null_mask <<= 1;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
bitmap_clear_bit(rw_set, field_ptr - begin_ptr);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
*row_end = ptr;
|
/*
|
||||||
|
We should now have read all the null bytes, otherwise something is
|
||||||
|
really wrong.
|
||||||
|
*/
|
||||||
|
DBUG_ASSERT(null_ptr == row_data + master_null_byte_count);
|
||||||
|
|
||||||
|
*row_end = pack_ptr;
|
||||||
if (master_reclength)
|
if (master_reclength)
|
||||||
{
|
{
|
||||||
if (*field_ptr)
|
if (*field_ptr)
|
||||||
@ -5712,9 +5726,8 @@ unpack_row(RELAY_LOG_INFO *rli,
|
|||||||
uint32 const mask= NOT_NULL_FLAG | NO_DEFAULT_VALUE_FLAG;
|
uint32 const mask= NOT_NULL_FLAG | NO_DEFAULT_VALUE_FLAG;
|
||||||
Field *const f= *field_ptr;
|
Field *const f= *field_ptr;
|
||||||
|
|
||||||
DBUG_PRINT("info", ("processing column '%s' @ 0x%lx", f->field_name,
|
if (event_type == WRITE_ROWS_EVENT &&
|
||||||
(long) f->ptr));
|
((*field_ptr)->flags & mask) == mask)
|
||||||
if (event_type == WRITE_ROWS_EVENT && (f->flags & mask) == mask)
|
|
||||||
{
|
{
|
||||||
slave_print_msg(ERROR_LEVEL, rli, ER_NO_DEFAULT_FOR_FIELD,
|
slave_print_msg(ERROR_LEVEL, rli, ER_NO_DEFAULT_FOR_FIELD,
|
||||||
"Field `%s` of table `%s`.`%s` "
|
"Field `%s` of table `%s`.`%s` "
|
||||||
@ -6778,6 +6791,15 @@ copy_extra_record_fields(TABLE *table,
|
|||||||
return 0; // All OK
|
return 0; // All OK
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define DBUG_PRINT_BITSET(N,FRM,BS) \
|
||||||
|
do { \
|
||||||
|
char buf[256]; \
|
||||||
|
for (uint i = 0 ; i < (BS)->n_bits ; ++i) \
|
||||||
|
buf[i] = bitmap_is_set((BS), i) ? '1' : '0'; \
|
||||||
|
buf[(BS)->n_bits] = '\0'; \
|
||||||
|
DBUG_PRINT((N), ((FRM), buf)); \
|
||||||
|
} while (0)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Replace the provided record in the database.
|
Replace the provided record in the database.
|
||||||
|
|
||||||
@ -6810,6 +6832,12 @@ replace_record(THD *thd, TABLE *table,
|
|||||||
int keynum;
|
int keynum;
|
||||||
auto_afree_ptr<char> key(NULL);
|
auto_afree_ptr<char> key(NULL);
|
||||||
|
|
||||||
|
#ifndef DBUG_OFF
|
||||||
|
DBUG_DUMP("record[0]", table->record[0], table->s->reclength);
|
||||||
|
DBUG_PRINT_BITSET("debug", "write_set = %s", table->write_set);
|
||||||
|
DBUG_PRINT_BITSET("debug", "read_set = %s", table->read_set);
|
||||||
|
#endif
|
||||||
|
|
||||||
while ((error= table->file->ha_write_row(table->record[0])))
|
while ((error= table->file->ha_write_row(table->record[0])))
|
||||||
{
|
{
|
||||||
if (error == HA_ERR_LOCK_DEADLOCK || error == HA_ERR_LOCK_WAIT_TIMEOUT)
|
if (error == HA_ERR_LOCK_DEADLOCK || error == HA_ERR_LOCK_WAIT_TIMEOUT)
|
||||||
@ -6931,20 +6959,75 @@ void Write_rows_log_event::print(FILE *file, PRINT_EVENT_INFO* print_event_info)
|
|||||||
*/
|
*/
|
||||||
static bool record_compare(TABLE *table)
|
static bool record_compare(TABLE *table)
|
||||||
{
|
{
|
||||||
|
/*
|
||||||
|
Need to set the X bit and the filler bits in both records since
|
||||||
|
there are engines that do not set it correctly.
|
||||||
|
|
||||||
|
In addition, since MyISAM checks that one hasn't tampered with the
|
||||||
|
record, it is necessary to restore the old bytes into the record
|
||||||
|
after doing the comparison.
|
||||||
|
|
||||||
|
TODO[record format ndb]: Remove it once NDB returns correct
|
||||||
|
records. Check that the other engines also return correct records.
|
||||||
|
*/
|
||||||
|
|
||||||
|
bool result= FALSE;
|
||||||
|
byte saved_x[2], saved_filler[2];
|
||||||
|
|
||||||
|
if (table->s->null_bytes > 0)
|
||||||
|
{
|
||||||
|
for (int i = 0 ; i < 2 ; ++i)
|
||||||
|
{
|
||||||
|
saved_x[i]= table->record[i][0];
|
||||||
|
saved_filler[i]= table->record[i][table->s->null_bytes - 1];
|
||||||
|
table->record[i][0]|= 1U;
|
||||||
|
table->record[i][table->s->null_bytes - 1]|=
|
||||||
|
256U - (1U << table->s->last_null_bit_pos);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (table->s->blob_fields + table->s->varchar_fields == 0)
|
if (table->s->blob_fields + table->s->varchar_fields == 0)
|
||||||
return cmp_record(table,record[1]);
|
{
|
||||||
|
result= cmp_record(table,record[1]);
|
||||||
|
goto record_compare_exit;
|
||||||
|
}
|
||||||
|
|
||||||
/* Compare null bits */
|
/* Compare null bits */
|
||||||
if (memcmp(table->null_flags,
|
if (memcmp(table->null_flags,
|
||||||
table->null_flags+table->s->rec_buff_length,
|
table->null_flags+table->s->rec_buff_length,
|
||||||
table->s->null_bytes))
|
table->s->null_bytes))
|
||||||
return TRUE; // Diff in NULL value
|
{
|
||||||
|
result= TRUE; // Diff in NULL value
|
||||||
|
goto record_compare_exit;
|
||||||
|
}
|
||||||
|
|
||||||
/* Compare updated fields */
|
/* Compare updated fields */
|
||||||
for (Field **ptr=table->field ; *ptr ; ptr++)
|
for (Field **ptr=table->field ; *ptr ; ptr++)
|
||||||
{
|
{
|
||||||
if ((*ptr)->cmp_binary_offset(table->s->rec_buff_length))
|
if ((*ptr)->cmp_binary_offset(table->s->rec_buff_length))
|
||||||
return TRUE;
|
{
|
||||||
|
result= TRUE;
|
||||||
|
goto record_compare_exit;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return FALSE;
|
|
||||||
|
record_compare_exit:
|
||||||
|
/*
|
||||||
|
Restore the saved bytes.
|
||||||
|
|
||||||
|
TODO[record format ndb]: Remove this code once NDB returns the
|
||||||
|
correct record format.
|
||||||
|
*/
|
||||||
|
if (table->s->null_bytes > 0)
|
||||||
|
{
|
||||||
|
for (int i = 0 ; i < 2 ; ++i)
|
||||||
|
{
|
||||||
|
table->record[i][0]= saved_x[i];
|
||||||
|
table->record[i][table->s->null_bytes - 1]= saved_filler[i];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -6980,6 +7063,8 @@ static int find_and_fetch_row(TABLE *table, byte *key)
|
|||||||
|
|
||||||
DBUG_ASSERT(table->in_use != NULL);
|
DBUG_ASSERT(table->in_use != NULL);
|
||||||
|
|
||||||
|
DBUG_DUMP("record[0]", table->record[0], table->s->reclength);
|
||||||
|
|
||||||
if ((table->file->ha_table_flags() & HA_PRIMARY_KEY_REQUIRED_FOR_POSITION) &&
|
if ((table->file->ha_table_flags() & HA_PRIMARY_KEY_REQUIRED_FOR_POSITION) &&
|
||||||
table->s->primary_key < MAX_KEY)
|
table->s->primary_key < MAX_KEY)
|
||||||
{
|
{
|
||||||
@ -7080,15 +7165,22 @@ static int find_and_fetch_row(TABLE *table, byte *key)
|
|||||||
while (record_compare(table))
|
while (record_compare(table))
|
||||||
{
|
{
|
||||||
int error;
|
int error;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
We need to set the null bytes to ensure that the filler bit
|
We need to set the null bytes to ensure that the filler bit
|
||||||
are all set when returning. There are storage engines that
|
are all set when returning. There are storage engines that
|
||||||
just set the necessary bits on the bytes and don't set the
|
just set the necessary bits on the bytes and don't set the
|
||||||
filler bits correctly.
|
filler bits correctly.
|
||||||
|
|
||||||
|
TODO[record format ndb]: Remove this code once NDB returns the
|
||||||
|
correct record format.
|
||||||
*/
|
*/
|
||||||
my_ptrdiff_t const pos=
|
if (table->s->null_bytes > 0)
|
||||||
table->s->null_bytes > 0 ? table->s->null_bytes - 1 : 0;
|
{
|
||||||
table->record[1][pos]= 0xFF;
|
table->record[1][table->s->null_bytes - 1]|=
|
||||||
|
256U - (1U << table->s->last_null_bit_pos);
|
||||||
|
}
|
||||||
|
|
||||||
if ((error= table->file->index_next(table->record[1])))
|
if ((error= table->file->index_next(table->record[1])))
|
||||||
{
|
{
|
||||||
table->file->print_error(error, MYF(0));
|
table->file->print_error(error, MYF(0));
|
||||||
@ -7114,17 +7206,11 @@ static int find_and_fetch_row(TABLE *table, byte *key)
|
|||||||
/* Continue until we find the right record or have made a full loop */
|
/* Continue until we find the right record or have made a full loop */
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
/*
|
|
||||||
We need to set the null bytes to ensure that the filler bit
|
|
||||||
are all set when returning. There are storage engines that
|
|
||||||
just set the necessary bits on the bytes and don't set the
|
|
||||||
filler bits correctly.
|
|
||||||
*/
|
|
||||||
my_ptrdiff_t const pos=
|
|
||||||
table->s->null_bytes > 0 ? table->s->null_bytes - 1 : 0;
|
|
||||||
table->record[1][pos]= 0xFF;
|
|
||||||
error= table->file->rnd_next(table->record[1]);
|
error= table->file->rnd_next(table->record[1]);
|
||||||
|
|
||||||
|
DBUG_DUMP("record[0]", table->record[0], table->s->reclength);
|
||||||
|
DBUG_DUMP("record[1]", table->record[1], table->s->reclength);
|
||||||
|
|
||||||
switch (error)
|
switch (error)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
@ -7138,6 +7224,7 @@ static int find_and_fetch_row(TABLE *table, byte *key)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
table->file->print_error(error, MYF(0));
|
table->file->print_error(error, MYF(0));
|
||||||
|
DBUG_PRINT("info", ("Record not found"));
|
||||||
table->file->ha_rnd_end();
|
table->file->ha_rnd_end();
|
||||||
DBUG_RETURN(error);
|
DBUG_RETURN(error);
|
||||||
}
|
}
|
||||||
@ -7147,6 +7234,7 @@ static int find_and_fetch_row(TABLE *table, byte *key)
|
|||||||
/*
|
/*
|
||||||
Have to restart the scan to be able to fetch the next row.
|
Have to restart the scan to be able to fetch the next row.
|
||||||
*/
|
*/
|
||||||
|
DBUG_PRINT("info", ("Record %sfound", restart_count == 2 ? "not " : ""));
|
||||||
table->file->ha_rnd_end();
|
table->file->ha_rnd_end();
|
||||||
|
|
||||||
DBUG_ASSERT(error == HA_ERR_END_OF_FILE || error == 0);
|
DBUG_ASSERT(error == HA_ERR_END_OF_FILE || error == 0);
|
||||||
|
@ -468,10 +468,23 @@ enum Log_event_type
|
|||||||
XID_EVENT= 16,
|
XID_EVENT= 16,
|
||||||
BEGIN_LOAD_QUERY_EVENT= 17,
|
BEGIN_LOAD_QUERY_EVENT= 17,
|
||||||
EXECUTE_LOAD_QUERY_EVENT= 18,
|
EXECUTE_LOAD_QUERY_EVENT= 18,
|
||||||
|
|
||||||
TABLE_MAP_EVENT = 19,
|
TABLE_MAP_EVENT = 19,
|
||||||
WRITE_ROWS_EVENT = 20,
|
|
||||||
UPDATE_ROWS_EVENT = 21,
|
/*
|
||||||
DELETE_ROWS_EVENT = 22,
|
These event numbers were used for 5.1.0 to 5.1.15 and are
|
||||||
|
therefore obsolete.
|
||||||
|
*/
|
||||||
|
PRE_GA_WRITE_ROWS_EVENT = 20,
|
||||||
|
PRE_GA_UPDATE_ROWS_EVENT = 21,
|
||||||
|
PRE_GA_DELETE_ROWS_EVENT = 22,
|
||||||
|
|
||||||
|
/*
|
||||||
|
These event numbers are used from 5.1.16 and forward
|
||||||
|
*/
|
||||||
|
WRITE_ROWS_EVENT = 23,
|
||||||
|
UPDATE_ROWS_EVENT = 24,
|
||||||
|
DELETE_ROWS_EVENT = 25,
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Add new events here - right above this comment!
|
Add new events here - right above this comment!
|
||||||
|
113
sql/sql_class.cc
113
sql/sql_class.cc
@ -2544,30 +2544,113 @@ my_size_t THD::max_row_length_blob(TABLE *table, const byte *data) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
my_size_t THD::pack_row(TABLE *table, MY_BITMAP const* cols, byte *row_data,
|
/*
|
||||||
const byte *record) const
|
Pack a record of data for a table into a format suitable for
|
||||||
|
transfer via the binary log.
|
||||||
|
|
||||||
|
SYNOPSIS
|
||||||
|
THD::pack_row()
|
||||||
|
table Table describing the format of the record
|
||||||
|
cols Bitmap with a set bit for each column that should be
|
||||||
|
stored in the row
|
||||||
|
row_data Pointer to memory where row will be written
|
||||||
|
record Pointer to record that should be packed. It is assumed
|
||||||
|
that the pointer refers to either record[0] or
|
||||||
|
record[1], but no such check is made since the code does
|
||||||
|
not rely on that.
|
||||||
|
|
||||||
|
DESCRIPTION
|
||||||
|
|
||||||
|
The format for a row in transfer with N fields is the following:
|
||||||
|
|
||||||
|
ceil(N/8) null bytes:
|
||||||
|
One null bit for every column *regardless of whether it can be
|
||||||
|
null or not*. This simplifies the decoding. Observe that the
|
||||||
|
number of null bits is equal to the number of set bits in the
|
||||||
|
'cols' bitmap. The number of null bytes is the smallest number
|
||||||
|
of bytes necessary to store the null bits.
|
||||||
|
|
||||||
|
Padding bits are 1.
|
||||||
|
|
||||||
|
N packets:
|
||||||
|
Each field is stored in packed format.
|
||||||
|
|
||||||
|
|
||||||
|
RETURN VALUE
|
||||||
|
|
||||||
|
The number of bytes written at 'row_data'.
|
||||||
|
*/
|
||||||
|
my_size_t
|
||||||
|
THD::pack_row(TABLE *table, MY_BITMAP const* cols,
|
||||||
|
byte *const row_data, const byte *record) const
|
||||||
{
|
{
|
||||||
Field **p_field= table->field, *field;
|
Field **p_field= table->field, *field;
|
||||||
int n_null_bytes= table->s->null_bytes;
|
int const null_byte_count= (bitmap_bits_set(cols) + 7) / 8;
|
||||||
byte *ptr;
|
byte *pack_ptr = row_data + null_byte_count;
|
||||||
uint i;
|
byte *null_ptr = row_data;
|
||||||
my_ptrdiff_t const rec_offset= record - table->record[0];
|
my_ptrdiff_t const rec_offset= record - table->record[0];
|
||||||
my_ptrdiff_t const def_offset= table->s->default_values - table->record[0];
|
my_ptrdiff_t const def_offset= table->s->default_values - table->record[0];
|
||||||
memcpy(row_data, record, n_null_bytes);
|
|
||||||
ptr= row_data+n_null_bytes;
|
|
||||||
|
|
||||||
for (i= 0 ; (field= *p_field) ; i++, p_field++)
|
/*
|
||||||
|
We write the null bits and the packed records using one pass
|
||||||
|
through all the fields. The null bytes are written little-endian,
|
||||||
|
i.e., the first fields are in the first byte.
|
||||||
|
*/
|
||||||
|
unsigned int null_bits= (1U << 8) - 1;
|
||||||
|
// Mask to mask out the correct but among the null bits
|
||||||
|
unsigned int null_mask= 1U;
|
||||||
|
for ( ; (field= *p_field) ; p_field++)
|
||||||
{
|
{
|
||||||
if (bitmap_is_set(cols,i))
|
DBUG_PRINT("debug", ("null_mask=%d; null_ptr=%p; row_data=%p; null_byte_count=%d",
|
||||||
|
null_mask, null_ptr, row_data, null_byte_count));
|
||||||
|
if (bitmap_is_set(cols, p_field - table->field))
|
||||||
{
|
{
|
||||||
my_ptrdiff_t const offset=
|
my_ptrdiff_t offset;
|
||||||
field->is_null((uint) rec_offset) ? def_offset : rec_offset;
|
if (field->is_null(rec_offset))
|
||||||
field->move_field_offset(offset);
|
{
|
||||||
ptr= (byte*)field->pack((char *) ptr, field->ptr);
|
offset= def_offset;
|
||||||
field->move_field_offset(-offset);
|
null_bits |= null_mask;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
offset= rec_offset;
|
||||||
|
null_bits &= ~null_mask;
|
||||||
|
|
||||||
|
/*
|
||||||
|
We only store the data of the field if it is non-null
|
||||||
|
*/
|
||||||
|
field->move_field_offset(offset);
|
||||||
|
pack_ptr= (byte*)field->pack((char *) pack_ptr, field->ptr);
|
||||||
|
field->move_field_offset(-offset);
|
||||||
|
}
|
||||||
|
|
||||||
|
null_mask <<= 1;
|
||||||
|
if ((null_mask & 0xFF) == 0)
|
||||||
|
{
|
||||||
|
DBUG_ASSERT(null_ptr < row_data + null_byte_count);
|
||||||
|
null_mask = 1U;
|
||||||
|
*null_ptr++ = null_bits;
|
||||||
|
null_bits= (1U << 8) - 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return (static_cast<my_size_t>(ptr - row_data));
|
|
||||||
|
/*
|
||||||
|
Write the last (partial) byte, if there is one
|
||||||
|
*/
|
||||||
|
if ((null_mask & 0xFF) > 1)
|
||||||
|
{
|
||||||
|
DBUG_ASSERT(null_ptr < row_data + null_byte_count);
|
||||||
|
*null_ptr++ = null_bits;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
The null pointer should now point to the first byte of the
|
||||||
|
packed data. If it doesn't, something is very wrong.
|
||||||
|
*/
|
||||||
|
DBUG_ASSERT(null_ptr == row_data + null_byte_count);
|
||||||
|
|
||||||
|
return static_cast<my_size_t>(pack_ptr - row_data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user