From owner-freebsd-questions Mon May 27 20:57:47 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id UAA27819 for questions-outgoing; Mon, 27 May 1996 20:57:47 -0700 (PDT) Received: from mailhub.Stanford.EDU (mailhub.Stanford.EDU [36.21.0.128]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id UAA27814 for ; Mon, 27 May 1996 20:57:44 -0700 (PDT) Received: from andrsn.stanford.edu (andrsn.Stanford.EDU [36.33.0.163]) by mailhub.Stanford.EDU (8.7.5/8.7.3) with SMTP id UAA19613; Mon, 27 May 1996 20:57:34 -0700 (PDT) Date: Mon, 27 May 1996 20:57:09 -0700 (PDT) From: Annelise Anderson To: fqueries@jraynard.demo.co.uk cc: freebsd-questions@freebsd.org, andrsn@hoover.stanford.edu Subject: Re: PPP Server Question In-Reply-To: <01I57O4N2O1U007IVP@HOOVER.STANFORD.EDU> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk On Mon, 27 May 1996, James Raynard wrote: > It's probably worth mentioning that "options GATEWAY" won't be around > for much longer - in fact it's already disappeared from -current. The > approved method is to put > > gateway=YES > > in /etc/sysconfig. This shouldn't cause you any problems at the > moment, though. > > > The ppp connection works fine, and I can ping the office machine > > from home and vice versa. I have an ip address to use for the home > > machine (and another one if I need it). What I can't do is ping > > or reach any host beyond the office computer from the computer at > > home. > > This usually means that everything's set up right, *except* for your > home computer not having a default route set. It does have a default route set--to the office machine: Routing tables Internet: Destination Gateway Flags Refs Use Netif Expire default 36.33.0.163 UGSc 0 300 tun0 36.33.0.75 36.33.0.163 UGHS 1 0 tun0 36.33.0.163 36.33.0.75 UH 1 7 tun0 127.0.0.1 127.0.0.1 UH 0 0 lo0 If I try to change the default route to the default the office machine uses (36.33.0.1), it says there's no route to that host. > [Cue simplistic explanation - there are three possible decisions that > BSD networking software can make when deciding where to send a > packet:- > > "It's addressed to me - I'll keep it". > > "It's addressed to a computer that's directly connected to me - I'll > send it straight to them." > > "Don't know how to reach them - I'll send it over my default route to > someone else who might know". I think it does this. The problem is that the office machine then does not send it further. > If it doesn't have a default route, it throws it away. So you could > ping your office machine, because it was directly connected by the PPP > link, but your home computer didn't know what to do when you wanted to > reach another host, as there wasn't a default route to send it over.] > > You can get PPP to do set a default route up for you when it makes the > connection. If you're using user-mode ppp, your home computer's > ppp.linkup file should look like this:- > > MYADDR: > add 0 0 HISADDR It does, but since the ppp.conf file won't dial the modem and I have to use terminal mode, the ppp.linkup file doesn't seem to get read, so I've been putting the default route in by hand, or actually with a script. > For kernel-mode pppd, add a line saying > > defaultroute > > to your home computer's "options" file. > > > It seemed from the handbook that running gated would be the right > > thing to do, so I installed it and changed sysconfig accordingly, > > turning off routed. > > No offence intended, but gated always makes me think of an eminent > Victorian politician's opinion on the Dreyfuss affair:- > > "Only three people have ever really understood this case. One is now > dead. Another is now insane. The third is myself." > > > > "Unfortunately, I appear to have forgotten most of the details!" > > Sorry about that. Anyway, my advice is not to bother with any kind of > routing daemons, unless you're doing something like setting up a > dedicated router for an ISP. > > If your office computer can talk to the outside world, and has IP > forwarding enabled, setting a default route on your home computer > *should* be all that's needed. Well, it doesn't seem to be working. There must be a piece missing. Any other ideas? Thanks, Annelise > -- > James Raynard, Edinburgh, Scotland > jraynard@dial.pipex.com > james@jraynard.demon.co.uk