I have two network interfaces with respective ips
eth0 : 192.168.70.153
eth2 : 192.168.70.155
when I make
route -C
Kernel IP routing cache
Source Destination Gateway Flags Metric Ref Use Iface
192.168.70.155 192.168.70.152 192.168.70.152 0 0 0 eth0
how I can force a telnet conection to 192.168.70.152 over eth2?
You would have to add a specific route for the host 192.168.70.152.
This would push all traffic destined for 192.168.70.152 over eth2. Would that be enough, or would you require only telnet to be routed?
What you want is the Linux Advanced Routing and Traffic Control HOWTO. Specifically, the section on Netfilter & iproute - marking packets is a good place to start for this sort of thing.
You'd set up your default route to go over eth0, then in
/etc/iproute2/rt_tables
add an entry, say at 200, for "viaeth2". Then you need to set up routing in that table:Then you can mark packets via iptables that should be routed via that table:
This will do what you specifically asked in the original question. If you want to do more general load-balancing across the two interfaces, you want to do "bonding" via the "bond" driver.