Date: Wed, 7 Jan 1998 19:03:16 -0500 (EST) From: John Brann <jbrann@brann.org> To: mhi@internetmci.com (Robert) Cc: freebsd-questions@freebsd.org Subject: Re: GATEWAY??? Message-ID: <199801080003.TAA10757@freebie.brann.org> In-Reply-To: <34B41053.3D09@internetmci.com> from Robert at "Jan 7, 98 05:31:31 pm"
next in thread | previous in thread | raw e-mail | index | archive | help
Robert wrote... > how do I define a gateway on freeBSD?? > I just got an ISDN line and I need to make the router the gateway for > the bsd box. > > help!! > thanks > Robert > Whoa, slow down! So you got an ISDN line, good for you. You mention a router. On the assumption that this is some device which talks to the ISDN line and an ethernet (I have a Netopia, myself), then the command you need is: add route default <hostname or IP address of router> (as root, of course). Just for good measure, you should modify rc.conf (on recent releases) or /etc/sysconfig (on older ones) to indicate that you want a default route and what it is. The line for /etc/rc.conf is: defaultrouter="<IP address of router>" # Set to default gateway (or NO). In this case, make sure you use the address. This will make sure you get the route back on a reboot. Once you think its ready, do a 'netstat -nr' and you should see output of this form: Destination Gateway Flags Refs Use Netif Expire default 10.0.0.1 UGSc 10 0 ed0 ... (Your Gateway IP address will be the one you specified, of course) Of course, if you don't really have a router, then the story is quite different :-) John -- Prohibit work, prohibit pay - people are dying! Situationist International slogan finger jbrann@doorman.brann.org for pgp public key
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199801080003.TAA10757>