[Pacemaker] Arp and configuration advice

Dejan Muhamedagic dejanmm at fastmail.fm
Fri Sep 11 10:10:02 UTC 2009


Hi,

On Wed, Sep 09, 2009 at 01:55:33PM -0400, j wrote:
> Thanks for your replies.
> 
> I seemed to have found the solution. Perhaps this will help others, so
> I'll send along what I've found:
> 
> I have a VIP on all db servers using IPAddr2. I found this link (to
> follow) before but executed the instructions on ALL machines, which was
> my stupidity...
> 
> http://kb.linuxvirtualserver.org/wiki/Using_arp_announce/arp_ignore_to_disable_ARP
> 
> Instead, the instructions should be followed for all machines with a VIP
> *not* running LVS/director.
> 
> That solves the problem of the wrong machines replying to who-is
> requests.
> 
> The only thing left is to make sure the web servers update their arp
> cache. So, I can execute SendArp on the web servers via an order
> constraint to they re-ask for the arp address for the director machine.
> 
> In testing, I had found that the SendArp tool (contrary to what it says)
> actually *asks* for the arp address, it doesn't send a gratuitous arp
> like advertised.

It does send an ARP packet. You can take a look at send_arp.c.
How did you find out it doesn't?

Thanks,

Dejan

> I hope this helps someone. Thank you all so much for your input!
> 
> Justin
> 
> On Wed, 2009-09-09 at 11:13 -0400, E-Blokos wrote:
> > ----- Original Message ----- 
> > From: <Darren.Mansell at opengi.co.uk>
> > To: <pacemaker at clusterlabs.org>
> > Sent: Wednesday, September 09, 2009 10:39 AM
> > Subject: Re: [Pacemaker] Arp and configuration advice
> > 
> > 
> > >> Greetings,
> > >> 
> > >> I have a two webserver/two database server clustered setup. I've got
> > >> ldirector and LVS managed by pacemaker and configured to be able to
> > > run
> > >> on either database machine.
> > >> 
> > >> I know how to disable ARP for the machine not running ldirector,
> > >> unfortunately I'm not sure how to dynamically get the webservers to
> > >> update their ARP cache when ldirector gets moved upon failure.
> > >> 
> > >> Is it possible to set up a service for the two web servers to delete
> > >> the
> > >> ARP cache for the VIP on the event that ldirector gets moved?
> > > 
> > > The IPaddr2 RA runs send_arp when the start action is called I believe:
> > > 
> > > 
> > > #
> > > # Run send_arp to note peers about new mac address
> > > #
> > > run_send_arp() {
> > >        ARGS="-i $ARP_INTERVAL_MS -r $ARP_REPEAT -p $SENDARPPIDFILE $NIC
> > > $BASEIP auto not_used not_used"
> > >        if [ "x$IP_CIP" = "xyes" ] ; then
> > >            if [ x = "x$IF_MAC" ] ; then
> > >                MY_MAC=auto
> > >            else
> > >                MY_MAC=`echo ${IF_MAC} | sed -e 's/://'`
> > >            fi
> > >            ARGS="-i $ARP_INTERVAL_MS -r $ARP_REPEAT -p $SENDARPPIDFILE
> > > $NIC $BASEIP $MY_MAC not_used not_used"
> > >        fi
> > >        ocf_log info "$SENDARP $ARGS"
> > >        case $ARP_BACKGROUND in
> > >        yes)
> > >                ($SENDARP $ARGS || ocf_log err "Could not send
> > > gratuitous arps" &) >&2
> > >                ;;
> > >        *)
> > >                $SENDARP $ARGS || ocf_log err "Could not send gratuitous
> > > arps"
> > >                ;;
> > >        esac
> > > }
> > > 
> > > 
> > > So when the VIP is started on another node, other nodes should be
> > > notified the IP has changed hosts. Doesn't it work for you?
> > > 
> > >> 
> > >> I can build my own OCF script to update the arp cache, that's not an
> > >> issue. I simply don't know how to configure pacemaker to say "Oop. db2
> > >> died. Move ldirector to db1 and tell the webservers to update their
> > > ARP
> > >> cache".
> > >> 
> > >> Any suggestions?
> > >> 
> > >> Thanks in advance!
> > >> 
> > >> Justin
> > >> 
> > > 
> > > Regards,
> > > Darren
> > 
> > I have also this kind of problem months ago,
> > ARP was not really updating well I don't know why...
> > 
> > 
> > > _______________________________________________
> > > Pacemaker mailing list
> > > Pacemaker at oss.clusterlabs.org
> > > http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> > > 
> > > -- 
> > > This message has been scanned for viruses and
> > > dangerous content by MailScanner, and is
> > > believed to be clean.
> > 
> 
> 
> _______________________________________________
> Pacemaker mailing list
> Pacemaker at oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker




More information about the Pacemaker mailing list