Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Mar 2007 12:22:47 -0700 (PDT)
From:      youshi10@u.washington.edu
To:        FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: per-interface default routes?
Message-ID:  <Pine.LNX.4.43.0703141222470.20708@hymn01.u.washington.edu>
In-Reply-To: <64CD631E-C04C-498E-A71D-208287D5511D@messier.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 14 Mar 2007, Mark Messier wrote:

> Suppose you have a freebsd box with two LAN interfaces,
> one numbered on netA and one on netB...
>
> Some applications are listening on the netA IP address, some on the
> netB IP address.  Some applications may be listening on all interfaces
> but might have a directive that indicates which IP address to use for
> packets sourced from the application, like this:
>
> 	query-source address 192.0.2.2 port 53;
>
> What I want to happen is that packets sourced from the
> netA IP address go out the netA physical interface
> and packets sourced from the
> netB IP address go out the netB physical interface.
>
> That is, I want per-interface default routes
> (is this the correct term?).
>
> How do I do this?
>
> Thanks,
> -mark

Route has more information if you want to setup default routes for interfaces. Either that, or natd will yield a solution for you.

-Garrett




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.4.43.0703141222470.20708>