"Linux Gazette...making Linux just a little more fun!"


Using diald to Connect to the Internet

By


Hello! This is a brief article about how to setup Diald on a RedHat 5.2 system. Yes, I know RedHat 6.0 is out, but this will be for a RedHat 5.2 system anyways. I wasn't able to test it on a RedHat 6.0 system in time.

What is Diald? It is program that runs in the background of your Linux system which will connect you to the internet through a modem anytime you try to get something from the internet. Thus, instead of manually dialing to get connected to the internet, all you have to do is type a url into your web browser, and if you are not already connected, it will attempt to connect for you. It also has the capability of disconnecting you after a period of inactivity with the internet.

Here are some more resources to help you.

  1. Diald homepage
  2. Mark's setup for QuickNet customers. QuickNet is a local ISP in Columbus, Ohio which supports Linux.
  3. FTP site where diald is located
  4. My copy of the diald rpms. I don't remember where I got them from.

This article is going to briefly tell you how to setup diald easily with RedHat 5.2.
  1. First, download the RPMS or from sunsite the tar files. I usually use the rpms.
  2. Install the two rpms
    rpm -Uhv diald*.rpm
  3. Next, use my configuration of /etc/diald/diald.conf
After you have downloaded the rpms, installed them, and replaced the diald.conf file, you need to do three things, edit diald.conf, activate the diald service, and make sure you have added ppp0 to the RedHat control panel.
  1. Replace MY_USERNAME_FOR_MODEM with the username you are connecting to your ISP. I am not sure if you actually need to do this, but it works for me.
  2. Okay, now add a "ppp0" interface (modem interface) to your computer. This can get lengthy. Here is TCU's article about setting up ppp0 for QuickNet users. If you are unable to get to that article, look at my brief notes about how to setup a ppp0 connection using RedHat's Control Panel.
  3. Next, you need to activate diald. The easiest way to do this is
    /etc/rc.d/init.d/diald start

    Or if you want to have it activated when your computer starts,
    chkconfig --add diald

DONE!


#
# diald.conf modified by Mark
#
accept any 1200 any
mode ppp
device /dev/modem
speed 57600
modem
lock
dynamic
local 137.130.2.44
remote 137.130.1.14
pppd-options name MY_USERNAME_FOR_MODEM
up-delay 5
defaultroute
crtscts
connect "/usr/sbin/chat -f /etc/sysconfig/network-scripts/chat-ppp0"
redial-timeout 10
fifo /etc/diald/diald.ctl


To setup your modem to com1 or com2
  1. # For com1
  2. rm /dev/modem
  3. ln -s /dev/cua0 /dev/modem
  4. # For com2
  5. rm /dev/modem
  6. ln -s /dev/cua1 /dev/modem


Here are the steps I did to get ppp setup. I did this as root. First, log in as root and start xwindows. The command to start Xwindows is "startx".

  1. The control panel should be there, choose network configuration. If it is not there, type this command in the xterm prompt to start the control-panel "control-panel".
  2. In this program, choose "Interfaces".
  3. Click on "Add".
  4. Choose "ppp".
  5. Enter in the phone number, username, and password.
  6. Click on "Use pap authentication".
  7. Click on "done".
  8. Click on "save".
  9. Now we need to set your DNS up correctly. Click on "Names" in the top menu of the Network Configurator. You should see "Nameservers" there.
  10. Enter "127.0.0.1" as one of the entries unless you have the number which should have been given to you by your ISP. 127.0.0.1 is a bad choice and should only be used as a last resource. Also, if you enter 127.0.0.1, you must have your DNS server installed locally and running in order for it to work. It is highly recommended to put in a nameserver number which your isp should have.
  11. Click on "Save".
  12. Click on "Interfaces" in the top menu.
  13. Now click on "Activate" for the ppp option you just made.
To activate and deactivate the modem as root, again, in the control-panel, choose "Network Configurations", then choose "Interfaces", select "ppp0", then click on "Activate" or "Deactivate" or turn the modem off and on.
Mark Nielsen works for The Computer Underground as a Linux geek. It is his first job that is 99% Linux oriented which leaves him ethically clean and feeling good about the work he does.


Copyright © 1999, Mark Nielsen
Published in Issue 41 of Linux Gazette, May 1999


[ TABLE OF CONTENTS ] [ FRONT PAGE ]  Back  Next