I am struggling with a scenario. Suppose we have two systems in same subnet A:- 192.168.1.5 and B:-192.168.1.6 where B is further connected with C:-172.22.1.5 through Openswan. B can ping C but A cant ping C.
I want to add a route in A that it route all traffic which is destined for 172.22.1.5 to B.
route add -net 172.22.1.0 netmask 255.255.255.0 gw 192.168.1.6 dev eth0 But it is not working. Checked with tcpdump and packets are not going to B.
Any ideas how this can be done ?