*BSD News Article 42170


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!msunews!caen!hookup!swrinde!pipex!peernews.demon.co.uk!demon!awfulhak.demon.co.uk!awfulhak.demon.co.uk!not-for-mail
From: brian@awfulhak.demon.co.uk (Brian Somers)
Newsgroups: comp.os.386bsd.questions
Subject: Re: PPP won't die on exit :-(
Date: 6 Feb 1995 20:34:45 -0000
Organization: None
Lines: 51
Message-ID: <3h6155$18e@awfulhak.demon.co.uk>
References: <3h3gki$4ag@News.Simplex.NL>
NNTP-Posting-Host: awfulhak.demon.co.uk
X-Newsreader: TIN [version 1.2 PL2]

Rob Simons (rob@Simplex.NL) wrote:
: Hi,

: Well, I've set up PPP now on a FreeBSD 1.1.5.1 box, and PPP itself
: works like a charm .. however the closing of the lines is another
: matter entirely.

: The client attaches to the server through a modem line, and pppd gets
: automatically fired up. When the client site desides it wants to hang
: up, it kills his running pppd and hangs up the phone line.
: The server side just sits and basically does nothing except hog up the
: ttyd line. The modem does answer again, but since the ttyd is hogged,
: no getty is running on it.

I havn't set up a receiving pppd (yet), but there are options for getting
pppd to periodically send 'are you there's down the line and hang up
if nothing replies.  This doesn't really sound correct, but it may work
until you suss the real answer.

: I've tried starting the pppd from a shell script, or directly from the
: passwd file -as- shell, no difference there. (what is the right method 
: btw ?)

run pppd direct - it's cleaner IMHO.

: Now I'm busy anyway, I have a few other questions as well:
: Can't a sh script run as suid root ?

I think bash will run scripts as root (if it's setuid root), but you
may have to rebuild it with some options set.

: Can I give a user a script as shell in the passwd file -with- arguments?
:       i.e. the shell field would look like: '/etc/ppp/ppplogin machine'

No, but your script (or /etc/ppp/ip-up) can check $USER and act acordingly.

: How can I alter the routing tables automatically when a PPP client logs
: on ?  (because there are a few other machines which should get routed
: through this PPP client)

Stuff some commands in /etc/ppp/ip-up (man pppd).

: Well, anyone who could shed some light on all or some of the above
: would have my eternal gratitude .. 

Hope some of this helps.

--
Brian <brian@awfulhak.demon.co.uk>

Don't _EVER_ lose your sense of humour....