mariadb/mysql-test/t/rpl000015.test
unknown 56b009412d Fix for
Bug#31030 rpl000015.test fails if $MYSQL_TCP_PORT != 3306
Note:
  This bug does not occur in MySQL 5.0 and up, because
  ChangeSet 1.2328.2.1 2006/11/27 for MySQL 5.0 prevents this.
  The 5.0 fix uses the environment variable DEFAULT_MASTER_PORT
  which is set by mysql-test-run.pl.
  mysql-test-run.pl in 4.1 does not set this variable.
  There are two alternatives:
  1) Backport the 5.0 fix for this test including modifications
     to mysql-test-run.pl and mysql-test-run-shell.
     This is a not acceptable impact on an old MySQL version.
  2) Fix the problem different than in 5.0 like in the current
     ChangeSet + do not apply these changes when upmerging to 5.0


mysql-test/r/rpl000015.result:
  Updated result
mysql-test/t/disabled.def:
  Enable rpl000015
mysql-test/t/rpl000015.test:
  Unify the MASTER_PORT number
2007-11-30 18:06:28 +01:00

43 lines
1.2 KiB
Text

-- source include/have_log_bin.inc
connect (master,localhost,root,,test,$MASTER_MYPORT,$MASTER_MYSOCK);
connect (slave,localhost,root,,test,$SLAVE_MYPORT,$SLAVE_MYSOCK);
connection master;
reset master;
show master status;
save_master_pos;
connection slave;
reset slave;
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
change master to master_host='127.0.0.1';
# The following needs to be cleaned up when change master is fixed
--replace_result $DEFAULT_MASTER_PORT DEFAULT_MASTER_PORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
--replace_result $MASTER_MYPORT MASTER_PORT
eval change master to master_host='127.0.0.1',master_user='root',
master_password='',master_port=$MASTER_MYPORT;
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
start slave;
sync_with_master;
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
connection master;
--disable_warnings
drop table if exists t1;
--enable_warnings
create table t1 (n int);
insert into t1 values (10),(45),(90);
sync_slave_with_master;
select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
# End of 4.1 tests