On 2011/07/19 06:49, Ben Harper wrote:
> Hi,
> I'm trying to NAT out to two DSL modems.
> I have three network cards on three subnets:
> re0: 192.168.4.0/24         Internal
> re1: 41.134.100.222/29    DSL_A
> re2: 10.10.10.5/24           DSL_B
> 
> I can NAT out to either re1 or re2, but I have to make my default
> gateway point to the relevant gateway on that network.
> How can I tell the route tables or the nat-to command what the gateway
> machine is?
> 
> So I can do this, but ***only if my default gateway is
> 41.134.100.217*** (which is the gateway for that net):
> pass out on re1 proto tcp from 192.168.4.0/24 to any nat-to re1
> 
> Likewise, I can do this, but once again, ***only if my default gateway
> is 10.10.10.1*** (which is the gateway for that net):
> pass out on re2 proto tcp from 192.168.4.0/24 to any nat-to re2
> 
> I believe I should be able to make this work without ANY default
> gateway. But then where do I tell the system
> what these two gateway machines are?

You need *A* default gateway, but it doesn't matter which you choose.
Then use "route-to {41.134.100.217@re1, 10.10.10.1@re2}" to redirect
traffic and nat-to rules for outbound traffic on the relevant interfaces.
You also need similar tricks with reply-to if you want to accept
incoming traffic and make sure replies go out the correct interface.

Reply via email to