2009-11-04 12:28:20 +00:00
|
|
|
# The test manually replaces the relay-log.info file with connection
|
|
|
|
# information which the slave then should pick up. However, to avoid
|
|
|
|
# overwriting the file, no CHANGE MASTER TO nor RESET SLAVE statements
|
|
|
|
# should be executed.
|
|
|
|
#
|
|
|
|
# Starting replication before granting a replication user privileges
|
|
|
|
# to replicate will cause the start slave to fail, so we shouldn't do
|
|
|
|
# that.
|
|
|
|
|
|
|
|
let $no_change_master = 1;
|
|
|
|
let $skip_slave_start = 1;
|
2005-12-22 06:39:02 +01:00
|
|
|
source include/master-slave.inc;
|
2009-11-04 12:28:20 +00:00
|
|
|
|
2001-01-24 12:47:09 -07:00
|
|
|
connection master;
|
2002-06-12 15:04:18 +03:00
|
|
|
grant replication slave on *.* to replicate@localhost identified by 'aaaaaaaaaaaaaaab';
|
|
|
|
grant replication slave on *.* to replicate@127.0.0.1 identified by 'aaaaaaaaaaaaaaab';
|
2001-01-24 12:47:09 -07:00
|
|
|
connection slave;
|
2002-10-24 17:46:14 -06:00
|
|
|
start slave;
|
2009-09-26 12:49:49 +08:00
|
|
|
source include/wait_for_slave_to_start.inc;
|
2009-11-04 12:28:20 +00:00
|
|
|
|
2001-01-24 12:47:09 -07:00
|
|
|
connection master;
|
2003-01-06 01:48:59 +02:00
|
|
|
--disable_warnings
|
2001-01-24 12:47:09 -07:00
|
|
|
drop table if exists t1;
|
2003-01-06 01:48:59 +02:00
|
|
|
--enable_warnings
|
2001-01-24 12:47:09 -07:00
|
|
|
create table t1(n int);
|
|
|
|
insert into t1 values(24);
|
2002-10-24 17:46:14 -06:00
|
|
|
sync_slave_with_master;
|
2001-01-24 12:47:09 -07:00
|
|
|
select * from t1;
|
|
|
|
connection master;
|
|
|
|
drop table t1;
|
2006-01-26 17:54:34 +01:00
|
|
|
delete from mysql.user where user="replicate";
|
2002-10-24 17:46:14 -06:00
|
|
|
sync_slave_with_master;
|
2005-07-28 03:22:47 +03:00
|
|
|
|
|
|
|
# End of 4.1 tests
|