| 1 |
# This test checks that the slave I/O thread refuses to start if slave |
| 2 |
# and master have the same server id (because this is a useless setup, |
| 3 |
# and otherwise SHOW SLAVE STATUS shows progress but all queries are |
| 4 |
# ignored, which has caught our customers), unless |
| 5 |
# --replicate-same-server-id. |
| 6 |
|
| 7 |
--source include/master-slave.inc |
| 8 |
connection slave; |
| 9 |
create table t1 (n int); |
| 10 |
reset master; |
| 11 |
# replicate ourselves |
| 12 |
--source include/stop_slave.inc |
| 13 |
--replace_result $SLAVE_MYPORT SLAVE_PORT |
| 14 |
eval change master to master_port=$SLAVE_MYPORT; |
| 15 |
--let $status_items= Slave_IO_Running, Slave_SQL_Running, Last_SQL_Errno, Last_SQL_Error, Exec_Master_Log_Pos |
| 16 |
--source include/show_slave_status.inc |
| 17 |
start slave; |
| 18 |
insert into t1 values (1); |
| 19 |
|
| 20 |
--let $slave_param=Last_IO_Errno |
| 21 |
--let $slave_param_value=1593 |
| 22 |
--source include/wait_for_slave_param.inc |
| 23 |
|
| 24 |
--let $slave_field_result_replace= / at [0-9]*/ at XXX/ |
| 25 |
--let $status_items= Last_IO_Errno, Last_IO_Error |
| 26 |
--source include/show_slave_status.inc |
| 27 |
|
| 28 |
--source include/stop_slave_sql.inc |
| 29 |
reset slave; |
| 30 |
reset master; |
| 31 |
drop table t1; |