Skip navigation links

MySQL Forums :: Replication :: Mysql 2 server replication setup with fail over


Advanced Search

Re: Mysql 2 server replication setup with fail over
Posted by: Irfan Ali ()
Date: September 24, 2011 05:26AM

>> So O think I need is a master - master with fail-over solution, however this seems to be very difficult with just 2 servers. I saw a nice setup on howtoforge but in this setup one master goes down the other one takes over the master function and when first master comes back online it will be slave. Which sounds good, but I don't see any method of determining which one is master in my php scripts to know where to to writing / editing the database..

I think you require MMM for MySQL solution. Which writes only on one master and replicates data to second master. And entire writing/editing on master handled through virtual ip address. In case of master1 down virtual ip moved to master2 and it becomes master to handle writes.
Don't bother handling in your php scripts. Infact you need to use one virtual ip address for write operations on your scripts.

Options: ReplyQuote


Subject Views Written By Posted
Mysql 2 server replication setup with fail over 2388 Steven SRS 09/23/2011 05:58PM
Re: Mysql 2 server replication setup with fail over 682 Irfan Ali 09/24/2011 05:26AM
Re: Mysql 2 server replication setup with fail over 750 Rick James 09/25/2011 01:20PM
Re: Mysql 2 server replication setup with fail over 596 Steven SRS 09/27/2011 01:11AM
Re: Mysql 2 server replication setup with fail over 662 Irfan Ali 09/27/2011 10:23PM


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.