Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Mar 1999 13:36:01 -0500 (EST)
From:      Jim Cassata <jim@web-ex.com>
To:        Chris Watson <cwatson@worldmediaco.net>
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: Route add question
Message-ID:  <Pine.BSF.4.10.9903091326460.2239-100000@Homer.Web-Ex.com>
In-Reply-To: <001901be6a56$3aa2c4b0$3d01a8c0@nt-trash.omaha.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 9 Mar 1999, Chris Watson wrote:

> I was trying to figure out today how to add a default route to an interface
> that is in a box with another interface that has a default route.
> 
> I.e
> 
> 3 nic cards in a box.
> 
> xl0
> fxp0
> fxp1
> If xl0 is ifconfig'd first then it gets the default route on bootup correct?

Incorrect.  Think about what a default route or a route is.  You are
telling the machine where to deliver packets.  The machine can only speak
to an interface to which it is directly connected.  The default route
simply says "If I have packets addressed to destinations that are not in
my route table (and so I don't know where they go) give them to this
interface"  It will do this for one interface only.

> What I was trying to do was assign the default route to fxp0 after bootup
> after xl0 was configured.
> I thought ifconfig xl0 delete might work. Then I could assign a the same
> default route to fxp0 that *was* assigned to xl0.
> But it kept useing xl0 as the interface.
>
The default route is going to be routed through the interface that
directly connects to the default gateway. take for example:

route add default 209.100.100.1

if I have ed0 ifconfig'ed for 209.100.100.5 with a netmask of
255.255.255.0 then this will be the interface used. 


Jim Cassata

516.421.6000
jim@web-ex.com

Web Express
20 Broadhollow Road
Suite 3011
Melville, NY 11747




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




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