Re: BUG: 2 NICs on same network

From: Harley Stenzel (hstenzel@nc.rr.com)
Date: Tue Apr 23 2002 - 08:58:27 EST


Frank Louwers wrote:
> Hi,
>
> We recently stummed across a rather annoying bug when 2 nics are on
> the same network.
>
> Our situation is this: we have a server with 2 nics, each with a
> different IP on the same network, connected to the same switch. Let's
> assume eth0 has ip 1.2.3.1 and eth1 has 1.2.3.2, with a both with a
> netmask of 255.255.255.0.
. . .
>
> Is this a bug or a known issue? If it is not a bug, how can it be
> solved?

It is a known issue with 2.4 Linux kernels and ARP. Linux will respond
to arp requests for any address configured on the box on any interface
that receives the arp request. Patches have been proposed in the past,
but the maintainers have elected to not accept the patches on the basis
that the current behavior is RFC-compliant. The behavior you describe
is also RFC-compliant, and is in fact what the other OSes that I'm
familiar with do.

In your situation, where you have a single nic that you want to use as
backup only, you could set noarp on the backup nic. Then, when you want
to talk to the machine on the backup nic, you could use a static arp
entry specifying the MAC address of the backup and any IP address on the
box.

Alternatively, you could put the NICs on different physical segments or
you could dig up the proposed patches (2.4.0,2,and 12 if I remember
correctly) and port them forward and apply them.

>
> Kind Regards,
> Frank Louwers
>

--Harley Stenzel
   hstenzel@nc.rr.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Apr 23 2002 - 22:00:35 EST