If you are using something like heartbeat to start and stop
ldirectord,
then you don't want the synchronisation daemons handled there,
else the synchronisation daemon won't run when the ldirectord
resource is relinqushed on a node, and this really isn't what
you want.
ipvsadm has an init script, You should be able to use that
to start and stop the daemons.
Well here's what I am going to be doing in my next cluster going live
very soon now (sm). If anyone sees anything silly please let me know.
Note that if you copy my config you will have to change
/etc/ha.d/update's SSH line to the proper host, and reverse it for the
backup host. You will also probably want an ssh-public key login
setup,
although I'm not certain I'm going to do this.
</etc/ha.d/resource.d/lvsstate.sh>
#!/bin/sh
# script to set the sync state properly on both LVS servers.
case "$1" in
start)
/sbin/ipvsadm --stop-daemon
/sbin/ipvsadm --start-daemon master
;;
stop)
/sbin/ipvsadm --stop-daemon
/sbin/ipvsadm --start-daemon backup
;;
esac