LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] keepalived - VRRP setup with no master

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: [lvs-users] keepalived - VRRP setup with no master
From: Sander Klein <roedie@xxxxxxxxx>
Date: Thu, 08 Jul 2010 23:08:30 +0200
Hi,

On Thu, 8 Jul 2010 20:17:33 +0100, campbell mcleay
<campbell.mcleay@xxxxxxxxx> wrote:
> I was interested in setting up LVS-NAT with keepalived for a redundant
> setup. All of the documentation recommends one director designated as
> master and one as backup. However, I was wondering if there is an
> issue having both as backup, the reasons for this configuration being
> 1) that config can be synced between the two directors, and 2) that if
> the master goes down and comes backup, it would not mean that the
> master would then take over again. I have read having the same
> priority could result in a race condition, but wouldn't this be very
> unlikely, since it would require both to come up at exactly the same
> time. I have not found any one else with such a setup, and all
> documentation says there has to be a master and backup with different
> priorities, so I want to be careful that I haven't missed something.
> It seems to work ok in practise so far though.

This question might better be asked on the keepalived mailing list. Maybe
someone has a better answer there than I have now.

I think you can give both directors the same priority. A director that is
in backup state and receives a vrrp packet with the same priority as it's
own should stay in backup state. But I can imagine it is possible that both
directors get in a state that they both start flapping between master and
backup state. I didn't look at any code, I only quickly reviewed the RFC.
So it might as well just work.

About your second point. You could use the 'nopreempt' option in the
keepalived config to keep a director with a higher priority from becoming a
master. So, when the directors initially start the director with the
highest priority becomes master. The master fails, so the director with the
lower priority becomes master. When the director with the higher priority
comes back online again it will become a backup director and stays backup
until the director with the lower priority fails.

Greets,

Sander

_______________________________________________
Please read the documentation before posting - it's available at:
http://www.linuxvirtualserver.org/

LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Send requests to lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
or go to http://lists.graemef.net/mailman/listinfo/lvs-users

<Prev in Thread] Current Thread [Next in Thread>