all traffic goes via eth0.. why?

i am running suse10sp2.

I have 2 network cards, ifconfig shows:

eth0 Link encap:Ethernet HWaddr 00:14:5E:A8:02:A4
inet addr: Bcast: Mask:
RX packets:170304 errors:0 dropped:0 overruns:0 frame:0
TX packets:232397 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:16102316 (15.3 Mb) TX bytes:271624681 (259.0 Mb)

eth1 Link encap:Ethernet HWaddr 00:14:5E:A8:02:A5
inet addr: Bcast: Mask:
RX packets:3181 errors:0 dropped:0 overruns:0 frame:0
TX packets:1109 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:203642 (198.8 Kb) TX bytes:70976 (69.3 Kb)

However, i scp copy a large file from other machine to this machine using different IP ( or, but I alwaysnotice only eth0 has activity. all other interfaces are idle. what could possibly go wrong? thanks

Look at your routing:

# netstat -r

You will most probably see that trafic to the network is routed through interface eth0.

here is what I got from “netstat -r”, but I still cannot figure out why all traffic goes to eth0…

stgbladeh103:~ # netstat -r
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface * U 0 0 0 eth0 * U 0 0 0 eth1 * U 0 0 0 eth10 * U 0 0 0 eth2 * U 0 0 0 eth3 * U 0 0 0 eth8 * U 0 0 0 eth9
9062-1300-vlan- * U 0 0 0 eth11
link-local * U 0 0 0 eth0
loopback * U 0 0 0 lo
default 9062-1300-vlan- UG 0 0 0 eth11
stgbladeh103:~ #

What happens IMHO is that the routing table is sorted according to the length of the netmask (the default route then comes last in the list). When a route to a destination is needed an entry is searched for that fits to the network/netmask combination. When one is found, that is it, no further searching done.

Now I do not know to much about this, but what you apparently want is ‘load balancing’. So try to find more info about this on the internet, or hope one of the better knowledgeble ppl here react to this thread.

If they are both connected to the same switch and you are trying to double your bandwidth, what you need is interface bonding/teaming (and other names). Your switch has to support it to be feasible.


i am not looking for bonding or load balance. In fact, my application need 2 network channels running independently.

Therefore, I have eth0 and eth1 on different hardware.

However, I found that my application is using both channels through eth0, leaving eth1 unused.

so… not sure how to rectify that… any suggestions?

Why? Only a router would require this functionality.

A little more explanation of what you are trying to do would be good, to try an suggest an appropriate solution

basically i am running a DB2 server, which needs to broadcast data on eth0, also receives interactive commands on eth1.

This is pretty much like a private network for eth0, and a corporate network on eth1. Not only DB2, but many server side applications need this type of config.

Thus my goal is to use two network interfaces to separate data across the two networks. But somehow eth0 takes over both network. My question is how to make eth1 on a different hardward takes away traffic on a different 192.168.XXX.XXX IP address

It’s still not clear if you are connecting both interfaces to the same network segment, i.e. same switch, or not. If you are not, then you shouldn’t assign them addresses in the same subnet.

All this talk about a private network on eth0 and a corporate network on eth1 makes it sound like you have a multihomed machine. But then you assign them consecutive IP addresses. So what gives?