Date: Mon, 16 Dec 2002 13:50:37 +0100 From: Boryan Yotov <test@prosyst.com> To: Justin Burke <mlist-freebsd@alt255.com> Cc: questions@FreeBSD.ORG Subject: Re: Adding defaultroute Message-ID: <3DFDCC1D.4030205@prosyst.com> References: <20021216110512.GZ59952@alt255.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello, if you take a look at /etc/rc.network you should be able to see how to setup through which device your default route will go. Otherwise simply change the following entry from /etc/rc,conf: defaultrouter="xxx.xxx.xxx.xxx" to defaultrouter="xxx.xxx.xxx.xxx rl0" Concerning the "File exists" error - it is issued when you try to setup once a route to host, network (or in your case default route) when an entry already exists into the routing table. In your case this means tah somehow you've already had a default route specified and some of the network script try to specify a default route once again. I suppose this is because of the dDHCP client which you use. When you assign a network characteristic for a device using a DHCP client then if not explicitly forbiden you'll have a default route assigned through that device. Thus way it's possible both of your device to have default route assigned through each of them. Through which of them the default route will actually proceed depends on which should be initialized first. So I think the clearest way (without error messages) is to deny default route assigning from your DHCP client (and to use the /etc/rc.conf entry which I wrote above). And finally, I hope this'll help :) Justin Burke wrote: > I'm having trouble getting a dual-homed system to setup the default > route correctly on bootup. Here are the relevant lines from my rc.conf: > > ifconfig_rl0="inet xx.xx.xx.xxx netmask 255.255.255.0" > ifconfig_xl0="DHCP" > defaultrouter="xx.xx.xx.x" > > During bootup, the system enables the default route to go through the xl0 > card, which I don't want; I'd like to enable to default route to go > through the rl0 card. > > After the network cards are setup, here is what is printed to the > console: > > route: writing to routing socket: File exists > add net default: gateway xx.xx.xx.xx: File exists > > Any suggestions? > > Justin > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3DFDCC1D.4030205>