From: juphoff@chaos.aoc.nrao.edu (Uppie) Subject: MANY NET-2, SLIP QUESTIONS ANSWERED. (dynamic IP add's too) Date: Wed, 23 Jun 1993 18:55:57 GMT
Oops, my first post of this went to the wrong group (linux.announce).
Here it is in the right place:
I have received numerous requests to summarize any successful hints that
I received on running SLIP, and specifically on running SLIP with
dynamically assigned IP addresses. Well, some of this summary is based on
hints from others, and some of it is based on my own trial-and-error
hacking. Here goes:
First: Get 0.99pl10 and compile/install it.
NOTE: Unlike previous 0.99pl's, pl10 does not include an option during
'make config' for auto-detection of serial line IRQ's. (It does
the detection, but does not change the settings, even if it finds
an IRQ different from what it expects.--Someone should ask Linus
to put this feature back, it was handy.) The solution to this if
you are running non-standard IRQ's (such as me, I use IRQ5 for
COM3 because I have a laptop running as a vt100 there) is to edit
the file /linux/kernel/chr_drv/serial.c, adding a define statement
to enable this. Look at the comments at the beginning of serial.c
and this will all explain itself.
Next: Reboot. You will get numerous error messages from inetd if I
recall correctly. This is normal as net-2 is not installed yet.
Next: Get image-4.4.tar.z from a site and install the libraries.
Next: Update the links from libc.so.4 and libm.so.4 to refer to the
new libraries. Syntax: ln -sf lib?.so.4.4 lib?.so.4
BE VERY CAREFUL HERE!!! Do not try deleting the old links and making
new ones! Once you delete the old ones, you can't make any new ones
because ln needs the libraries to make new links, and the library
is "not there" as far as ln is concerned, because the link is gone.
Next: Install the net-2 binaries. You will need to create the directory
/conf/net for this if you simply want to unravel the tar file as
a whole. (There are other hints on doing the net-2 installation
properly, I have a file from someone detailing them and I will email
it to anyone who asks.) Details on configuring networking are in
the NET-FAQ. (Specifically nameserving, etc.)
Next: Reboot. 0.99pl10 should boot properly now.
NOTE: End of post contains more info on /conf/net links and such.
Ok, you now are set up to try and make a SLIP connection. I am going to
show the _exact_ commands that I use (they are a bit of a hack, but
work for me...I was more worried about being effective than elegant).
Background info: I am dialing into a gateway that assigns me an IP
address dynamically: 128.118.25.??? The address of the gateway is
128.118.25.1 I am running 9600 baud, my /dev/modem is a link to
/dev/cua0 on IRQ4. (My mouse is on COM2 at IRQ3.) The modem uses
standard Hayes commands.
Here is a transcript: Comments are enclosed in {}'s
%dip -t
DIP>port modem
DIP>speed 9600
DIP>reset
DIP>send att\r\n {define tone-type dialing}
DIP>dial ???-????
DIP>term {enter interactive mode}
{Welcome message, etc....}
TN>SLIP {TN> is my gateway's prompt, SLIP is the initiation command
on my gateway...this of course will vary from user to user.}
{My gateway now tells me that I have entered SLIP mode with an address
of 128.118.25.???, and that mtu = 1500.}
^] {return to dip command mode}
DIP>local 128.118.25.???
DIP>remote 128.118.25.1
DIP>mtu 1500
DIP>mode SLIP
%
We are now in SLIP mode, and a quick 'ifconfig' tells me that sl0 is up
and going, and shows me all the relevant addresses--I already know
these, but I always look to be sure everything is OK.
A 'route' command shows me the routing, and since I'm a standalone
system running through a gateway, I want to change this. I do this
by deleting the entry that has been created when SLIP fired up, and adding
a new one with the parameters that I want. {I haven't found a command
to modify routing, simply adding and deleting--anyone know a better way?)
Here's exactly what I do:
%route del 128.118.25.1 {get rid of the old one}
%route add default gw 128.118.25.1 {add the new one with new settings}
And I'm up and running! I edited my resolv.conf file to use some local
nameservers in the area and hit the net!
Things that I have tested so far and results:
Telnet: OK.
Finger: OK.
FTP: connecting to others from my computer: OK
connecting to my computer from others: not successful
(closes connection after I enter the password, I must have
something wrong in permissions or in the ftp configuration
somewhere.....anyone have any hints?)
ping: OK.
named: OK. I set up some secondary nameservers in my named.boot files
and the automatic querying and transfer of updated nameserver
files and such all went flawlessly. I this only as a test--
since then I have removed 'named' and simply use my resolv.conf
file. (I'm not worried about acting as a nameserver for myself
since when I'm not running SLIP I'm only in loopback mode, and
'named' is not needed.)
X-related: some success. I left slip running from my home computer and
went to my office. On one of the Suns (running X) there, I did
xhost +128.118.25.???, then telnetted back to my Linux
box at home (tying up the phone all day =) ) and did:
DISPLAY=nomad.astro.psu.edu:0.0 (the office machine).
I ran xlander, xeyes, and xgas on my home machine, and *poof*
the displays showed up in my office perfectly (albiet a little
jerky because of the phone-line lag).
I tried the exact reverse of what I had done once I
returned home that evening, and had no success. the
proesses appeared to be running, but no windows ever
appeared on my Linux box running (running olvwm).
Hope this is a help to some people....and I would appreciate it if
someone would forward any hints on modifying the routing tabel, as
well as a way to make dip trap that dynamic address rather than
having me type it in....if i could do that, then I could totally
automate this whole process. (dip won't go to mode SLIP until
you specificall declare the local address, but I have to go into
term mode to see it so that I can declare it.)
Also, could someone ask Linus to add the make config option
for auto IRQ setting? (un-remove it actually)...It was helpful
and didn't eat much. =)
Addition (late) as there are questions about installing net-2
regarding /conf/net links and such:
You need to create the following directories: /conf, /conf/net,
/conf/net/named.d
Now do a tar -t -v on the net-base file of net-2 and look at
all the links it makes. Move all the files that are sitting where
the links will be (mostly the /etc directory) to the places
that the links will point. (you may need to make other directories,
i can't recall...)
an example: move your named.boot file from /etc to /conf/net
When you untar net-base, it will create a link of:
/etc/named.boot -> /conf/net/named.boot
-- Jeff Uphoff -- "Uppie" | "The secret to good teaching is sincerity. As uphoff@astro.psu.edu | soon as you learn to fake that, you've got it juphoff@nrao.edu | made."