Initial PPP Setupby Bill Unruh
Table of contents:
The key problem in hooking up a PPP link to an ISP is that the ISPs
seem to compete with each other as to who can find another obscure way of
users. Thus we have
and combinations of these. The
chief difficulty of connecting to an ISP is discovering which technique
is actually being used by the ISP in an orderly way. Since few of them know
about Linux, and since few of them even understand what technique they
actually use, this procedure should allow you to set up without their
help, and to understand what the ISP's help means if it is given.
The following has a number of steps to connecting to your ISP. The temptation is to skip steps. This is a bad idea, as it will almost certainly lead to grief. Do each step and you will succeed, and you will also learn something about your system in the process.
These instructions were developed with the 2.0.x versions of the Linux
kernels, and also work with the 2.2.x series of kernels.
Similarly, they work with versions of
pppd at least from version 2.3.3
on (up to 2.4.1 by now). In fact, some of the features
below only work with later versions of
pppd. I would urge you to
upgrade to the latest version. You can get the latest
You may be able to get older versions from
but these sites are not being updated.
These steps are essentially independent of your ISP. Many ISPs do not know their own systems, and their advice must often be taken with a grain of salt. Thus, the document below shows you how to find out what your ISP wants, independent of what your ISP says he wants. However, you cannot do the first step without your ISP. You must get a user name and a password from your ISP -- which usually means that you must open an account with them and pay money. It is worth asking them to make sure that they tell you exactly what form that user name must take when you sign on. For example, some of them demand that you use your full email address with them as your user name, rather than simply the name itself. Others demand additions to the bare user name. Try to get them to be as specific as possible about exactly what you need to use.
You also need to get the ISP's Domain Name Server (DNS-IP)
address. (This is an address in Internet Protocol [IP] format, which is
four numbers each less than 256 separated by dots [for example,
will give you more than one. Occasionally an ISP will refuse. In that
case, they may supply the DNS dynamically instead. Using PPP version
greater than 2.3.7 will allow you still to sign on with them as
Having that information, log on as root, or, after you have logged on as a user, run
su and enter your root password at the prompt.
Make sure that you know which port your modem is on. The two programs
can help you to determine which port your modem is on. COM1 (serial
port 1) is
/dev/ttyS0. COM2 is
/dev/ttyS1, etc. In the following, I will assume
Change for your situation. It is preferable to use the ttyS ports rather
the cua ports or the modem port. The cua ports will disappear in future
of Linux, and the
/dev/modem port hides what you are actually doing and
to conflicts with other programs which use the serial ports.
[Note that if your modem is a winmodem, it will not work as-is under Linux. Some winmodems now have drivers for Linux. See www.linmodems.org--- It is probably a winmodem if it is a PCI modem, less so if it is an ISA and improbable if it is an external modem, and also improbably if it is not a 56-Kbps modem.
If you have the latest
kernels with USB support (Kernels 2.2.17 with the USB patches or 2.4.x)
you may also be able to use USB modems. (They must comply with the ACM
standard.) See the file
Documentation/usb/acm.txt included with the Linux source
/usr/src/linux* if included on your system, or
here is a copy
kernel 2.2.17). Note that for USB modems, the correct port to use is not
the serial port
ttyS? series but probably the
/dev/usb/acm/? series of
ports, where ? is a USB number. I have never used a USB modem, so can
provide no guidance on setting them up correctly.
http://www.o2.net/~gromitkc/winmodem.html for a listing of known
winmodems. For some advice on buying modems for Linux, see
To figure out what is happening while you are trying to log on to
ISP, you must turn on debugging and log the debug messages to a file.
The key programs are
pppd, and a program it uses, called
We will store those debugging messages in a file called
(You can use any file you wish, including
distributions are now installing a directory called
/var/log/ppp (for example,
the Corel distribution does this). If
yours does, you must use a different name, such as
/var/log/ppplog. Use that
name instead everywhere this document talks about
To make your system record the debugging information from both these programs, do the following
cp /etc/syslog.conf /etc/syslog.conf.orig
to make sure you have a copy of a good version in case you mess up the next command. If you have trouble, copy back the original version.
/etc/syslog.conf and add the lines
local2.* /var/log/ppp daemon.* /var/log/ppp
(Some versions of
syslogd (especially SunOS) demand that those be tabs -- not
between the two parts on each line. Some editors refuse to insert
tabs and convert them to spaces. The
syslogd shipped with most recent
distributions of Linux do not seem to care, but be warned.)
Then, to tell
syslogd to actually log the information, do
killall -1 syslogd
Pages: 1, 2