Only one of the two ethernet interface is used
I have two ethernet interface (eth0 and eth1) on my server system and I have two linux client system. These three systems are inter connected through a switch. To dedicate one ethernet interface of the server to each of the client for better performance, I have configured them statically as shown below:
eth0 inet addr:192.168.221.1 Bcast:192.168.221.255 Mask:255.255.255.0
eth1 inet addr:192.168.231.1 Bcast:192.168.231.255 Mask:255.255.255.0
eth0 inet addr:192.168.221.2 Bcast:192.168.221.255 Mask:255.255.255.0
eth0 inet addr:192.168.231.2 Bcast:192.168.231.255 Mask:255.255.255.0
Ping and file transfer works fine. When I use Client2 to copy file from Server, eth1 of Server is used. However when I use Client1, to copy file from Server, eth1 of Server is used and not eth0. The same happens (only eth1 of server is used) when I copy file simultaneously from Client1 and Client2 thus eth1 is the bottleneck and I get only one ethernet interface performance.
Below is the ifconfig output of the server eth0 and eth1 before and after I copy 2G files simultaneously totaling 4G from each of the two clients:
eth0: RX bytes:14776137955 (13.7 GiB) TX bytes:381798147 (364.1 MiB)
eth1: RX bytes:20943165129 (19.5 GiB) TX bytes:383402896 (365.6 MiB)
eth0: RX bytes:14776146890 (13.7 GiB) TX bytes:396688679 (378.3 MiB)
eth1: RX bytes:25083190376 (23.3 GiB) TX bytes:440061868 (419.6 MiB)
Looking, only eth1 of the server is used to transfer 4G.
I do not want to do bonding and I want to dedicate eth0 of the interface on the server to Client1 and dedicate eth1 of the interface on the server to Client2. Please help me configure on this.
Thanks for any help from experts on this.