Ping fails to mutli homed host with addresses on same subnet
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I've got bond0 set up, and my default route is attached to it:
root# ip route show
10.80.132.0/23 dev bond0 proto kernel scope link src 10.80.132.94
10.80.132.0/23 dev eth3 proto kernel scope link src 10.80.132.97
169.254.0.0/16 dev bond0 scope link
default via 10.80.132.11 dev bond0
root#
I am testing the other two interfaces have connectivity before setting up bond1, but I am having problems...
I am testing by pinging the "97" IP from a server on the same subnet (ie. local) and a server on another subnet (ie. remote).
When I assign the "97" IP to eth1 I get a response to my ping from both local and remote servers.
However, if I swap the IP to eth3 (I assign 0.0.0.0 to eth1 and down it, and then assign the IP to eth3 and up it), it doesn't work properly; I still get a local ping response but I don't get a remote one. (But it may spring to life after perhaps 20 minutes, but then swapping the IP back to eth1 makes it hang.)
I think the problem may be to do with the outbound traffic going over bond0 instead of back over the receiving interface.
I've done a fair amount of searching the internet and I thought it might be the so-called "arp flux" problem, so I tried setting the arp_filter to 1 for each interface, but it doesn't seem to have any effect. (My NICs don't have the "hidden" option there, which is the other thing mentioned in relation to the arp flux.)
My machine is a HP blade running RHEL 5.7, which is patched to a grab of what was available in August 2011.
I've set rp_filter on bond0 (which is on eth0 & eth2) and on each of the two interfaces I'm trying to switch between.
But then the remote stops regardless of which interface is active(and there is a gap in my icmp_seq); the local carries on.
FYI, I inherited an environment with UNIX (HP-UX) and Linux servers with multiple NICs on the same subnet, but it seems like I'm being a bit of a maverick in implementing bonding. However, I'm only implementing fault-tolerant (mode 1 = active/standby), as the network infrastructure isn't set up for active/active (LACP). My fallback will be to just use aliases on the primary interfaces pair.
Are you using your ethernet devices in the bond and outside it?
The routing table shows eth3 and not bond1 has been assigned the subnet..
One thing to realise which helps one think about this sort of thing,
is that an interface doesn't really have an ip address, (although its configured like that)
a host has the ip addresses, and an interface has the subnets.
You can use advanced routing stuff to try and get packets with the right source to leave the correct interface, but you will
need to tweak the routing tables, the arp_ignore settings and the rp_filter.
The kernel will arp reply on an ethernet interface for nearly any ip that it has, if there is a query, this can cause weirdness too
so try looking at the arp_ignore settings too.
You _can_ make this setup work, but it is a seriously confusing pain.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.