LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

ARPING and VIP vs MAC

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: ARPING and VIP vs MAC
From: pb <peterbaitz@xxxxxxxxx>
Date: Wed, 26 Feb 2003 08:36:36 -0800 (PST)
Hello all,

I was looking into a way to write a script that would
run on each LVS box such that the status of each VIP
could be checked, as to which MAC (ethernet) address
the VIP is "running" on.  As you know a failover of
the VIP also means the MAC address changes. It seemed
likely to me I could use Linux's "arping" command to
locate this info, process it and mail me at my pager
address.  We have had a couple circumstances in which
the backup LVS lost connection with the primary, so
both were running LVS and VIPs.  When connectivity was
restored, LVS daemon was correctly stopped on the
backup, but VIPs stayed up on both so routing was
affected.   So the following arping statements seemed
likely for a script + pager solution:

(IPs and MACs changed to protect the folks)

THIS DOES ARPING ON DEVICE:

[root@lvs]# arping -I eth0 184.186.18.50 -c 1
ARPING 184.186.18.50 from 184.186.18.51 eth0
Unicast reply from 184.186.18.50 [00:86:58:88:0D:D8] 
0.697ms
Sent 1 probes (1 broadcast(s))
Received 1 response(s)

THIS CHECKS FOR DUPLICATES:

[root@lvs6]# arping -I eth0 184.186.18.50 -D
ARPING 184.186.18.50 from 0.0.0.0 eth0
Unicast reply from 184.186.18.50 [00:86:58:88:0D:D8]
for 184.186.18.50 [00:86:58:88:0D:D8] 0.713ms
Sent 1 probes (1 broadcast(s))
Received 1 response(s)

But I can only get the above results from the BACKUP
LVS box, I cannot get any result when run from the
PRIMARY LVS box.   The above 184.186.18.50 is the LVS
VIP and the MAC address shown is on the PRIMARY eth0:1
device. Additionally, I cannot get any result when
running those arpings from my own Linux PC. I've tried
playing with the -I and adding -s (source IP) but does
not change outcome.  

Anybody use arping to do this kind of checking ?
Why does arping only work from the backup and not
the primary LVS nor from my PC ?  I cannot seem to
locate this kind of info on the web.  

Thanks
Peter


__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/
<Prev in Thread] Current Thread [Next in Thread>