[CentOS] High Availability using 2 sites

Thu Jan 5 14:34:06 UTC 2006
Les Mikesell <lesmikesell at gmail.com>

On Thu, 2006-01-05 at 00:10, Tim Edwards wrote:
> We currently have a backup site at a different location to our main 
> site. This backup site mirrors (as closely as possible) our main 
> services, particularly web serving. Is there a way to have the backup 
> site act as a failover for the main site using something like Linux-HA? 
> They are on seperate internet connections with different IP ranges.

Web browsers (IE at least) tend to be very good about handling
failures if you give out multiple IP addresses for a name and
one or more locations does not respond.  When both work the
load will balance across them. If you provide the client
software for other services you can build in similar
robustness by getting the list from DNS and trying each until
you get a connection (don't retry too fast if you expect
to have a lot of clients...).

There are expensive commercial DNS servers like F5's
3dns that will test for service availability and modify
the response if a location is down.   Some free variations
may also be available.  For a few services you could
probably write your own fairly easily - you just have to
use a short TTL on the DNS records.   However, most
applications cache the DNS response internally regardless
of the TTL and won't automatically pick up a change unless
you exit the app and restart it.  IE does this too, but
if you have given out 2 addresses and one subsequently
stops working it seems to do the right thing where if you
give out one address first then change it you have to
exit and restart to pick up the new one.

--
  Les Mikesell
    lesmikesell at gmail.com