2006-03-08 06:55:21 +01:00
|
|
|
stop slave;
|
|
|
|
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 (a INT, b LONG);
|
|
|
|
INSERT INTO t1 VALUES (1,1), (2,2);
|
|
|
|
INSERT INTO t1 VALUES (3,UUID()), (4,UUID());
|
|
|
|
SHOW BINLOG EVENTS;
|
|
|
|
Log_name Pos Event_type Server_id End_log_pos Info
|
2006-03-14 14:21:28 +01:00
|
|
|
master-bin.000001 # Format_desc 1 # Server ver: VERSION, Binlog ver: 4
|
|
|
|
master-bin.000001 # Query 1 # use `test`; CREATE TABLE t1 (a INT, b LONG)
|
2009-11-03 20:02:56 +01:00
|
|
|
master-bin.000001 # Query 1 # BEGIN
|
2006-03-14 14:21:28 +01:00
|
|
|
master-bin.000001 # Query 1 # use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
2009-11-03 20:02:56 +01:00
|
|
|
master-bin.000001 # Query 1 # COMMIT
|
2009-05-31 07:44:41 +02:00
|
|
|
master-bin.000001 # Query 1 # BEGIN
|
2006-03-14 14:21:28 +01:00
|
|
|
master-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
|
|
|
master-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
2009-05-31 07:44:41 +02:00
|
|
|
master-bin.000001 # Query 1 # COMMIT
|
2006-03-08 06:55:21 +01:00
|
|
|
**** On Slave ****
|
|
|
|
SHOW SLAVE STATUS;
|
|
|
|
Slave_IO_State #
|
|
|
|
Master_Host 127.0.0.1
|
|
|
|
Master_User root
|
|
|
|
Master_Port MASTER_PORT
|
|
|
|
Connect_Retry 1
|
|
|
|
Master_Log_File master-bin.000001
|
2009-11-03 20:02:56 +01:00
|
|
|
Read_Master_Log_Pos #
|
2006-03-08 06:55:21 +01:00
|
|
|
Relay_Log_File #
|
|
|
|
Relay_Log_Pos #
|
|
|
|
Relay_Master_Log_File master-bin.000001
|
|
|
|
Slave_IO_Running Yes
|
|
|
|
Slave_SQL_Running Yes
|
|
|
|
Replicate_Do_DB
|
|
|
|
Replicate_Ignore_DB
|
|
|
|
Replicate_Do_Table
|
|
|
|
Replicate_Ignore_Table
|
|
|
|
Replicate_Wild_Do_Table
|
|
|
|
Replicate_Wild_Ignore_Table
|
|
|
|
Last_Errno 0
|
|
|
|
Last_Error
|
|
|
|
Skip_Counter 0
|
2009-11-03 20:02:56 +01:00
|
|
|
Exec_Master_Log_Pos #
|
2006-03-08 06:55:21 +01:00
|
|
|
Relay_Log_Space #
|
|
|
|
Until_Condition None
|
|
|
|
Until_Log_File
|
|
|
|
Until_Log_Pos 0
|
|
|
|
Master_SSL_Allowed No
|
|
|
|
Master_SSL_CA_File
|
|
|
|
Master_SSL_CA_Path
|
|
|
|
Master_SSL_Cert
|
|
|
|
Master_SSL_Cipher
|
|
|
|
Master_SSL_Key
|
|
|
|
Seconds_Behind_Master #
|
2007-06-11 22:15:39 +02:00
|
|
|
Master_SSL_Verify_Server_Cert #
|
2007-06-09 07:19:37 +02:00
|
|
|
Last_IO_Errno #
|
2007-06-11 22:15:39 +02:00
|
|
|
Last_IO_Error
|
2007-06-09 07:19:37 +02:00
|
|
|
Last_SQL_Errno 0
|
|
|
|
Last_SQL_Error
|
2009-10-01 18:44:53 +02:00
|
|
|
Replicate_Ignore_Server_Ids
|
|
|
|
Master_Server_Id 1
|
2006-03-08 06:55:21 +01:00
|
|
|
SHOW BINLOG EVENTS;
|
|
|
|
Log_name Pos Event_type Server_id End_log_pos Info
|
2006-03-14 14:21:28 +01:00
|
|
|
slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
|
|
|
|
slave-bin.000001 # Query 1 # use `test`; CREATE TABLE t1 (a INT, b LONG)
|
2009-11-03 20:02:56 +01:00
|
|
|
slave-bin.000001 # Query 1 # BEGIN
|
2006-03-14 14:21:28 +01:00
|
|
|
slave-bin.000001 # Query 1 # use `test`; INSERT INTO t1 VALUES (1,1), (2,2)
|
2009-11-03 20:02:56 +01:00
|
|
|
slave-bin.000001 # Query 1 # COMMIT
|
2009-05-31 07:44:41 +02:00
|
|
|
slave-bin.000001 # Query 1 # BEGIN
|
2006-03-14 14:21:28 +01:00
|
|
|
slave-bin.000001 # Table_map 1 # table_id: # (test.t1)
|
|
|
|
slave-bin.000001 # Write_rows 1 # table_id: # flags: STMT_END_F
|
2009-05-31 07:44:41 +02:00
|
|
|
slave-bin.000001 # Query 1 # COMMIT
|
2006-03-08 06:55:21 +01:00
|
|
|
DROP TABLE IF EXISTS t1;
|