Chapter 4: Email and the Web


If you are like me, the first thing you’ll want to do when you get your new Linux system up and running is to surf the Web. The next thing will be to send and receive email.

Under the Gnome desktop environment, you can run Netscape Messenger to send and receive email. Netscape Communicator or Navigator 4.51 for Linux can be used to browse the Web. These products work the same way—and have the same look and feel—as their counterparts in other visual operating systems, such as Windows. They are automatically installed as part of the standard Red Hat installation.

But before you can use these programs to do these things, you must first configure your system so you are connected to the Internet. In this chapter, I’ll show you how to configure a dial-up connection.

If you have a direct LAN connection to the Web (or—the functional equivalent—are connected via a cable modem), you may have already configured the appropriate network settings during the Red Hat installation. However, if you skipped this step during the Red Hat installation, or if you need to make changes to the settings you did enter, I’ll show you how to configure your network settings for direct Internet access.

Then you’ll launch the Netscape product suite and configure Messenger for incoming mail (by specifying a POP server) and outgoing mail (by specifying a SMTP server).

Becoming Root

Changing system settings, such as the modem or network configurations, generally requires root access. Root is the term used for the all-powerful Linux superuser. (For more information on Linux users and privileges, see Chapter 12.)

If you are not logged on as root, you can log off and log back on as root. Or, you can su—change your effective user identity—to root.

To su to root:

  1. Open a terminal window, either by clicking the terminal icon on the Gnome panel or by choosing Gnome Terminal from the Gnome Utilities menu (Figure 4.1).
  2. Click in the Terminal window, so that it has the focus of keyboard entries.
  3. With the terminal window open, type su root at the prompt.
  4. Enter the root password at the prompt.
    You’ll see at the next prompt that you are effectively logged on as root (Figure 4.1).


Figure 4.1 Use a terminal window to su to root, giving yourself the privileges of a system administrator.

Configuring Your System with Control Panel

The Gnome control panel is used to configure most aspects of your system. Each button on the control panel opens a different configuration applet (Figure 4.2). This control panel functions in much the same way as the Windows control panel.

The configuration applets include the following:

To open the control panel:

With the terminal window still open, and while you are still logged on as root (Figure 4.2), enter control-panel at the terminal prompt.


The System Configurator applet (Figure 4.3) presents a hierarchical window that allows you to change many settings, including those that can be changed by the Network and Modem Configurator applets. However, the separate applets are easier to work with.

Figure 4.2
The Gnome control panel allows you to configure most systems settings.

Figure 4.3 The System Configurator applet allows you to edit most settings, but it is more complicated to use than individual applets.

Configuring a Modem

If you are going to connect to the Internet using a modem that works over phone lines, sometimes called a dial-up adapter, you have to tell Linux what serial port your modem is connected to. You also have to set various network configuration settings. Your Internet service provider (ISP) should supply these. It’s a good idea to make sure you have all the configuration information supplied by your ISP before you try to enter your settings in Linux.

To choose a serial port:

  1. Open the Modem Configurator applet (Figure 4.4).
  2. Select the serial port your modem is connected to.
  3. Click OK to close the dialog box.


To enter DNS information:

  1. Open the Network Configurator applet.
  2. Select the Names tab (Figure 4.5).
  3. Type the tuplets (series of numbers) provided by your ISP in the Nameservers box.
  4. Click Save to close the dialog box.


Figure 4.4 Use the Modem Configurator Applet to tell your system what serial port your modem is connected to.

Figure 4.5 Enter the DNS information provided by your ISP in the Nameservers box.

Configuring a Modem

To add a PPP interface:

  1. Click the tab to open the Interfaces page of the Network Configurator dialog box (Figure 4.6).
  2. Click the Add button at the lower left of the Interfaces page.
    The Interface Type dialog will open (Figure 4.7).
  3. Select PPP and click OK.
    The Create PPP Interface dialog will open (Figure 4.8).
  4. Enter your ISP’s phone number, your user name, and your password in this dialog box.
  5. Click Done.
    The new PPP Interface will now appear on the Interfaces page (Figure 4.9).
  6. Use your mouse to highlight the interface (labeled PPP0) and click the Edit button.
  7. Enable the Allow Any User to De(Activate) Interface setting (Figure 4.10).
    This allows any user—not just root—to dial and hang up.
  8. Click Done.
  9. Click Save on the Interfaces page (Figure 4.9).

To dial your ISP:

  1. Open a Terminal window (Figure 4.11).
  2. Enter the following at the prompt:
    /sbin/ifup ppp0
    If all is well, you should hear your modem dialing, following by the connection tones.

To check the connection:

With the terminal window still open (Figure 4.11), enter the following command to attempt to communicate with an important domain at Compaq computers:


You should receive a series of reply messages with the time of a round-trip journey to the computer you are pinging (Figure 4.11). If you receive a message back, it verifies that the two computers can communicate.


To close the connection:

  1. In the terminal window (Figure 4.11), type
    /sbin/ifdown ppp0

Figure 4.6 The Interfaces tab of the Network Configurator dialog box is used to add and modify network connections.

Figure 4.7 Use the Interface Type dialog box to select the type of network interface.

Figure 4.8 Your ISP phone number and identification information should be entered in the Create PPP Interface dialog box.

Figure 4.9 Once a new interface has been added, you can edit its properties using the Interfaces tab.

Figure 4.10 It's a good idea to allow any user - not just root - to activate and deactivate the network connection.

Figure 4.11 Use a terminal window to enter the commands to dial up your ISP, test the connection, and disconnect.

Configuring a Direct Connection

If you have a direct—or broadband— connection to the Internet, there are a few things you have to configure differently than when you use a dial-up connection.

A broadband connection typically means that you are interfaced with the Internet via a LAN or a cable modem.

There is no reason that you can’t have multiple connections: for example, one dial-up connection and one via a LAN.

To add an Ethernet interface:

  1. Open the Interfaces page of the Network Configurator applet (Figure 4.12).
  2. Click Add to add a new interface.
  3. Select Ethernet from the Interface Type dialog box (Figure 4.13).
  4. Click OK.
    The Edit Ethernet/Bus Interface dialog will open (Figure 4.14).
  5. Enter the IP for your machine and the netmask that should be used. Enable the Activate Interface at Boot Time option if you want Internet access to automatically be available when you boot up your computer.
  6. Click Done.
  7. Click Save on the Interfaces page of the Network Configurator applet.
  8. Select the Names tab to open the Names page of the Network Configurator (Figure 4.15).
  9. Enter your host name, domain, and name servers.
  10. Click Save.
  11. Select the Routing page of the Interface Configurator. Enter the default gateway. (Figure 4.16).
  12. Click Save.
  13. Close the Interface Configurator and reboot your system by entering the following at the command prompt in the terminal window:
    shutdown –r now.


Figure 4.12 Open the Interfaces page of the Configurator to add a direct connection.

Figure 4.13 Select Ethernet as the interface type for a direct connection.

Figure 4.14 You'll need to enter a unique IP for your machine in the Edit Ethernet/Bus Interface dialog box.

Figure 4.15 Enter your host name, domain, and IP addresses for your name servers on the Names page of the Configurator.

Figure 4.16 Enter your default gateway on the Router page of the Configurator.

Configuring and Using Netscape Communicator

From here, the process of configuring and launching the Netscape product suite to browse the Web and to send and receive email is the same as in any environment.

To launch the Netscape browser:

  1. Select the Netscape icon on the Gnome panel or select Netscape Communicator from the Internet folder on the Gnome Start menu.
  2. Now you can open any site you’d like. For example, enter to go to that site (Figure 4.17).

To configure the Netscape products:

  1. With the Netscape browser open, select Preferences from the Edit menu.
    You’ll see a hierarchy of options that can be configured (Figure 4.18).
  2. For example, to configure Navigator’s home page, select Navigator from the list on the left and enter the home page on the right (Figure 4.18).

To configure Messenger to send and receive mail:

  1. With the Netscape Preferences dialog still open, expand Mail and Newsgroups.
  2. Scroll down and select Identity on the left-hand menu (Figure 4.19).
  3. Enter your name and your email address on the right.
  4. Select Mail Servers on the left
    (Figure 4.20).
  5. Enter the name of your incoming mail server (this is usually a POP server) and the name of your outgoing (SMTP) mail server.
  6. Click OK.

To receive email:

  1. Select Messenger from the Communicator menu on the browser.
    Netscape Messenger will open (Figure 4.21).
  2. Click the Get Msg button (Figure 4.21).
  3. Enter your email password when prompted (Figure 4.22).

To send email:

  1. With the main Messenger window open, select New Msg (Figure 4.21).
    The Compose dialog box will open (Figure 4.23).
  2. Address and compose your email.
  3. Click the Send button.

Figure 4.17 You can browse any site you like by opening it in Linux Navigator.

Figure 4.18 The Netscape Preference dialog box is used to configure the Netscape product suite.

Figure 4.19 To configure Messenger, enter your identity.

Figure 4.20 You'll need to identify your incoming (POP) mail server and your outgoing (SMTP) mail server.

Figure 4.21 The main Netscape Messenger window is used to organize your email.

Figure 4.22 When you get your messages, you will be prompted for your email password.

Figure 4.23 The Messenger Compose window is used to create and send email.


In this chapter, you learned how to: