Autor: W B Hacker Data: A: exim users Assumpte: Re: [exim] heartbeat load balancing and exim
Jeroen van Aart wrote: > Just some ideas about using something like heartbeat to load balance 2
> or more MTA servers. Say in the case you have 2 servers and wish to
> combine them in a load balancing set up. This would require a 3rd server
> to serve as a load balancer, either using heartbeat or a dedicated
> machine like a cisco box.
>
> If this is the case wouldn't implementing a load balancing setup
> actually introduce more points of failure? You have halved the chance of
> a failed MTA server causing downtime, but introduced the chance of the
> load balancer failing, causing downtime of both MTA servers. You also
> may have to deal with the added complexity of replicating the mailstore
> on 2 (in this example) servers, and such a mechanism (using rsync, or
> drbd) will have its own chance of failure.
>
> Or is there a way to access a server directly, automatically, when a
> load balancer fails? Maybe I am missing some obvious things.
>
> Thank you,
> Jeroen
>
It can be simpler.
Much simpler.
- Let ordinary DNS entries split the day-to-day load over twin machines
by domain.tld
- sync their mailstore (by any of several methods - from unseen routers
through GMIRROR, nfs, or shared SAN)
- sync the *combined* <domain>.<tld> and UID:PWD file/db on both.
Much slower rate-of-change than message traffic anyway.
The DNS will see to it that MTA, MSA, and IMAP/POP use only the box(es)
'on duty'.
- have each box watch the other (checkservice, monit - whatever).
- IF/AS/WHEN a box sees its twin go offline, it picks up the IP of the
failed box as an alias.
Clients find the <domain>.<tld> at the same IP, and it has all the
requisite creds, mailstore, et al. Some minor - usually recoverable -
IMAP folder/content deletion differences, but not much else.
With a bit of planning, one can even have both sets of ssl certs
installed on both.
No third box required. No complex load-balacing required. No
lower-priority mx required unless you want a second physical location.
Restoral best done manually - but you were going to trouble-shoot and do
maintenance anyway, no?