Commit f875890a authored by unknown's avatar unknown

Merge mail.hezx.com:/media/sda3/work/mysql/bkwork/versional/mysql-5.1-new-rpl

into  mail.hezx.com:/media/sda3/work/mysql/bkwork/versional/merge-51


mysql-test/suite/rpl/r/rpl_create_database.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_load_from_master.result:
  Auto merged
mysql-test/suite/rpl/t/rpl_create_database.test:
  Auto merged
mysql-test/suite/rpl/t/rpl_load_from_master.test:
  Auto merged
mysql-test/suite/rpl/r/rpl_init_slave.result:
  SCCS merged
mysql-test/suite/rpl/t/rpl_init_slave.test:
  SCCS merged
parents 5744be40 556f2e4e
...@@ -43,7 +43,7 @@ set global max_relay_log_size=8192-1; # mapped to 4096 ...@@ -43,7 +43,7 @@ set global max_relay_log_size=8192-1; # mapped to 4096
select @@global.max_relay_log_size; select @@global.max_relay_log_size;
start slave; start slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--echo # --echo #
--echo # Test 2 --echo # Test 2
...@@ -55,7 +55,7 @@ set global max_relay_log_size=(5*4096); ...@@ -55,7 +55,7 @@ set global max_relay_log_size=(5*4096);
query_vertical select @@global.max_relay_log_size; query_vertical select @@global.max_relay_log_size;
start slave; start slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--echo # --echo #
--echo # Test 3: max_relay_log_size = 0 --echo # Test 3: max_relay_log_size = 0
...@@ -67,7 +67,7 @@ set global max_relay_log_size=0; ...@@ -67,7 +67,7 @@ set global max_relay_log_size=0;
query_vertical select @@global.max_relay_log_size; query_vertical select @@global.max_relay_log_size;
start slave; start slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--echo # --echo #
--echo # Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions --echo # Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions
...@@ -78,7 +78,7 @@ reset slave; ...@@ -78,7 +78,7 @@ reset slave;
# test of relay log rotation when the slave is stopped # test of relay log rotation when the slave is stopped
# (to make sure it does not crash). # (to make sure it does not crash).
flush logs; flush logs;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--echo # --echo #
--echo # Test 5 --echo # Test 5
...@@ -96,7 +96,7 @@ create table t1 (a int); ...@@ -96,7 +96,7 @@ create table t1 (a int);
save_master_pos; save_master_pos;
connection slave; connection slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--echo # --echo #
--echo # Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated --echo # Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated
...@@ -108,13 +108,12 @@ drop table t1; ...@@ -108,13 +108,12 @@ drop table t1;
save_master_pos; save_master_pos;
connection slave; connection slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
connection master; connection master;
# test that the absence of relay logs does not make a master crash # test that the absence of relay logs does not make a master crash
flush logs; flush logs;
-- replace_column 3 <Binlog_Ignore_DB> source include/show_master_status.inc;
query_vertical show master status;
# Restore max_binlog_size # Restore max_binlog_size
connection slave; connection slave;
......
...@@ -13,18 +13,18 @@ connection master; ...@@ -13,18 +13,18 @@ connection master;
save_master_pos; save_master_pos;
connection slave; connection slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
stop slave; stop slave;
change master to master_user='test'; change master to master_user='test';
source include/show_slave_status.inc; source include/show_slave_status2.inc;
reset slave; reset slave;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
start slave; start slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
# test of crash with temp tables & RESET SLAVE # test of crash with temp tables & RESET SLAVE
# (test to see if RESET SLAVE clears temp tables in memory and disk) # (test to see if RESET SLAVE clears temp tables in memory and disk)
......
...@@ -122,7 +122,7 @@ INSERT INTO t1_nodef VALUES (1,2); ...@@ -122,7 +122,7 @@ INSERT INTO t1_nodef VALUES (1,2);
connection slave; connection slave;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
START SLAVE; START SLAVE;
...@@ -142,7 +142,7 @@ sync_slave_with_master; ...@@ -142,7 +142,7 @@ sync_slave_with_master;
--echo **** On Slave **** --echo **** On Slave ****
SELECT * FROM t2; SELECT * FROM t2;
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
connection master; connection master;
...@@ -154,7 +154,7 @@ INSERT INTO t4 VALUES (4); ...@@ -154,7 +154,7 @@ INSERT INTO t4 VALUES (4);
connection slave; connection slave;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
START SLAVE; START SLAVE;
...@@ -168,7 +168,7 @@ INSERT INTO t5 VALUES (5,10,25); ...@@ -168,7 +168,7 @@ INSERT INTO t5 VALUES (5,10,25);
connection slave; connection slave;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
START SLAVE; START SLAVE;
...@@ -182,7 +182,7 @@ INSERT INTO t6 VALUES (6,12,36); ...@@ -182,7 +182,7 @@ INSERT INTO t6 VALUES (6,12,36);
connection slave; connection slave;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
START SLAVE; START SLAVE;
...@@ -191,7 +191,7 @@ connection master; ...@@ -191,7 +191,7 @@ connection master;
INSERT INTO t9 VALUES (6); INSERT INTO t9 VALUES (6);
sync_slave_with_master; sync_slave_with_master;
--replace_result $SLAVE_MYPORT SLAVE_PORT --replace_result $SLAVE_MYPORT SLAVE_PORT
--replace_column 1 # 4 # 7 # 8 # 9 # 22 # 23 # 33 # --replace_column 1 # 4 # 7 # 8 # 9 # 20 # 22 # 23 # 33 # 40 #
--query_vertical SHOW SLAVE STATUS --query_vertical SHOW SLAVE STATUS
# Testing some tables extra field that can be null and cannot be null # Testing some tables extra field that can be null and cannot be null
......
# show binary logs
# mask out the binlog position
-- replace_column 2 #
show binary logs;
# show master logs
# mask out the binlog position
-- replace_column 2 #
query_vertical show master logs;
# show master status
# mask out the binlog position
-- replace_column 2 # 3 <Binlog_Do_DB> 4 <Binlog_Ignore_DB>
show master status;
# Include file to show the slave status, masking out some information
# that varies depending on where the test is executed.
# masked out log positions
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
query_vertical SHOW SLAVE STATUS;
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 106 master-bin.000001 # <Binlog_Do_DB> <Binlog_Ignore_DB>
reset slave; reset slave;
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
change master to master_host='127.0.0.1'; change master to master_host='127.0.0.1';
...@@ -12,7 +12,7 @@ Master_User test ...@@ -12,7 +12,7 @@ Master_User test
Master_Port 3306 Master_Port 3306
Connect_Retry 7 Connect_Retry 7
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -27,7 +27,7 @@ Replicate_Wild_Ignore_Table ...@@ -27,7 +27,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -53,7 +53,7 @@ Master_User root ...@@ -53,7 +53,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 7 Connect_Retry 7
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -68,7 +68,7 @@ Replicate_Wild_Ignore_Table ...@@ -68,7 +68,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -93,7 +93,7 @@ Master_User root ...@@ -93,7 +93,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 7 Connect_Retry 7
Master_Log_File master-bin.000001 Master_Log_File master-bin.000001
Read_Master_Log_Pos 106 Read_Master_Log_Pos #
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
...@@ -108,7 +108,7 @@ Replicate_Wild_Ignore_Table ...@@ -108,7 +108,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 106 Exec_Master_Log_Pos #
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 ...@@ -33,7 +33,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 191 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -73,7 +73,7 @@ Replicate_Wild_Ignore_Table ...@@ -73,7 +73,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 191 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
......
...@@ -7,40 +7,40 @@ start slave; ...@@ -7,40 +7,40 @@ start slave;
**** On Master **** **** On Master ****
CREATE USER dummy@localhost; CREATE USER dummy@localhost;
CREATE USER dummy1@localhost, dummy2@localhost; CREATE USER dummy1@localhost, dummy2@localhost;
SELECT user, host FROM mysql.user WHERE user != 'root'; SELECT user, host FROM mysql.user WHERE user like 'dummy%';
user host user host
dummy localhost dummy localhost
dummy1 localhost dummy1 localhost
dummy2 localhost dummy2 localhost
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
COUNT(*) COUNT(*)
6 3
**** On Slave **** **** On Slave ****
SELECT user,host FROM mysql.user WHERE user != 'root'; SELECT user,host FROM mysql.user WHERE user like 'dummy%';
user host user host
dummy localhost dummy localhost
dummy1 localhost dummy1 localhost
dummy2 localhost dummy2 localhost
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
COUNT(*) COUNT(*)
6 3
**** On Master **** **** On Master ****
DROP USER nonexisting@localhost; DROP USER nonexisting@localhost;
ERROR HY000: Operation DROP USER failed for 'nonexisting'@'localhost' ERROR HY000: Operation DROP USER failed for 'nonexisting'@'localhost'
DROP USER nonexisting@localhost, dummy@localhost; DROP USER nonexisting@localhost, dummy@localhost;
ERROR HY000: Operation DROP USER failed for 'nonexisting'@'localhost' ERROR HY000: Operation DROP USER failed for 'nonexisting'@'localhost'
DROP USER dummy1@localhost, dummy2@localhost; DROP USER dummy1@localhost, dummy2@localhost;
SELECT user, host FROM mysql.user WHERE user != 'root'; SELECT user, host FROM mysql.user WHERE user like 'dummy%';
user host user host
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
COUNT(*) COUNT(*)
3 0
**** On Slave **** **** On Slave ****
SELECT user,host FROM mysql.user WHERE user != 'root'; SELECT user,host FROM mysql.user WHERE user like 'dummy%';
user host user host
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
COUNT(*) COUNT(*)
3 0
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
Slave_IO_State # Slave_IO_State #
Master_Host 127.0.0.1 Master_Host 127.0.0.1
...@@ -48,7 +48,7 @@ Master_User root ...@@ -48,7 +48,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 617 Read_Master_Log_Pos #
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
...@@ -57,13 +57,13 @@ Slave_SQL_Running Yes ...@@ -57,13 +57,13 @@ Slave_SQL_Running Yes
Replicate_Do_DB Replicate_Do_DB
Replicate_Ignore_DB Replicate_Ignore_DB
Replicate_Do_Table Replicate_Do_Table
Replicate_Ignore_Table Replicate_Ignore_Table #
Replicate_Wild_Do_Table Replicate_Wild_Do_Table
Replicate_Wild_Ignore_Table Replicate_Wild_Ignore_Table
Last_Errno 0 Last_Errno 0
Last_Error Last_Error
Skip_Counter 0 Skip_Counter 0
Exec_Master_Log_Pos 617 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -76,7 +76,7 @@ Master_SSL_Cipher ...@@ -76,7 +76,7 @@ Master_SSL_Cipher
Master_SSL_Key Master_SSL_Key
Seconds_Behind_Master # Seconds_Behind_Master #
Master_SSL_Verify_Server_Cert No Master_SSL_Verify_Server_Cert No
Last_IO_Errno 0 Last_IO_Errno #
Last_IO_Error Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
...@@ -4,6 +4,7 @@ reset master; ...@@ -4,6 +4,7 @@ reset master;
reset slave; reset slave;
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;
start slave; start slave;
set global max_connections=151;
stop slave; stop slave;
start slave; start slave;
show variables like 'init_slave'; show variables like 'init_slave';
......
...@@ -6,7 +6,7 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; ...@@ -6,7 +6,7 @@ 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 106 <Binlog_Ignore_DB> master-bin.000001 # <Binlog_Do_DB> <Binlog_Ignore_DB>
stop slave; stop slave;
change master to master_log_pos=75; change master to master_log_pos=75;
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
...@@ -16,7 +16,7 @@ Master_User root ...@@ -16,7 +16,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 75 Read_Master_Log_Pos #
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
...@@ -31,7 +31,7 @@ Replicate_Wild_Ignore_Table ...@@ -31,7 +31,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 75 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -91,12 +91,12 @@ Last_SQL_Errno 0 ...@@ -91,12 +91,12 @@ Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
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 106 <Binlog_Ignore_DB> master-bin.000001 # <Binlog_Do_DB> <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);
change master to master_log_pos=106; change master to master_log_pos=4;
start slave; start slave;
select * from t1 ORDER BY n; select * from t1 ORDER BY n;
n n
......
...@@ -21,7 +21,7 @@ Master_User root ...@@ -21,7 +21,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 60 Connect_Retry 60
Master_Log_File master-bin.000001 Master_Log_File master-bin.000001
Read_Master_Log_Pos 556 Read_Master_Log_Pos #
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
...@@ -36,7 +36,7 @@ Replicate_Wild_Ignore_Table ...@@ -36,7 +36,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 556 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -63,9 +63,9 @@ insert into t2 values (34),(67),(123); ...@@ -63,9 +63,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 600 master-bin.000001 #
master-bin.000002 371 master-bin.000002 #
master-bin.000003 106 master-bin.000003 #
create table t3 select * from temp_table; create table t3 select * from temp_table;
select * from t3; select * from t3;
a a
...@@ -78,21 +78,22 @@ set global sql_slave_skip_counter=1; ...@@ -78,21 +78,22 @@ set global sql_slave_skip_counter=1;
start slave; 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 master-bin.000002
master-bin.000002 371 File_size #
master-bin.000003 415 Log_name master-bin.000003
File_size #
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 371 master-bin.000002 #
master-bin.000003 415 master-bin.000003 #
select @time_for_purge:=DATE_ADD(UPDATE_TIME, INTERVAL 1 SECOND) select @time_for_purge:=DATE_ADD(UPDATE_TIME, INTERVAL 1 SECOND)
from information_schema.tables from information_schema.tables
where TABLE_SCHEMA="test" and TABLE_NAME="t2"; where TABLE_SCHEMA="test" and TABLE_NAME="t2";
purge master logs before (@time_for_purge); purge master logs before (@time_for_purge);
show binary logs; show binary logs;
Log_name File_size Log_name File_size
master-bin.000003 415 master-bin.000003 #
insert into t2 values (65); insert into t2 values (65);
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
Slave_IO_State # Slave_IO_State #
...@@ -101,7 +102,7 @@ Master_User root ...@@ -101,7 +102,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 60 Connect_Retry 60
Master_Log_File master-bin.000003 Master_Log_File master-bin.000003
Read_Master_Log_Pos 504 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File master-bin.000003 Relay_Master_Log_File master-bin.000003
...@@ -116,7 +117,7 @@ Replicate_Wild_Ignore_Table ...@@ -116,7 +117,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 504 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -149,12 +150,12 @@ count(*) ...@@ -149,12 +150,12 @@ 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 4193 master-bin.000003 #
master-bin.000004 4198 master-bin.000004 #
master-bin.000005 2040 master-bin.000005 #
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 2040 master-bin.000005 # <Binlog_Do_DB> <Binlog_Ignore_DB>
select * from t4; select * from t4;
a a
testing temporary tables part 2 testing temporary tables part 2
...@@ -165,7 +166,7 @@ Master_User root ...@@ -165,7 +166,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 60 Connect_Retry 60
Master_Log_File master-bin.000005 Master_Log_File master-bin.000005
Read_Master_Log_Pos 2040 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File master-bin.000005 Relay_Master_Log_File master-bin.000005
...@@ -180,7 +181,7 @@ Replicate_Wild_Ignore_Table ...@@ -180,7 +181,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 2040 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
......
...@@ -30,7 +30,7 @@ Master_User root ...@@ -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 60268 Read_Master_Log_Pos #
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 ...@@ -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 60268 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -78,7 +78,7 @@ Master_User root ...@@ -78,7 +78,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 60268 Read_Master_Log_Pos #
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
...@@ -93,7 +93,7 @@ Replicate_Wild_Ignore_Table ...@@ -93,7 +93,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 60268 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -126,7 +126,7 @@ Master_User root ...@@ -126,7 +126,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 60268 Read_Master_Log_Pos #
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
...@@ -141,7 +141,7 @@ Replicate_Wild_Ignore_Table ...@@ -141,7 +141,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 60268 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -171,7 +171,7 @@ Master_User root ...@@ -171,7 +171,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -186,7 +186,7 @@ Replicate_Wild_Ignore_Table ...@@ -186,7 +186,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -217,7 +217,7 @@ Master_User root ...@@ -217,7 +217,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 60354 Read_Master_Log_Pos #
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
...@@ -232,7 +232,7 @@ Replicate_Wild_Ignore_Table ...@@ -232,7 +232,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 60354 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -261,7 +261,7 @@ Master_User root ...@@ -261,7 +261,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 60430 Read_Master_Log_Pos #
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
...@@ -276,7 +276,7 @@ Replicate_Wild_Ignore_Table ...@@ -276,7 +276,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 60430 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -295,10 +295,8 @@ Last_SQL_Errno 0 ...@@ -295,10 +295,8 @@ Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
flush logs; flush logs;
show master status; show master status;
File master-bin.000002 File Position Binlog_Do_DB Binlog_Ignore_DB
Position 106 master-bin.000002 # <Binlog_Do_DB> <Binlog_Ignore_DB>
Binlog_Do_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;
# #
# End of 4.1 tests # End of 4.1 tests
......
...@@ -11,7 +11,7 @@ Master_User root ...@@ -11,7 +11,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 106 Read_Master_Log_Pos #
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
...@@ -26,7 +26,7 @@ Replicate_Wild_Ignore_Table ...@@ -26,7 +26,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -52,7 +52,7 @@ Master_User test ...@@ -52,7 +52,7 @@ Master_User test
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 106 Read_Master_Log_Pos #
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
...@@ -67,7 +67,7 @@ Replicate_Wild_Ignore_Table ...@@ -67,7 +67,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -92,7 +92,7 @@ Master_User root ...@@ -92,7 +92,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -107,7 +107,7 @@ Replicate_Wild_Ignore_Table ...@@ -107,7 +107,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -132,7 +132,7 @@ Master_User root ...@@ -132,7 +132,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 106 Read_Master_Log_Pos #
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
...@@ -147,7 +147,7 @@ Replicate_Wild_Ignore_Table ...@@ -147,7 +147,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
......
...@@ -29,7 +29,43 @@ select * from t1; ...@@ -29,7 +29,43 @@ select * from t1;
a a
1 1
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 Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State #
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 851 # # master-bin.000001 Yes Yes 0 0 851 # None 0 No # No 0 0 Master_Host 127.0.0.1
Master_User root
Master_Port MASTER_PORT
Connect_Retry 1
Master_Log_File master-bin.000001
Read_Master_Log_Pos #
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
Exec_Master_Log_Pos #
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 #
Master_SSL_Verify_Server_Cert No
Last_IO_Errno #
Last_IO_Error #
Last_SQL_Errno 0
Last_SQL_Error
drop table t1; drop table t1;
...@@ -28,7 +28,7 @@ Master_User root ...@@ -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 72960 Read_Master_Log_Pos #
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 ...@@ -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 72960 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -76,7 +76,7 @@ Master_User root ...@@ -76,7 +76,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 72960 Read_Master_Log_Pos #
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
...@@ -91,7 +91,7 @@ Replicate_Wild_Ignore_Table ...@@ -91,7 +91,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 72960 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -124,7 +124,7 @@ Master_User root ...@@ -124,7 +124,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 72960 Read_Master_Log_Pos #
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
...@@ -139,7 +139,7 @@ Replicate_Wild_Ignore_Table ...@@ -139,7 +139,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 72960 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -169,7 +169,7 @@ Master_User root ...@@ -169,7 +169,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -184,7 +184,7 @@ Replicate_Wild_Ignore_Table ...@@ -184,7 +184,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -215,7 +215,7 @@ Master_User root ...@@ -215,7 +215,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 73046 Read_Master_Log_Pos #
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
...@@ -230,7 +230,7 @@ Replicate_Wild_Ignore_Table ...@@ -230,7 +230,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 73046 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -259,7 +259,7 @@ Master_User root ...@@ -259,7 +259,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 73122 Read_Master_Log_Pos #
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
...@@ -274,7 +274,7 @@ Replicate_Wild_Ignore_Table ...@@ -274,7 +274,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 73122 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -293,10 +293,8 @@ Last_SQL_Errno 0 ...@@ -293,10 +293,8 @@ Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
flush logs; flush logs;
show master status; show master status;
File master-bin.000002 File Position Binlog_Do_DB Binlog_Ignore_DB
Position 106 master-bin.000002 # <Binlog_Do_DB> <Binlog_Ignore_DB>
Binlog_Do_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;
# #
# End of 4.1 tests # End of 4.1 tests
......
...@@ -11,7 +11,7 @@ Master_User root ...@@ -11,7 +11,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 106 Read_Master_Log_Pos #
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
...@@ -26,7 +26,7 @@ Replicate_Wild_Ignore_Table ...@@ -26,7 +26,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -52,7 +52,7 @@ Master_User test ...@@ -52,7 +52,7 @@ Master_User test
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 106 Read_Master_Log_Pos #
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
...@@ -67,7 +67,7 @@ Replicate_Wild_Ignore_Table ...@@ -67,7 +67,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -92,7 +92,7 @@ Master_User root ...@@ -92,7 +92,7 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File Master_Log_File
Read_Master_Log_Pos 4 Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File Relay_Master_Log_File
...@@ -107,7 +107,7 @@ Replicate_Wild_Ignore_Table ...@@ -107,7 +107,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 0 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -132,7 +132,7 @@ Master_User root ...@@ -132,7 +132,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 106 Read_Master_Log_Pos #
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
...@@ -147,7 +147,7 @@ Replicate_Wild_Ignore_Table ...@@ -147,7 +147,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 106 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
......
...@@ -26,7 +26,7 @@ Master_User root ...@@ -26,7 +26,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 784 Read_Master_Log_Pos #
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
...@@ -41,7 +41,7 @@ Replicate_Wild_Ignore_Table ...@@ -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 327 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition Master Until_Condition Master
Until_Log_File master-bin.000001 Until_Log_File master-bin.000001
...@@ -72,7 +72,7 @@ Master_User root ...@@ -72,7 +72,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 784 Read_Master_Log_Pos #
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
...@@ -87,7 +87,7 @@ Replicate_Wild_Ignore_Table ...@@ -87,7 +87,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 327 Exec_Master_Log_Pos #
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
...@@ -116,7 +116,7 @@ Master_User root ...@@ -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 784 Read_Master_Log_Pos #
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 ...@@ -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 616 Exec_Master_Log_Pos #
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
...@@ -158,7 +158,7 @@ Master_User root ...@@ -158,7 +158,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 784 Read_Master_Log_Pos #
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
...@@ -173,7 +173,7 @@ Replicate_Wild_Ignore_Table ...@@ -173,7 +173,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 784 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition Master Until_Condition Master
Until_Log_File master-bin.000001 Until_Log_File master-bin.000001
......
...@@ -46,7 +46,7 @@ Master_User root ...@@ -46,7 +46,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 408 Read_Master_Log_Pos #
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
...@@ -61,7 +61,7 @@ Replicate_Wild_Ignore_Table ...@@ -61,7 +61,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 408 Exec_Master_Log_Pos #
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
......
...@@ -9,22 +9,22 @@ connect (master,localhost,root,,test,$MASTER_MYPORT,$MASTER_MYSOCK); ...@@ -9,22 +9,22 @@ connect (master,localhost,root,,test,$MASTER_MYPORT,$MASTER_MYSOCK);
connect (slave,localhost,root,,test,$SLAVE_MYPORT,$SLAVE_MYSOCK); connect (slave,localhost,root,,test,$SLAVE_MYPORT,$SLAVE_MYSOCK);
connection master; connection master;
reset master; reset master;
show master status; source include/show_master_status.inc;
save_master_pos; save_master_pos;
connection slave; connection slave;
reset slave; reset slave;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
change master to master_host='127.0.0.1'; change master to master_host='127.0.0.1';
# The following needs to be cleaned up when change master is fixed # The following needs to be cleaned up when change master is fixed
source include/show_slave_status.inc; source include/show_slave_status2.inc;
--replace_result $MASTER_MYPORT MASTER_PORT --replace_result $MASTER_MYPORT MASTER_PORT
eval change master to master_host='127.0.0.1',master_user='root', eval change master to master_host='127.0.0.1',master_user='root',
master_password='',master_port=$MASTER_MYPORT; master_password='',master_port=$MASTER_MYPORT;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
start slave; start slave;
sync_with_master; sync_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
connection master; connection master;
--disable_warnings --disable_warnings
drop table if exists t1; drop table if exists t1;
......
...@@ -18,13 +18,9 @@ save_master_pos; ...@@ -18,13 +18,9 @@ save_master_pos;
connection slave; connection slave;
--real_sleep 3 # wait for I/O thread to have read updates --real_sleep 3 # wait for I/O thread to have read updates
stop slave; stop slave;
--replace_result $MASTER_MYPORT MASTER_PORT source include/show_slave_status2.inc;
--replace_column 1 # 7 # 8 # 9 # 16 # 23 # 33 # 35 # 36 #
query_vertical SHOW SLAVE STATUS;
change master to master_user='root'; change master to master_user='root';
--replace_result $MASTER_MYPORT MASTER_PORT source include/show_slave_status2.inc;
--replace_column 1 # 7 # 8 # 9 # 16 # 23 # 33 # 35 # 36 #
query_vertical SHOW SLAVE STATUS;
start slave; start slave;
sync_with_master; sync_with_master;
select * from t1; select * from t1;
......
...@@ -147,12 +147,14 @@ INSERT INTO t1 VALUES ("This is a test of col a.", ...@@ -147,12 +147,14 @@ INSERT INTO t1 VALUES ("This is a test of col a.",
"This is a test of the large col c.", "This is a test of the large col c.",
"Col d"); "Col d");
SELECT * FROM t1; SELECT * FROM t1;
--replace_result default DEFAULT
SHOW CREATE TABLE t1; SHOW CREATE TABLE t1;
sync_slave_with_master slave; sync_slave_with_master slave;
--echo Insert some values and select them on slave --echo Insert some values and select them on slave
SELECT * FROM t1; SELECT * FROM t1;
--replace_result default DEFAULT
SHOW CREATE TABLE t1; SHOW CREATE TABLE t1;
...@@ -200,12 +202,14 @@ INSERT INTO t1 VALUES ( ...@@ -200,12 +202,14 @@ INSERT INTO t1 VALUES (
); );
SELECT BIN(a), BIN(b), BIN(c), BIN(d), BIN(e) FROM t1; SELECT BIN(a), BIN(b), BIN(c), BIN(d), BIN(e) FROM t1;
--replace_result default DEFAULT
SHOW CREATE TABLE t1; SHOW CREATE TABLE t1;
sync_slave_with_master slave; sync_slave_with_master slave;
--echo Insert some values and select them on master --echo Insert some values and select them on master
SELECT BIN(a), BIN(b), BIN(c), BIN(d), BIN(e) FROM t1; SELECT BIN(a), BIN(b), BIN(c), BIN(d), BIN(e) FROM t1;
--replace_result default DEFAULT
SHOW CREATE TABLE t1; SHOW CREATE TABLE t1;
--echo *** Cleanup *** --echo *** Cleanup ***
......
...@@ -9,12 +9,12 @@ connection master; ...@@ -9,12 +9,12 @@ connection master;
CREATE USER dummy@localhost; CREATE USER dummy@localhost;
CREATE USER dummy1@localhost, dummy2@localhost; CREATE USER dummy1@localhost, dummy2@localhost;
SELECT user, host FROM mysql.user WHERE user != 'root'; # root host non-determ SELECT user, host FROM mysql.user WHERE user like 'dummy%';
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
sync_slave_with_master; sync_slave_with_master;
--echo **** On Slave **** --echo **** On Slave ****
SELECT user,host FROM mysql.user WHERE user != 'root'; # root host non-determ SELECT user,host FROM mysql.user WHERE user like 'dummy%';
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
--echo **** On Master **** --echo **** On Master ****
connection master; connection master;
...@@ -30,13 +30,11 @@ DROP USER nonexisting@localhost, dummy@localhost; ...@@ -30,13 +30,11 @@ DROP USER nonexisting@localhost, dummy@localhost;
# All users exist # All users exist
DROP USER dummy1@localhost, dummy2@localhost; DROP USER dummy1@localhost, dummy2@localhost;
SELECT user, host FROM mysql.user WHERE user != 'root'; # root host non-determ SELECT user, host FROM mysql.user WHERE user like 'dummy%';
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
sync_slave_with_master; sync_slave_with_master;
--echo **** On Slave **** --echo **** On Slave ****
SELECT user,host FROM mysql.user WHERE user != 'root'; # root host non-determ SELECT user,host FROM mysql.user WHERE user like 'dummy%';
SELECT COUNT(*) FROM mysql.user; SELECT COUNT(*) FROM mysql.user WHERE user like 'dummy%';
--replace_result $MASTER_MYPORT MASTER_PORT source include/show_slave_status2.inc;
--replace_column 1 # 8 # 9 # 23 # 33 #
query_vertical SHOW SLAVE STATUS;
...@@ -4,6 +4,8 @@ source include/master-slave.inc; ...@@ -4,6 +4,8 @@ source include/master-slave.inc;
# Test of init_slave variable # Test of init_slave variable
# #
set global max_connections=151;
connection slave; connection slave;
stop slave; stop slave;
source include/wait_for_slave_to_stop.inc; source include/wait_for_slave_to_stop.inc;
......
...@@ -11,14 +11,13 @@ ...@@ -11,14 +11,13 @@
# Passes with rbr no problem, removed statement include [jbm] # Passes with rbr no problem, removed statement include [jbm]
source include/master-slave.inc; source include/master-slave.inc;
--replace_column 3 <Binlog_Ignore_DB> source include/show_master_status.inc;
show master status;
sync_slave_with_master; sync_slave_with_master;
stop slave; stop slave;
--source include/wait_for_slave_to_stop.inc --source include/wait_for_slave_to_stop.inc
change master to master_log_pos=75; change master to master_log_pos=75;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
start slave; start slave;
let $slave_param= Slave_SQL_Running; let $slave_param= Slave_SQL_Running;
let $slave_param_value= Yes; let $slave_param_value= Yes;
...@@ -31,15 +30,14 @@ stop slave; ...@@ -31,15 +30,14 @@ stop slave;
source include/show_slave_status.inc; source include/show_slave_status.inc;
connection master; connection master;
--replace_column 3 <Binlog_Ignore_DB> source include/show_master_status.inc;
show master status;
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);
save_master_pos; save_master_pos;
connection slave; connection slave;
change master to master_log_pos=106; change master to master_log_pos=4;
start slave; start slave;
sync_with_master; sync_with_master;
select * from t1 ORDER BY n; select * from t1 ORDER BY n;
......
...@@ -65,14 +65,14 @@ insert into temp_table values ("testing temporary tables"); ...@@ -65,14 +65,14 @@ insert into temp_table values ("testing temporary tables");
create table t1 (s text); 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');
sync_slave_with_master; sync_slave_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
select * from t1; select * from t1;
connection master; connection master;
flush logs; flush logs;
create table t2(m int not null auto_increment primary key); create table t2(m int not null auto_increment primary key);
insert into t2 values (34),(67),(123); insert into t2 values (34),(67),(123);
flush logs; flush logs;
show binary logs; source include/show_binary_logs.inc;
create table t3 select * from temp_table; create table t3 select * from temp_table;
sync_slave_with_master; sync_slave_with_master;
...@@ -106,10 +106,10 @@ connection master; ...@@ -106,10 +106,10 @@ connection master;
sync_slave_with_master; sync_slave_with_master;
connection master; connection master;
purge master logs to 'master-bin.000002'; purge master logs to 'master-bin.000002';
show master logs; source include/show_master_logs.inc;
# we just tests if synonyms are accepted # we just tests if synonyms are accepted
purge binary logs to 'master-bin.000002'; purge binary logs to 'master-bin.000002';
show binary logs; source include/show_binary_logs.inc;
# Calculate time to use in "purge master logs before" by taking # Calculate time to use in "purge master logs before" by taking
# last modification time of t2 and adding 1 second # last modification time of t2 and adding 1 second
...@@ -122,10 +122,10 @@ select @time_for_purge:=DATE_ADD(UPDATE_TIME, INTERVAL 1 SECOND) ...@@ -122,10 +122,10 @@ select @time_for_purge:=DATE_ADD(UPDATE_TIME, INTERVAL 1 SECOND)
--enable_result_log --enable_result_log
purge master logs before (@time_for_purge); purge master logs before (@time_for_purge);
show binary logs; source include/show_binary_logs.inc;
insert into t2 values (65); insert into t2 values (65);
sync_slave_with_master; sync_slave_with_master;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
select * from t2; select * from t2;
# #
...@@ -148,14 +148,14 @@ while ($1) ...@@ -148,14 +148,14 @@ while ($1)
enable_query_log; enable_query_log;
select count(*) from t3 where n >= 4; select count(*) from t3 where n >= 4;
create table t4 select * from temp_table; create table t4 select * from temp_table;
show binary logs; source include/show_binary_logs.inc;
show master status; source include/show_master_status.inc;
save_master_pos; save_master_pos;
connection slave; connection slave;
sync_with_master; sync_with_master;
select * from t4; select * from t4;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
# because of concurrent insert, the table may not be up to date # because of concurrent insert, the table may not be up to date
# if we do not lock # if we do not lock
lock tables t3 read; lock tables t3 read;
......
...@@ -50,9 +50,7 @@ sync_slave_with_master; ...@@ -50,9 +50,7 @@ sync_slave_with_master;
connection slave; connection slave;
select @@server_id; select @@server_id;
select * from t1; select * from t1;
--replace_column 1 # 8 # 9 # 23 # 33 # source include/show_slave_status2.inc;
--replace_result $MASTER_MYPORT MASTER_PORT
show slave status;
connection master; connection master;
drop table t1; drop table t1;
sync_with_master; sync_with_master;
......
...@@ -31,20 +31,20 @@ start slave until master_log_file='master-bin.000001', master_log_pos=323; ...@@ -31,20 +31,20 @@ start slave until master_log_file='master-bin.000001', master_log_pos=323;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
# here table should be still not deleted # here table should be still not deleted
select * from t1; select * from t1;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
# this should fail right after start # this should fail right after start
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;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
# again this table should be still not deleted # again this table should be still not deleted
select * from t1; select * from t1;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
# try replicate all up to and not including the second insert to t2; # try replicate all up to and not including the second insert to t2;
start slave until relay_log_file='slave-relay-bin.000004', relay_log_pos=746; start slave until relay_log_file='slave-relay-bin.000004', relay_log_pos=746;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
select * from t2; select * from t2;
source include/show_slave_status.inc; source include/show_slave_status2.inc;
# clean up # clean up
start slave; start slave;
...@@ -61,7 +61,7 @@ start slave until master_log_file='master-bin.000001', master_log_pos=776; ...@@ -61,7 +61,7 @@ start slave until master_log_file='master-bin.000001', master_log_pos=776;
--source include/wait_for_slave_sql_to_stop.inc --source include/wait_for_slave_sql_to_stop.inc
# here the sql slave thread should be stopped # here the sql slave thread should be stopped
--replace_result bin.000005 bin.000004 bin.000006 bin.000004 bin.000007 bin.000004 --replace_result bin.000005 bin.000004 bin.000006 bin.000004 bin.000007 bin.000004
source include/show_slave_status.inc; source include/show_slave_status2.inc;
#testing various error conditions #testing various error conditions
--error 1277 --error 1277
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment