MySQL Forums
Forum List  »  Replication

Re: Removing dead server from replication ring
Posted by: Jesús Uzcanga
Date: May 18, 2018 09:28AM

You can restore C and D from zero without having to shut off A (master server).

Just make a backup using --master-data=2 option

mysqldump -u MyUser -p --opt --master-data=2 --routines --databases MyDatabase > /pathtobackup/backup.sql


(During th backup the server will be up but the DB will be locked (all transactions will be processed after finish automatically.

That backup.sql contains a magic value... If you open it, will see the following line:

-- CHANGE MASTER TO MASTER_LOG_FILE='mysql-bin.000008', MASTER_LOG_POS=829650236;


So that's the magic, just restore that backup in C and set the master values as pointed.


Repeat from C to D.

___________________________
Ing. Jesús Alfredo Uzcanga
Twitter: @JesusUzcanga

We learn the 20% of what we HEAR,
the 50% of what we SEE,
the 80% of what we DO and
the 95% of what we TEACH.

____________________________________________________________
https://www.linkedin.com/in/jauzcanga/

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Removing dead server from replication ring
503
May 18, 2018 09:28AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.