Hello,
I am currently working on configuring a machine that has two network interfaces, and both are connected to the same subnet. I have configured the routing table so that they are able to ping/connect to both other machines on the same network and external machines. However, they are not able to connect/ping each other. For example, if I ping 192.168.101.14 from 192.168.100.250 (the two IPs) I just get "Host unreachable". Does anyone have any tips regarding how to solve this? I have attach the routing tables, please let me know if you need any more information.
Edited: I can see the ping packets in tcpdump/wireshark. The src.- and dst.-IP of the header is always equal but the destination inside the ICMP-packet is correct (for example 101.14 if pinging from 100.250). It seems that somehow Linux struggles to seperate the two interfaces.
Thanks in advance,
Kristian
Main routing table:
Code:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.100.0 * 255.255.254.0 U 0 0 0 eth0
192.168.100.0 * 255.255.254.0 U 10 0 0 eth1
default kasus.local 0.0.0.0 UG 0 0 0 eth0
default kasus.local 0.0.0.0 UG 10 0 0 eth1
Code:
192.168.100.0/23 dev eth0 scope link src 192.168.101.14
192.168.100.0/23 dev eth1 scope link src 192.168.100.250 metric 10
default via 192.168.100.1 dev eth0
default via 192.168.100.1 dev eth1 metric 10
Routing table for iface1 (used ip rule to make sure all traffic related to this interface passes through here)
Code:
192.168.100.0/23 dev eth0 scope link src 192.168.101.14
default via 192.168.100.1 dev eth0
Routing table for iface2 (done the same as with iface1)
Code:
192.168.100.0/23 dev eth1 scope link src 192.168.100.250
default via 192.168.100.1 dev eth1