LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] LVS Sync in Ldirectord

To: Darren.Mansell@xxxxxxxxxxxx
Subject: Re: [lvs-users] LVS Sync in Ldirectord
Cc: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
From: Simon Horman <horms@xxxxxxxxxxxx>
Date: Fri, 18 Dec 2009 22:32:28 +1100
On Fri, Dec 18, 2009 at 11:12:40AM -0000, Darren.Mansell@xxxxxxxxxxxx wrote:
> >On Thu, 2009-12-17 at 16:37 +0100, Michael Schwartzkopff wrote:
> >> Am Donnerstag, 17. Dezember 2009 16:22:08 schrieb 
> >> Darren.Mansell@xxxxxxxxxxxx:
> >> > I'm using ldirectord to load LVS modules rather than the ipvsadm 
> >> > init script. Man ipvsadm says you need to start the ipvsadm sync 
> >> > daemon using --start-daemon state and --stop-daemon. As ldirectord 
> >> > is doing the loading / unloading of ipvsadm rules then I think the 
> >> > ldirectord script itself needs to support ipvsadm daemon sync states?
> >> >
> >> > Regards
> >> > Darren
> >> 
> >> Could be. But if you use a resource manager like pacemaker to control 
> >> ldirectord the sync daemon would be switched off in the passive node. 
> >> So no sync here.
> >> 
> >> controlling the ldirectord in the cluster has the advantage that the 
> >> cluster can react if the ldirectord dies.
> >> 
> >> If you would like to have ldirectord also to control the sync of 
> >> ipvsadm you would have to develop a multistate resource agent. Something 
> >> like:
> >> - Stopped: sync and ldirectord stopped
> >> - Started as slave: sync started, ldir stopped
> >> - Started as master: sync and ldir started.
> >
> >
> >You can, without any negative result, run both master and backup sync daemon 
> >on both hosts. I always have them set to a different sync-id, but perhaps 
> >that's not even necessary:

It isn't necessary. A node won't receive sync packets sent by itself.

> >node1 $ ipvsadm --start-daemon master --syncid 50
> >node1 $ ipvsadm --start-daemon backup --syncid 51
> >
> >node2 $ ipvsadm --start-daemon backup --syncid 50
> >node2 $ ipvsadm --start-daemon master --syncid 51
> >
> >Just create a simple init script for it, or put it in rc.local. Maybe you 
> >would have to do a modprobe vs or something similar before starting the 
> >daemons if you don't have ipvs built into the kernel. 
> >
> >I realize you could somehow create a fancier way than this, but i don't want 
> >to make it more complicated. LVS is hard enough already.

I don't advocate making it any fancier either.


_______________________________________________
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>