[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: two network cards on a server



On Thu, Apr 19, 2007 at 06:12:24PM -0400, Faheem Mitha wrote:
> 
> 
> On Fri, 20 Apr 2007, Alex Samad wrote:
> 
> >On Thu, Apr 19, 2007 at 05:15:25PM -0400, Roberto C. Sánchez wrote:
> >>On Thu, Apr 19, 2007 at 05:06:47PM -0400, Faheem Mitha wrote:
> >>>
> >>>/sbin/route -n
> >>>
> >>>Kernel IP routing table
> >>>Destination     Gateway         Genmask         Flags Metric Ref    Use
> >>>Iface
> >>>152.3.172.0     0.0.0.0         255.255.254.0   U     0      0        0 
> >>>eth1
> >>>152.3.172.0     0.0.0.0         255.255.254.0   U     0      0        0 
> >>>eth0
> >>>0.0.0.0         152.3.172.1     0.0.0.0         UG    0      0        0 
> >>>eth1
> >>>
> >>>Somebody suggested that using two network addresses with one network card
> >>> should be possible. Would this make these problems go away?
> >sorry, what are the problems that you are seeing ?
> 
> They were described in the first post to this thread. Namely one of the 
> two network cards on this machine (the one configured later) behaves 
> eratically, is only intermittently reachable from outside, and is 
> constantly broadcasting dhcp requests.
> 
> >>Yes.  I have one server (firewall actually) with 8 IPs on one physical
okay I thought it might be have a look at 

ip-sysctl.txt (in the kernel source tree doc/networking

arp_filter - BOOLEAN
        1 - Allows you to have multiple network interfaces on the same
        subnet, and have the ARPs for each interface be answered
        based on whether or not the kernel would route a packet from
        the ARP'd IP out that interface (therefore you must use source
        based routing for this to work). In other words it allows control
        of which cards (usually 1) will respond to an arp request.

        0 - (default) The kernel can respond to arp requests with addresses
        from other interfaces. This may seem wrong but it usually makes
        sense, because it increases the chance of successful communication.
        IP addresses are owned by the complete host on Linux, not by
        particular interfaces. Only for more complex setups like load-
        balancing, does this behaviour cause problems.

        arp_filter for the interface will be enabled if at least one of
        conf/{all,interface}/arp_filter is set to TRUE,
        it will be disabled otherwise

I think you are looking for 1.  You could also bond the interfaces - not sure
exactly what your trying to do (end result)


> >>interface.  It simplifies things greatly.  You want to search for how to
> >>do aliases.
> >
> >have a look for ip (it part of the iproute package)
> >
> >Usage: ip addr {add|del} IFADDR dev STRING
> >      ip addr {show|flush} [ dev STRING ] [ scope SCOPE-ID ]
> >                           [ to PREFIX ] [ FLAG-LIST ] [ label PATTERN ]
> >IFADDR := PREFIX | ADDR peer PREFIX
> >         [ broadcast ADDR ] [ anycast ADDR ]
> >         [ label STRING ] [ scope SCOPE-ID ]
> >SCOPE-ID := [ host | link | global | NUMBER ]
> >FLAG-LIST := [ FLAG-LIST ] FLAG
> >FLAG  := [ permanent | dynamic | secondary | primary |
> >          tentative | deprecated ]
> 
> Er, why is this relevant? Sorry if I am being clueless.

ip is the new tool of choice for setting things (ip address links etc)
the above is the help for ip address - if you want to add a secondary address
to an interface



> 
> Thanks.                                         Faheem.

Attachment: signature.asc
Description: Digital signature


Reply to: