keeps both the master and slave binlog position info in mysqldump log

Bug #1076824 reported by Hui Liu on 2012-11-09
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Percona Server
Wishlist
Unassigned

Bug Description

Though the --master-data and --dump-slave could provide the MASTER(connected node to be dumping) and SLAVE(the dumping node's master, if exists), it's still not enough for DBA to use when try to use the restored node as a slave for the MASTER or SLAVE, for some urgent situation, as these two parameters conflict, only one CHANGE MASTER is allowed.

For the urgent case, take an example from our DBA's daily work, when dumped with --dump-slave but later want to use the backup to catch up the dumping node as a slave, because the master is crashed. It's hard to handle such case.

We could provide both MASTER and SLAVE binlog position info, when --dump-slave both provided:

--
-- Position to start replication or point-in-time recovery from (the master of this slave)
--

CHANGE MASTER TO MASTER_LOG_FILE='mysql-bin.000016', MASTER_LOG_POS=251460384;

--
-- Position to start replication or point-in-time recovery from
--

-- CHANGE MASTER TO MASTER_LOG_FILE='mysql-bin.000001', MASTER_LOG_POS=661;

Note that, the dumping node's binlog info is provided, and it's commented, once DBA decide to restore a new slave as the dumping node, it's possible.

yinfeng (yinfeng-zwx) wrote :

if we dumped the data from slave with --dump-slave and the master server was crashed later , and then the role of slave may be upgraded to be a new master, we can't set up a slave server that point to new master because we lack the information of "master status"

Changed in percona-server:
status: New → Confirmed
Vadim Tkachenko (vadim-tk) wrote :

I set to "New", as the bug has to be verified by Percona team for "Confirmed"

Changed in percona-server:
status: Confirmed → New
Changed in percona-server:
status: New → Triaged
importance: Undecided → Wishlist
fengyi (fengyi) wrote :

add --tmpdir option for mysqldump

This patch just extract information from "SHOW MASTER STATUS;" and "SHOW SLAVE STATUS;" and store in 'mysqldump_master_info' and 'mysqldump_slave_info' in the directory specified by '--tmpdir' , it doesn't affect the process of dumping data.

tags: added: contribution
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers