Answer the question
In order to leave comments, you need to log in
Routing traffic through ospf?
Good afternoon!
There is a server with ip:
192.168.0.1
There is a server with ip:
192.168.10.1
192.168.10.2
192.168.10.3
and a computer is connected to them, ip:
192.168.11.1
I need traffic from the computer, using iptables, to forward to server 192.168.0.1
for example on the computer 192.168.11.1 ip route
192.168.0.1 proto zebra metric 30
nexthop via 192.168.10.1 dev eth0 weight 1
nexthop via 192.168.10.2 dev eth0 weight 1
nexthop via 192.168.10.3 dev eth0 weight 1
if formulated in ipfw rules, then I need analog:
ipfw add fwd 192.168.0.1 all from 192.168.11.1 to any
direct all traffic from the computer 192.168.11.1 to 192.168.0.1
I do this:
ip route add default via 192.168.0.1 table 120
ip rule add from 192.168.11.1 table 120
but the traffic goes along the default route (to the gate ip)
in advance, thank you very much for help!
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question