Subject: Re: kermit?
To: Takashi Ikemi <ikemi@xa2.so-net.or.jp>
From: Bob Nestor <rnestor@metronet.com>
List: port-mac68k
Date: 08/06/1998 19:20:44
Takashi Ikemi <ikemi@xa2.so-net.or.jp> wrote:

>I'm now trying  SLIP connection between my two NetBSD macs (Classic II and
>Iici, NetBSD 1.3.1 on both), following the directions from the "Networking
>FAQ for NetBSD/Amiga"
>(http://rfhs8012.fh-regensburg.de/~feyrer/NetBSD/NWF/nwf_toc.html) as below
>:

Running SLIP into a NetBSD system is a lot easier now than when those 
instructions were first written.  Add the following two files to your 
system:

File #1:  /etc/sliphome/slip.login
#!/bin/sh -
#
#       $NetBSD: slip.login,v 1.3 1994/06/30 07:50:26 cgd Exp $
#       @(#)slip.login  5.1 (Berkeley) 7/1/90

#
# generic login file for a slip line.  sliplogin invokes this with
# the parameters:
#      1        2         3        4          5         6     7-n
#   slipunit ttyspeed loginname local-addr remote-addr mask opt-args
#
UNIT=$1
LOCALADDR=$4
REMOTEADDR=$5
NETMASK=$6
shift 6
OPTARGS=$*

/sbin/ifconfig sl${UNIT} inet ${LOCALADDR} ${REMOTEADDR} netmask 
${NETMASK} \
    ${OPTARGS}
/sbin/route add ${REMOTEADDR} ${LOCALADDR}
exit

File #2:  /etc/sliphome/slip.hosts
#
# login local-addr      remote-addr     mask            opt1    opt2 
#                                                       (compress == 
link0)
#                                                       (noicmp == link1)
#                                                       (autocomp == 
link2)
#
# This defines a login account named "Sbob" that will connect my NetBSD 
system
#  named "pluto" to a serial port identified as "slip0".  Replace the 
"pluto"
#  and "slip0" with actual IP addresses on your system if you're not 
running a
#  local DNS.
Sbob pluto      slip0          0xffffff00      link0

Define the IP address for your serial port:
     ifconfig sl0 inet <netbsd-ip-address> <remote-system-ip-address>

Add a new account (using vipw) to your NetBSD system for the user to log 
in as a SLIP user on the line.  Many ISPs use a technique of prefixing an 
"S" to an account name for SLIP access and a "P" for PPP access. In these 
setups a user has three accounts on the system, one for plain access, one 
for SLIP and one for PPP but they all point to the same home directory. 
In my example here my login account is "bob" and my SLIP account is 
"Sbob". This is what my passwd file looks like:
       bob:*:100:20:Bob Nestor:/home/bob:/bin/csh
       Sbob:*:100:20:Bob Nestor:/home/bob:/usr/sbin/sliplogin
       Pbob:*:100:20:Bob Nestor:/home/bob:/usr/sbin/pppd

Now, with all these steps completed you'll be able to log into your 
NetBSD system as a plain user with Zterm (or Jterm), log in as a SLIP 
user with something like InterSLIP, or log in as a PPP user with OT/PPP 
or FreePPP.  The setup on the serial port on the NetBSD system doesn't 
have to change to support this as the user chagnes from one protocol to 
another. However, without DTR support in your NULL modem cable the NetBSD 
system won't be able to do normal link shutdown when the remote user 
exits.

If you're using InterSLIP (1.0.1 or 1.0.2d2) make sure the NetBSD system 
has "NP" specified in the default entry of the /etc/gettytab file.  Early 
versions of NetBSD had defaulted to Odd Parity which confused InterSLIP 
since the initial NetBSD Banner was written in 7-bit Odd Parity then the 
line was switched to 8-bit no parity for the login.  InterSLIP insists on 
proper parity and word length for the login process, which for this setup 
should be the built-in UNIX login.

hope this helps,
-bob