665 667




Linux Unleashed, Third Edition:SLIP and PPP





-->















Previous
Table of Contents
Next




Chapter 38SLIP and PPP

by Tim Parker

In This Chapter
•   Setting up the dummy interface
•   Setting up SLIP
•   Setting up PPP
•   Using DNS with SLIP and PPP

Most UNIX or Linux systems that want to make a connection to the Internet through an ISP or gateway do so with either Serial Line Internet Protocol (SLIP) or Point-to-Point Protocol (PPP). Both SLIP and PPP work through a dialup modem (either asynchronous, synchronous, or ISDN) to establish a link with remote systems. Linux provides both SLIP and PPP as well as an enhanced version of SLIP called CSLIP (Compressed SLIP).

You can perform SLIP and PPP configurations when you are configuring Linux TCP/IP or you can wait until you need to set them up for Internet access. Most Internet service providers prefer SLIP or PPP access from small systems as they provide fast, efficient transfers, so if you plan on using an ISP you will probably end up configuring the protocols yourself in the end.
The steps to setting up SLIP or PPP on your Linux system are not too complicated. Follow the process shown in this chapter and you’ll have the SLIP or PPP setup completed in a few minutes.
Setting Up the Dummy Interface
A dummy interface (also called a loopback interface or device) is used to give your machine an IP address to work with when it uses only SLIP and PPP interfaces. A dummy interface solves the problem of a standalone machine with no network cards connecting it to other machines. Most TCP/IP services and applications need an IP address which is usually lacking in a standalone configuration. For this reason, the loopback driver is configured with a standard IP address (127.0.0.1).
Creating a dummy interface is simple. If your machine has an IP address already assigned to it in the /etc/hosts file, all you need to do is set up the interface and create a route. For Linux the two commands needed are as follows:


ifconfig dummy machine_name
route add machine_name


machine_name is your local machine’s name. This creates a link to your own IP address. If you do not have an IP address for your machine in the /etc/hosts file, you should add one before you create the dummy interface by manually editing the /etc/hosts file and adding a line like this:


127.0.0.1 loopback


Some Linux systems do not use the ifconfig and route utilities, relying instead on a menu-driven user interface to set the same parameters up. In most cases with Linux, the loopback driver is added automatically for you when you install Linux. Check the /etc/hosts file for a line with the IP address 127.0.0.1. If it doesn’t exist, use whatever routine your version of Linux uses to set up new chains or simply use an editor to add it to the file, then reboot the machine to make the changes effective.
Setting Up SLIP
SLIP can be used with many dialup ISPs as well as for networking with other SLIP-equipped machines. When you are establishing a SLIP connection to another machine, the modem establishes a connection as usual, then SLIP takes over and maintains the session for you. The SLIP driver is usually configured as part of the operating system kernel, so it needs to be added if it doesn’t already exist. Most Linux SLIP drivers can also handle CSLIP, a compressed SLIP version that offers higher throughput. (Not all ISPs support CSLIP, so you should check with them before configuring it for your connection.)

For many Linux operating systems that use SLIP for connections, a serial port has to be dedicated for this reason. This means that a serial port must be specifically configured to use SLIP and cannot be used for any other purpose. The kernel uses a special program usually called SLIPDISC (SLIP discipline) to control the serial port and blocks non-SLIP applications from using it even when the port is not in use by SLIP.



Previous
Table of Contents
Next














Wyszukiwarka

Podobne podstrony:
665 667
IV CSK 665 10 1
ESET NOD 32 Antivirus 3 0 667 0 Full LICENCE 2050
665 Jak zostać biegłym rewidentem
2007 2` 64id 665
IV CSK 665 10 1 (a)
663 665
2007 Amphibians onlineid 667
665,7,artykul
Nuestro Circulo 665 ESTUDIOS FANTÁSTICOS, 23 de mayo de 2015

więcej podobnych podstron