Re: Webserver Redundacy
On Tue, Feb 27, 2007 at 06:27:19PM -0500, Jim Popovitch wrote:
> On Wed, 2007-02-28 at 10:09 +1100, Craig Sanders wrote:
> > i suggest you look into LVS anyway....by the time you've got heartbeat set up,
> > you've already done about two-thirds of the work needed to get load-balancing
> > working as well. with a little bit more work, you get load-balancing as well
> > as just failover.
> What if the load-balancer fails? :-)
you have a redundant LVS server.
with LVS, that could be dedicated LVS boxes, or it could be the real web
servers doubling as LVS boxes.
> -Jim P. (don't over architect a simple solution ;-) )
i've used both simple failover and LVS load-balancing on numerous
occasions. in my experience, LVS is not significantly more complicated
than just plain heartbeat and gives a whole lot more than just failover.
i.e. i don't think it is "over-architecting" the solution. most of the
design (and implementation) work you have to do for LVS is exactly the
same as what you would have to do for just heartbeat.
of course, it gets more complicated if you're doing, say mysql
clustering, as well as web site failover/load-bal....but that's going to
be more complicated anyway, whether you do failover or LVS
in fact, IMO, it's simpler to do LVS than failover for both web serving
and mysql clustering. with load-balancing you don't need to write any
scripts to handle the changeover from "backup" to "primary" server
because there is no changeover - all servers in the array are up and
running and serving requests at all times.
this is much simpler than having to handle the changeover event
(bringing up interfaces, starting up server daemons, etc) when the
primary goes down (so the backup takes over) and the reverse when the
primary comes back up (so the backup needs to be taken down). getting
this part of the failover stuff right can be very tricky and complicated
and there are several potential race-conditions if you're not careful.
IME, this is the hardest part of getting heartbeat working.
LVS avoids all that because there is no changeover.
craig sanders <firstname.lastname@example.org>
BOFH excuse #401: Sales staff sold a product we don't offer.