Re: Disaster Recovery with master-master replication
Posted by:
Rick James
Date: August 24, 2012 08:39AM
> As there would inevitably be a short period where we inadvertently write to both masters.
Do two things:
* SET read_only = ON; -- on the backup master.
* Do not use 'root' (or other SUPER user) for your applications. (Use only for admin stuff by a human.)
The second item is because SUPER ignores read_only.
Be sure to set read_only at the proper time in your failover scripts. You _will_ have a brief time where no one can write.
DNS is notoriously slow; I suspect EC2 is no better. The stated TTL cannot be trusted.
> too long to re-read all the binary logs
As time goes on, you will get more logs. This will become intractable. Start considering taking dumps and use the logs from the point of the dump.
Another issue. If the disk dies on the writable master, you will need to take the backup master down long enough to take a dump to recreate the Master. Suggest you look into using Xtradb and Xtrabackup -- with them, you can almost avoid any downtime to take a dump of a running Master.
Subject
Views
Written By
Posted
7869
August 21, 2012 09:59AM
Re: Disaster Recovery with master-master replication
2633
August 24, 2012 08:39AM
1832
August 24, 2012 09:23AM
1763
August 24, 2012 10:09AM
2107
August 25, 2012 09:28AM
1723
August 28, 2012 02:01AM
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.