We're updating the issue view to help you get more done.Learn more

mysqldump --master-data does not work with GTID setups

mysqldump --master-data (or --dump-slave) is a usual way to provision a new
slave from an existing master or slave. But this is not able to provision a
GTID slave, as the GTID is not available in the output.

Proposed solution is to add a --gtid option (old behaviour is preserved
without --gtid, for backwards compatibility).

With --gtid, the GTID position is output instead, while the old-style position
is included but commented out.

The GTID position is obtained from @@gtid_binlog_pos or @@gtid_slave_pos, if
using table locking, or from BINLOG_GTID_POS() if using non-blocking
consistent snapshot.

Status

Assignee

Kristian Nielsen

Reporter

Kristian Nielsen