next up previous contents
Next: 8 Networking Up: Redhat FAQ Previous: 6 Installing Linux   Contents

Subsections


7 Modem

This works for the ``standard'' serial pots but may not detect a modem attached to a serial or multi-I/O card.

  1. Connect the modem to the desired serial port
  2. Log onto the server if necessary
  3. Run kudzu to auto-detect the modem
    $ sudo kudzu
  4. If this works, then /dev/modem should point to the modem. The actual device name will probably be either /dev/ttyS0 or /dev/ttyS1.
  5. If the autodection fails see Section 7.2
  6. Test the modem - I use minicom pointing to /dev/modem. Try a few AT commands and maybe dial a number you can check.

7.1 mgetty

Mgetty is used to monitor the modem and provide a login program for systems calling in. It can be tested from the command line but must be run from init for any real work.

  1. The first field in a /etc/inittab entry should be that last one or two characters of the actual device that mgetty is running on. Determine the device the modem is attached to:
    $ ls -l /dev/modem
    lrwxrwxrwx   1 root   root    10 Nov 11 20:42 /dev/modem -> /dev/ttyS0
  2. It is important that the device name given to mgetty in the last field of the entry (modem in this case) be the same as used by uucp and any other programs that access the serial port. Otherwise programs may not be able to recognize each other's locks and will not work correctly.
  3. The baud rate should be as fast as the port and modem allows. With speed buffering in modern modems, this need not be the same as the actual connection speed.
  4. Add to /etc/inittab:
    S0:12345:respawn:/sbin/mgetty -s 115200 modem
  5. Force init to re-read the inittab file
    $ sudo /sbin/telinit q
  6. To stop mgetty from answering the phone, create a file /etc/nologin.modem
    $ sudo touch /etc/nologin.modem
  7. Delete the nologin file to enable answering.


7.2 Manual Modem Setup

  1. Connect and turn on the modem
  2. Run statserial
    $ sudo statserial /dev/ttyS0
  3. Look for the line:
    DSR   6   6   in   1   Data Set Ready
  4. If the Status in column 5 is a 1 then there is a device attached. If not try the next serial device.
  5. Once the device is determined create a symbolic link for it. Assuming the device is ttyS0
    $ sudo ln -sf /dev/ttyS0 /dev/modem


next up previous contents
Next: 8 Networking Up: Redhat FAQ Previous: 6 Installing Linux   Contents
2005-03-20