Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 12 Feb 1995 16:53:50 -0700
From:      Nate Williams <nate@trout.sri.MT.net>
To:        Pete Shipley <shipley@merde.dis.org>, questions@FreeBSD.org
Subject:   Re: slattach
Message-ID:  <199502122353.QAA01872@trout.sri.MT.net>
In-Reply-To: Pete Shipley <shipley@merde.dis.org> "slattach" (Feb 12,  2:50pm)

next in thread | previous in thread | raw e-mail | index | archive | help
> does anyone successfully use "slattach -r" to setup a slip link.
> 
> I use the  the command:
> 
>  /sbin/slattach -z -f -h -c -s 38400 -r '/usr/local/bin/kermit -y /etc/tlg.kermit >/tmp/kermit.log.$$ 2>&1' /dev/cua00
>  
> 
> It appears to me that slattach's -r command is unusable option.

I just installed 2.0R last night, and it works great using the additions to
/etc/netstart *'d below.  The link gets started correctly on reboot, and it
redails if the link is lost w/out any intervention.  Note, slattach needs
to happen before the ifconfig line (at least it was required in 1.1.5)

I'm actually very pleased with the way this works, and when I switch to
PPP most of this stuff will go with.

>From /etc/netstart:

-----------------/etc/netstart--------------
#!/bin/sh -
#
#	$Id: netstart,v 1.17 1994/11/07 04:02:25 phk Exp $
#	From: @(#)netstart	5.9 (Berkeley) 3/30/91

# This is the slip-host as well
(*)defaultrouter=`cat /etc/defaultrouter`
...
(*)# The slip connection
(*)slattach -a -h -r /etc/ppp/slip-dial -s 57600 cua01
(*)ifconfig sl0 inet $hostname $defaultrouter netmask 0xffffff00

# set the address for the loopback interface
ifconfig lo0 inet localhost

-----------------
> >From that I can tell the problem is that, when kermit exits, DTR is dropped.
> Thus the connection is lost before slattach can attach the ip-serial
> device to the tty port.

I wasn't able to get kermit to work, but this script (used in slattach above)
works great for me.

--------------/etc/ppp/slip-dial--------------
#!/bin/sh
#
# This program uses the chat program to (re)dial and connect back up to the
# SLIP host

PHONE=1234567
USER=mylogin
PASSWORD=mypassword
DEVICE=cua01
 
# Wait just a little for the line to settle down
sleep 10

(if chat -v ABORT "NO CARRIER" ABORT BUSY "" ATZ1 OK ATDT$PHONE CONNECT "" ogin: $USER ssword: \\q$PASSWORD
then
    exit 0
else
    exit 1
fi
) < /dev/$DEVICE > /dev/$DEVICE

-----------------



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199502122353.QAA01872>