Re: simple ping; pinging 101

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

 



On Wed, 2005-07-06 at 07:40, THUFIR HAWAT wrote:
> two computers, arrakis and caladan, are
> connected with some standard RJ45 Cat 5e cable
> and a hub. arrakis can ping caladan from eth0.
> arrakis cannot ping caladan from eth1.
> 
> what's wrong with arrakis eth1, please?

> 
> [root@arrakis init.d]# route
> Kernel IP routing table
> Destination     Gateway         Genmask         Flags Metric Ref    Use
> Iface
> 192.168.0.0     *               255.255.255.0   U     0      0        0
> eth0
> 192.168.0.0     *               255.255.255.0   U     0      0        0
> eth1
> 169.254.0.0     *               255.255.0.0     U     0      0        0
> eth1
> [root@arrakis init.d]#
> 

The problem you are having is shown in the routing table above.  Even
when you have one of the two network cables disconnected the routes are
still in the table for both NICs.  Since both NICs are in the same
subnet they have routing entries to that subnet.

When you ping with eth0 connected it works.  Then when you disconnect
eth0 and connect eth1 and ping it does not work.  The reason is that the
ping looks in the routing table and finds the FIRST router to
192.168.0.0 network which is out eth0.  But eth0 is not connected to
anything so it fails.

If you completely disable eth0 so that route is not in the route table
eth1 will work.

The real question here is what are you trying to do?  Typically you can
not setup two NICs on the same LAN.  The only way to do this is to bind
them together to act as a single interface.  This will require a switch
that also understands how to bind interfaces/ports together.  

You can setup each interface in its own subnet but you will have to have
other devices in the other subnet for it to communicate with.

The other thing that has already been pointed out is that you do not
have a default gateway.  The default gateway is used for any packets
going to networks that are not on one of your local LANs.  This default
gateway will go out one of the two interfaces not both.

Also note: the 169.254 address if from the zeroconf project and is
useless.  This should be disabled by default but it is not. :)

-- 
Scot L. Harris
webid@xxxxxxxxxx

Things will be bright in P.M.  A cop will shine a light in your face. 


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux