policy-based routing
Posted: Tue Jan 17, 2006 8:41 pm
I have been trying for a week to get policy-based routing to work on my RouterBoard 532 with RouterOS 2.9.10 and have not been successful. I have looked at the examples at http://www.mikrotik.com/docs/ros/2.9/ip/route several times but the given scenarios do not match what I'm trying to do.
Here is my setup: Ether1 is my local network (192.168.69.1/24), Ether2 is ISP1 and is obtained via DHCP (68.102.x.x). Ether3 is ISP2 and has a static IP (158.247.x.x/29).
What I'm trying to setup is that any traffic coming in from Ether2 is routed back out Ether2 and any traffic coming in on Ether3 goes back out Ether3. Ether2 is set as my default gateway so that all traffic originating from the local network is routed out that interface.
The way it is right now, all traffic works coming through Ether2, but no inbound or outbound traffic works through Ether3. I have set up route-marks for inbound traffic on Ether3 and have a routing rule but that has not worked. I set this up via winbox but here are the resulting commands:
What am I missing to make all of this work? I greatly appreciate any help provided.
Mezlo
Here is my setup: Ether1 is my local network (192.168.69.1/24), Ether2 is ISP1 and is obtained via DHCP (68.102.x.x). Ether3 is ISP2 and has a static IP (158.247.x.x/29).
What I'm trying to setup is that any traffic coming in from Ether2 is routed back out Ether2 and any traffic coming in on Ether3 goes back out Ether3. Ether2 is set as my default gateway so that all traffic originating from the local network is routed out that interface.
The way it is right now, all traffic works coming through Ether2, but no inbound or outbound traffic works through Ether3. I have set up route-marks for inbound traffic on Ether3 and have a routing rule but that has not worked. I set this up via winbox but here are the resulting commands:
Code: Select all
/ ip firewall mangle
add chain=prerouting in-interface=Ether3 action=mark-routing \
new-routing-mark=ksnet passthrough=yes comment="" disabled=no
/ ip route
add dst-address=0.0.0.0/0 gateway=158.247.x.x distance=1 scope=255 \
target-scope=10 routing-mark=ksnet comment="" disabled=no
Mezlo