multiple subnets / routing

Started by D3s7, July 13, 2007, 09:29:51 AM

Previous topic - Next topic

D3s7

Ok so this is more of a freebsd routing question then a toaster question but it directly relates to my setup here and i'm drawing a total blank on how to do it.

here is my current setup

INET -> DSL connection -> Mail toaster

simple, straight forward, works great.  We however need to add a secondary route into the mailserver on our main inet connection.  The new setup will look something like this:

INET -> DSL Connection -> Mailtoaster (nic1)
INET -> T1 -> DMZ_FW -> Mailtoaster (nic2)

What I'm seeking assistance on is that the standard routing using a default route will no longer work here... packets coming IN nic2 are trying to go OUT nic1...

I'm assuming I can do this with a firewall rule or nat rule to return back to the source route, but can't quite match which one I need.

Anyone done this before and have any suggestions?

This is freebsd 6.2 w/ the latest toaster

D3s7

well after a lot of googling I found my answer....

dc0 = wan0
xl0 = wan1

in my ipf.rules:
pass out log quick on dc0 to xl0:{xl0 defaulroute) from xl0 to any


that right there says anything trying to go out wan0 that orginiated from wan1, redirect back to wan1

worked like a charm