Advanced MySQL Replication Techniques
Subject:   HA Lamp box
Date:   2006-05-03 07:24:10
From:   simon_massey
the mysql technique in this articles sounds idea for setting up a highly availability lamp (Linux, Apache, mysql, perl/python/php) website. the techniques in the book "The Linux Enterprise Cluster" by Karl Kopper could be used for Apache fail-over.
if you co-locate an Apache and mysql instances on each host (each apache node is also a mysql node) then you wont have to think very hard about the database fail-over with the technique described in this article. each Apache configuration would connect to localhost for mysql. just failing over Apache from that host would then effectively stop access to the co-located mysql instance.
if a particular mysql instance or Apache instance on a given host has failed then the whole hosts would be suspect and it should all be swapped out. as long as the heartbeat hit a scripted web page that touched the database then you would be testing the whole stack on a given node for a failure.
as the techniques for Apache clustering from a client perspective are well documented pushing the load balancing and fail-over up to that level would makes sense. if you read that book when building a dynamic website cluster the problem part is the resilient database. as the technique in this article requires no shared disk or other specialist hardware it appears to complete the picture perfectly.