*BSD News Article 73701


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!nntp.coast.net!fu-berlin.de!news.mathworks.com!hunter.premier.net!news1.erols.com!newsmaster@erols.com
From: Ken Bigelow <kbigelow@www.play-hookey.com>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Problem with PPPD dial script(s)
Date: Sun, 14 Jul 1996 19:57:13 -0700
Organization: Erols Internet Services
Lines: 72
Message-ID: <31E9B389.EF2@www.play-hookey.com>
References: <HUFF.96Jul7001252@sunspot.tiac.net> <4rrf2f$fg@anorak.coverform.lan> <4ruq0b$or7@cronkite.cisco.com>
NNTP-Posting-Host: kenjb05.play-hookey.com
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 2.02 (Win16; I)

Tim Iverson wrote:
> 
> In article <4rrf2f$fg@anorak.coverform.lan>,
> Brian Somers <brian@awfulhak.demon.co.uk> wrote:
> |Robert Huff (huff@sunspot.tiac.net) wrote:
> |:      I'm setting up kernel PPP and the sample scripts provided in
> |: the Handbook don't work.
> |
> |This is one of the reasons I stopped using it.  ijppp (prog: ppp)
> |is infinitely better - it dials, allows auto-connection, firewalling
> |etc.  I'd advise this approach.
> 
> Hmmm.  Iijppp is easier to play with for simple setups, but it has serious
> drawbacks.  The biggest being that it never execs another program to do
> anything for it -- everything must be done from within iijppp's own internal
> scripting language.  I need to configure NAT from a dynamically assigned IP
> when I dial up.  Can't do this with iijppp.
> 
> |ijppp allows you to run "chat" from within the program (fork/exec).
> |Here, chat inherits the serial descriptors, reads & writes the necessary
> 
> No.  At least not in the 2.1-release that I have.  Take a look at the
> source; iijppp never calls the chat program.  Instead, some of the source
> code from chat was copied into iijppp.  IMHO, this is poor engineering and
> a major design flaw -- always use an existing tool unless there is some
> large gain to be made by not doing so.
> 
> BTW, the documentation does say that iijppp fork/execs chat.  It lies.  ;-)
> 
> |If you *really* have a good reason for not using ijppp, the only
> |satisfactory way I found was to get your modem not to drop carrier
> |on loss of DTR for a long time (say 255 hundreths of a second).
> |You can then write a script that kermits, then *immediately*
> |runs pppd.  As long as pppd re-opens the line within your 2.55
> |second limit, you keep carrier.
> 
> Umm, no.  Open the line, run chat, run pppd, close line.  If you need
> special dialing, use xchat from tUUCP (it can do anything).  Documentation
> seems to indicate that pppd can open the line and then run chat for you,
> but none of the example scripts use this capability.
> 

man pppd for the last of the necessary info; this is a large man page.

I can't get iijppp working correctly for my system, so I use pppd.
I start pppd from rc.local with the line: pppd /dev/cuaa1 115200

All other essential info is in /etc/ppp/options -- the key lines in mine 
are:

crtscts				#hardware control
modem
206.161.179.129:		#My gateway's IP address
connect /etc/ppp/dial-erols	#chat script for login to ISP.
disconnect /etc/ppp/ip-down	#execute upon loss of IP connection
				#-- Doesn't always work right, so I
				#have a cron-driven line check program
				#as well, to run it for restart.
ipcp-accept-remote		#accept ISP's stated IP address.
defaultroute			#set route as default


Other entries are discussed in man pppd. This has been working fine for 
my full-time connection.

-- 

Ken

Are you interested in   |
byte-sized education    |   http://www.play-hookey.com
over the Internet?      |