Cristhian Alcantara Cadillo







 Contact me


 Other Stuff

Things about Peru


LINUX > Dial Up

Dial-Up Connection to an ISP (Internet Service Provider).

These instructions are just a brief description of how to “try” to connect to your ISP if it is possible, what i mean is that there are modems designed only for Windows, called WinModems. First find out if you have one of them. I have proved these instructions using Red Hat 6.0.

You need the following programs:
      1. The pppd daemon (to establish your connection, usually in /usr/sbin/ppd)
      2. The chat program, usually in /usr/sbin/chat

You need the following information (ask your ISP):
      1. The telephone number where you are going to connect.
      2. The primary and secondary DNS addresses. 
The domain of your ISP

Log on as the root, then, make sure your modem is functioning correctly and find out in which device is located. For example, my modem is connected to the /dev/ttyS1 and my WinModem is in the /dev/modem. Of course winmodems only work with Windows..

You need to specify a hostname for your host, to do this edit the /etc/sysconfig/network and give your machine a host name. Here is an example of this file:
            #DOMAINNAME= localdomain
            # GATEWAY=""   Only for Lan networks
            # GATEWAYDEV="eth0"       Only for Lan networks
            # NISDOMAIN="dbcustomer"  Only for Lan Network Information System

Edit your /etc/resolv.conf file, there you have to put the ISP´s domain and nameservers (DNS servers, both the primary and the secondary). Here is a example of the final format of this file:

Ok, if you want to add security to your machine one thing is to avoid the ftp or telnet services to be available to the entire INTERNET, you have to edit the /etc/inetd.conf  file and find where is the ftp and telnet services. Just add a # before the sentece and that´s it, for example:
               # ftp     stream  tcp nowait  root  /usr/sbin/tcpd  in.ftpd -l -a
               # telnet  stream  tcp nowait  root  /usr/sbin/tcpd  in.telnetd       

Now edit the /etc/host.conf and look for a line that begins with “order”, make sure it has the following:
order    hosts, bind

After that edit the /etc/nsswitch.conf and look for a line that begins with “hosts”, make sure it has the following:
hosts:  files dns
If hosts have more options don´t delete them

Now we are ready to prove if the pppd daemon can connect you to your ISP. Because we need to know what the pppd programs is doing, for example, if there is a failure in the connection we would like to know what happened. To do this you have to tell pppd to write log information into a file that you can review whenever you want. To do this just edit the /etc/syslog.conf file and add the following lines:
local2.*                      /var/log/ppp
                daemon.*                   /var/log/ppp
You can specify a different file, i mean different than /var/log/ppp, it´s up to you.

Edit the file /etc/ppp/options in order to configure it, add the following:
                #Comment the default route if you need to access an Ethernet

Maybe you have to restart your computer and then run as root the script of pppd Connection that is in the programs section, here

For more detailed information refer to the Official Linux HowTos


Welcome Linux stuff My University Resume
Programs Contact me Links Other Stuff

Last Update:
Wednesday, December 26, 2001