| 1 |
call mtr.add_suppression("Can't init tc log"); |
| 2 |
call mtr.add_suppression("Aborting"); |
| 3 |
# restart |
| 4 |
RESET MASTER; |
| 5 |
CREATE TABLE t1(a varchar(60) PRIMARY KEY, b VARCHAR(60)) ENGINE INNODB; |
| 6 |
INSERT INTO t1 VALUES(1, NULL); |
| 7 |
CREATE TABLE t2 (val INT) ENGINE=InnoDB; |
| 8 |
INSERT INTO t2 VALUES (0); |
| 9 |
connect con1,localhost,root,,; |
| 10 |
*** Start a background load... |
| 11 |
CALL gen_load(); |
| 12 |
connection default; |
| 13 |
*** Doing backup... |
| 14 |
*** Doing prepare... |
| 15 |
*** Stop the background load... |
| 16 |
UPDATE t2 SET val=1; |
| 17 |
connection con1; |
| 18 |
connection default; |
| 19 |
disconnect con1; |
| 20 |
*** Provision a new slave from the backup |
| 21 |
connect server2,127.0.0.1,root,,,$SERVER_MYPORT_2; |
| 22 |
*** Stopping provisioned server |
| 23 |
*** Removing old datadir for provisioned server |
| 24 |
*** Provision new server from backup |
| 25 |
# restart |
| 26 |
*** Configure slave position from xtrabackup_binlog_pos_innodb |
| 27 |
CREATE TABLE t3 (file VARCHAR(255), pos INT) ENGINE=InnoDB; |
| 28 |
LOAD DATA LOCAL INFILE "BASEDIR/xtrabackup_binlog_pos_innodb" |
| 29 |
INTO TABLE t3 FIELDS ESCAPED BY '' (file, pos); |
| 30 |
CHANGE MASTER TO |
| 31 |
master_ssl_verify_server_cert=0, |
| 32 |
master_port=PORT, master_host='127.0.0.1', master_user='root', |
| 33 |
master_log_file= "MASTER_FILE", |
| 34 |
master_log_pos= MASTER_POS; |
| 35 |
Warnings: |
| 36 |
Note 4190 CHANGE MASTER TO is implicitly changing the value of 'Using_Gtid' from 'Slave_Pos' to 'No' |
| 37 |
START SLAVE; |
| 38 |
connection default; |
| 39 |
connection server2; |
| 40 |
connection server2; |
| 41 |
STOP SLAVE; |
| 42 |
RESET SLAVE ALL; |
| 43 |
Warnings: |
| 44 |
Note 4190 RESET SLAVE is implicitly changing the value of 'Using_Gtid' from 'No' to 'Slave_Pos' |
| 45 |
DROP PROCEDURE gen_load; |
| 46 |
DROP TABLE t1, t2, t3; |
| 47 |
connection default; |
| 48 |
DROP PROCEDURE gen_load; |
| 49 |
DROP TABLE t1, t2; |