2016-03-25 20:51:22 +04:00
|
|
|
connect master,127.0.0.1,root,,test,$MASTER_MYPORT,;
|
|
|
|
connect slave,127.0.0.1,root,,test,$SLAVE_MYPORT,;
|
|
|
|
connection master;
|
2009-09-30 18:38:02 -03:00
|
|
|
CREATE DATABASE federated;
|
2016-03-25 20:51:22 +04:00
|
|
|
connection slave;
|
2009-09-30 18:38:02 -03:00
|
|
|
CREATE DATABASE federated;
|
|
|
|
#
|
|
|
|
# Bug#47525: MySQL crashed (Federated)
|
|
|
|
#
|
2016-03-25 20:51:22 +04:00
|
|
|
connection slave;
|
2009-09-30 18:38:02 -03:00
|
|
|
CREATE TABLE t1(a INT);
|
|
|
|
INSERT INTO t1 VALUES (1);
|
2016-03-25 20:51:22 +04:00
|
|
|
connection master;
|
2009-09-30 18:38:02 -03:00
|
|
|
CREATE TABLE t1(a INT) ENGINE=FEDERATED
|
|
|
|
CONNECTION='mysql://root@127.0.0.1:SLAVE_PORT/test/t1';
|
|
|
|
SELECT * FROM t1;
|
|
|
|
a
|
|
|
|
1
|
|
|
|
# Start a asynchronous reload
|
|
|
|
# Wait for tables to be closed
|
|
|
|
# Ensure that the server didn't crash
|
|
|
|
SELECT * FROM t1;
|
|
|
|
a
|
|
|
|
1
|
|
|
|
# Drop tables on master and slave
|
|
|
|
DROP TABLE t1;
|
2016-03-25 20:51:22 +04:00
|
|
|
connection slave;
|
2009-09-30 18:38:02 -03:00
|
|
|
DROP TABLE t1;
|
2016-03-25 20:51:22 +04:00
|
|
|
connection default;
|
2009-09-30 18:38:02 -03:00
|
|
|
# Federated cleanup
|
2016-03-25 20:51:22 +04:00
|
|
|
connection master;
|
2009-09-30 18:38:02 -03:00
|
|
|
DROP TABLE IF EXISTS federated.t1;
|
2009-11-16 21:49:51 +01:00
|
|
|
DROP DATABASE IF EXISTS federated;
|
2016-03-25 20:51:22 +04:00
|
|
|
connection slave;
|
2009-09-30 18:38:02 -03:00
|
|
|
DROP TABLE IF EXISTS federated.t1;
|
2009-11-16 21:49:51 +01:00
|
|
|
DROP DATABASE IF EXISTS federated;
|