pt-slave-restart not reliable with GTIDs
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Toolkit moved to https://jira.percona.com/projects/PT |
Confirmed
|
High
|
Frank Cizmich |
Bug Description
I'm using pt-slave-restart 2.2.8.
How to reproduce:
1) Set up a master (A) and a slave (B) using GTID-based replication
2) On the slave in the test database, create a table like this:
mysql> create table t (id int not null auto_increment primary key);
3) On the master in the test database, create the same table, but with if not exists:
mysql> create table if not exists t (id int not null auto_increment primary key);
4) Make the slave the new master:
B> stop slave; reset slave all;
A> change master to master_
Replication is now broken on A because of the errant transaction created at step #2.
5) Insert a new row in t on the new master:
B> insert into test.t (id) values (null);
6) Run pt-slave-restart on the slave:
A# pt-slave-restart h=127.0.
2014-06-03T10:39:10 P=13001,
Use of uninitialized value $gtid_exec_ids in substitution (s///) at /usr/bin/
The output of SHOW SLAVE STATUS shows that replication is still broken and that the offending transaction has not been skipped.
Changed in percona-toolkit: | |
importance: | Undecided → High |
assignee: | nobody → Frank Cizmich (frank-cizmich) |
tags: | added: pt-slave-restart |
Changed in percona-toolkit: | |
status: | Invalid → Won't Fix |
Changed in percona-toolkit: | |
status: | Won't Fix → Confirmed |
Thanks for the detailed report Stéphane!
I followed your instructions but I was unable to reproduce this using MySQL 5.6
Every time pt-slave-restart worked and restarted the slave (previously master)
Are you using MySQL?
Can you run pt-slave-restart with PTDEBUG environment variable set and post results?
Thanks!