MySQL Forums
Forum List  »  Replication

Re: Load Balancing?
Posted by: sharding
Date: November 29, 2004 10:13AM

Emic clustering is ok, but not complete yet IMO. We have been working with Emic for about a year now to resolve various issues with the software. It is probably 90%-95% of the way there now. The biggest thing to know is that if you go the Emic route, that you will need at least 3 master nodes per cluster and that Emic masters themselves cannot replicate from another master. Note this information is specific to how we have our network set up and Emic might work 100% for other people with less specific needs.

If you have only 2 master nodes and one of them needs to be resynched, they both need to drop out of the cluster so the 'good' master can resynch the 'bad' master. This leaves you with exactly zero masters to take transactions. With 3 masters, unless 2 of them go out of synch at one time, you have at least one master at all times to take transactions. If you have a LOT of incoming changes (a LOT being several hundred per second) then a single master going out of synch can cause at least 2 masters (the one originally out of synch and the one that has to resynch it) to become even more out of synch since they do not replicate while resynching; all changes for those 2 masters are cached until they are resynched. If a lot of data needs to be synched then this could be a problem.

Slaves can replicate from Emic master nodes, but not the cluster itself which presents another problem. If the master the slaves are replicating from goes out of synch, this effectively puts all slaves replicating from that node out of synch.

All nodes in the cluster share the same IP address AND MAC address. This is important because some network cards do not like having their MAC address changes (EMIC software changes the MAC address at boot time). If you use Gig cards, go with Intel ones since I know they work. This also means ARP tables can get screwy since every master has the same MAC address, but different individual IP addresses AND share a client access IP address (you need 2 NICs in each node; one for client access (this one has same MAC and IP on each node) and one for cluster communications (these are individual IP and MAC per node). The internal communications if for heartbeat and synching).

As far as I know MySQL doesn't really have any kind of multi-master replication yet. The way we have it set up is all select queries go to slaves and all changes go to the master. This is so selects do not lock the master while it is receiving updates. We have around 20 MySQL servers so we built a system to transparently connect to appropriate databases with valid authentication information. All our software uses a set of Perl modules that wrap around DBI and connect to our 'Auth' system, which acts as a sort of firewall for our MySQL servers. It is all ACL-based using cluster identifiers to group database servers. Certain client servers can only connect to specific database servers.

Well, hope this information is useful albeit the post is almost 3 weeks old.

Options: ReplyQuote


Subject
Views
Written By
Posted
14278
November 09, 2004 11:30AM
Re: Load Balancing?
6310
November 29, 2004 10:13AM


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.