[eepro100] About RX and TX for a dual port nic on the same network

Thomas Lorenzen tl@theory.ki.ku.dk
Mon, 17 Sep 2001 11:08:40 +0200 (CEST)


     Hi'

   In my cluster setup of linux machines I have a server
with a dual port nic, which services all the clients via
diskless boot and root via nfs. The clients and the server
are connected evenly between two unmanages switches, which
in turn are connected via their gigabit ports. Half of the
clients are connected to sw-1, which also hosts eth1 of the
dual port nic, whereas the other half of the clients are
connected to sw-2, which also hosts eth2 of the dual port
nic. I note, that every machine can see each other via the
gigabit link interconnecting the switches, and thus every
client is able to see both eth1 and eth2 of the dual port
nic of the server.

   Below I present the relevant output of ifconfig.

eth1      Link encap:Ethernet  HWaddr 00:03:47:3B:27:EE  
          inet addr:192.168.200.100  Bcast:192.168.200.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:399607 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1070472 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100 
          Interrupt:19 Base address:0x4000 
eth2      Link encap:Ethernet  HWaddr 00:03:47:3B:27:EF  
          inet addr:192.168.200.200  Bcast:192.168.200.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:142634 errors:0 dropped:0 overruns:0 frame:0
          TX packets:104 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100 
          Interrupt:16 Base address:0x6000 

   Below I present the relevant output of route.

192.168.200.0   *               255.255.255.0   U     0 0 0 eth1
192.168.200.0   *               255.255.255.0   U     0 0 0 eth2


   The problem is, that if I ping the eth2 interface of the
dual port nic, then the eth1 interface of the dual port nic
answers back. This is somehow expectable, as both ports are
(and in my setup has to be) configured on the same network,
why the first available interface to the kernel apparently
gets to answer the request. As one can see from the output
above this however produces a very uneven load on eth1 and
eth2 with respect to the interfaces. Both interfaces
receives packages (RX), but just about only the first
interface answers the requests (TX). In other words, pinging
eth2 increments RX of eth2, but increments TX on eth1,
meaning, that eth1 answers the ping.

   In brief my question goes as follows. Given a dual port
nic with both interfaces configured on the same network. Is
there then a way to specify, that packets to a specific
port, eth2 say, is always answered by the same port, eth2
say.

   Thanks for any help in advance.

   Best Regards.

     Thomas.

----------------------------------------------------------------------
Cand. Scient. Thomas Lorenzen               Phone : (+ 45) 35 32 02 50
Department of Chemistry                       Fax : (+ 45) 35 32 02 59
University of Copenhagen                     Mail : tl@theory.ki.ku.dk
DK, 2100 Copenhagen, Denmark   Homepage : http://theochem.ki.ku.dk/~tl
----------------------------------------------------------------------