Page 1 of 1

How to select gateway based on the src-address

Posted: Mon Nov 21, 2016 2:06 pm
by jmginer
Hello,

we have 2 upstreams in BGP providing us full-routing.

What we want, is to limit one /24 to only use 1 upstream.

We have done for incoming traffic in BGP filters, advertising the /24 to only 1 upstream.

But for the outgoing traffic we don't know how to do.

It's possible?

Thanks!

Re: How to select gateway based on the src-address

Posted: Mon Nov 21, 2016 8:24 pm
by jmginer
Found! with a Mangle:
/ip firewall mangle
add action=route chain=prerouting passthrough=yes src-address=x.x.x.0/24 route-dst=y.y.y.y
y.y.y.y is the gateway IP of my provider (their side IP).