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 have a x86 based PCM 6892 motherboard with a dual ethernet port 8139too.I am using Fedora Core 3 linux. I configured the devices so that eth0 has ip address x.x.x.1 and eth1 has ip address x.x.x.2. If eth0 cable is removed then x.x.x.1 and x.x.x.2 both do not respond to a ping request, whereas when eth1 cable is removed i get a response. I also tried bonding. I created a bond0 in active backup mode and enslaved eth0 and eth1. My problem was solved and i began to get response to ping even if one of the cables was removed. BUT if both the cables are present i recieve a DUPLICATE response to ping. Is there any solution?
Or is there any other solution other than bonding?
It would be ok even if i could configure the dual port so that it would behave like 2 separate ports
Thanking in anticipation
We have the same issue at the office. Two IP addresses over two NICs on the same subnet. The problem is that Linux picks one NIC to route the traffic out of and sticks to it. Only if you ifdown the NIC does it failover to the other connection. Your pings are being received by the server but it can't route them back out as the route it wants to send the traffic over isn't up (cos you unplugged the cable). You can see it in more detail by doing a netstat -rn
You'll see that there is one route for your subnet and it goes out of one NIC. The ip route command helps partially. It will instruct the routing table to send traffic back through the NIC it came in on, which will sort out your ping problem. However, if you need to initiate a connect from the Linux box itself, that will go down a black hole so not ideal.
Could do with a little more info on what you're trying to achieve here as there might be a better way of doing it. Are you looking for resilience across the two NICs? i.e. unplug one cable and you still have connectivity? or are you try to have more than one IP address to bind different applications to (e.g. multiple web instances).
If you're after resilience, then bonding should be the best way. I don't know why you'd be getting duplicate ping responses though I'm afraid.
Hi,
First of all, sorry for replying so late. I was keeping track of replies but donno how I overlooked your reply.
Initially I was using RedHat 8.0, and when I configured them in bonding, active-backup mode, I used to get duplicate responses to pings when both the cables were intact.
Now I am working on X-Linux.I need to have the two ethernet NIC's configured on the same subnet, and routing based on the source address of the packet.Is there any way of achieving this? Currently it routes all packets from one NIC UNLESS you ifconfig it down, in which case it switches to the second NIC.Also I have not tried bonding in embedded linux yet(I dont know if it gives duplicate packets here also), so I have to try it out.
Basically I need to have both
1. Independent operation of NICs
2. Bonded operation of NICs
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.