Certification Objective 1.12-Other Basic Prerequisite Skills per the Red Hat Exam Prep Guide


There are more prerequisite skills defined in the Red Hat Exam Prep guide at https://www.redhat.com/training/rhce/examprep.html. These are over and above the RH300 prerequisites as defined by https://www.redhat.com/training/rhce/courses/rh300_prereq.html. Word for word from the current Exam Prep guide, they specify that you know how to:

  • Configure an e-mail client on Red Hat Enterprise Linux

  • Use a text and/or graphical browser to access HTTP/HTTPS URLs

  • Use lftp to access FTP URLs

Configuring an email Client

The configuration process for a GUI e-mail client should be trivial for any candidate for Red Hat certification. However, the same may not necessarily be true for command line clients, and it's certainly possible that you'll have to configure RHEL 5 solely on the command line.

Command Line Mail

To test your mail system, you can use the built-in command line mail utility, a simple text-based interface. The system keeps each user's mail in a system directory. Once users read a message, they can reply, forward, or delete it. If they do not delete the message before quitting the mail utility, the system stores the message in the /var/ mail directory, in a file named after the applicable username.

You can certainly use any of the other mail readers, such as mutt, or the e-mail managers associated with different GUI Web browsers to test your system. Other mail readers store messages in different directories. For example, pine would create and store messages for user mj in the /home/mj/mail directory.

To send mail to another user, you can use the mail command line utility. There are two basic methods for using mail. First, you can enter the subject and then the text of your message. When you're done, press CTRL-D and then enter another addressee in the Cc: line, if desired. When you press ENTER, the message is sent and the mail utility stops and sends you back to the command line:

 $ mail Michael Subject: Test Message Sent and received Cc: mjang@example.com $ 

Alternatively, you can redirect a file as the text of an e-mail to another user. For example, the following command sends a copy of /etc/hosts to the root user, with the subject name "hosts file":

 $ mail root@localhost -s 'hosts file' < /etc/hosts 

Reading Mail Messages

By default, the mail system doesn't open unless you actually have e-mail in your inbox. Once it is open, you'll see a list of new and already read messages. To read a specific message, enter the number of the message and press ENTER. If you press ENTER with no argument, the mail utility assumes you want to read the next unread message. To delete a mail message, use the d command after reading the message, or use d# to delete the message numbered #.

Mail Group "Alias" Lists

If you have a distribution list of people for the same e-mail, you can set it up in the /etc/aliases file. By default, it's set up to forward e-mail from pseudo-accounts such as system and apache to root. You can change it by adding a group list similar to the following:

 groupname:  user01,  user02,  othergroupname 

You can then run the newaliases command to compile this database. Then all you need to do is name the group of users as addressees for your e-mail.

Using a Text and/or Graphical Browser to Access HTTP/HTTPs URLs

First, the prerequisite specifies the use of a text and/or graphical browser. RHEL 5 uses the Mozilla Firefox browser, known popularly as Firefox. This prerequisite should be trivial for any serious user of Linux. However, it's possible that you'll have access only to the command line interface during the Red Hat exams; therefore, you may want to learn how to use a text-based browser such as elinks. Once the package is installed, you can use it from the command line to open the Web site of your choice. For example, Figure 1-5 illustrates a view of www.osborne.com.

image from book
Figure 1-5: Using elinks

If you configure a Web server, the easiest way to make sure it works is with a simple text home page. No HTML coding is required. For example, if you added the following text to home.html:

 This is my home page 

you could then run the elinks home.html command to view this text in the elinks browser.

Using lftp to Access URLs

The original FTP client software was a basic command line, text-oriented client application that offered a simple but efficient interface. Most Web browsers offer a graphical interface and can also be used as an FTP client.

Any FTP client allows you to view the directory tree and files. Using FTP as a client is easy. You could use the ftp command to connect to a server such as ftp .redhat.com with the following command:

 # ftp ftp.redhat.com 

The FTP client listed in the Red Hat Exam Prep guide is lftp. You can use it to connect to the FTP server of your choice. It automatically attempts an anonymous login. It also supports command completion, which can especially help you access files and directories with longer names.

Figure 1-6 illustrates a typical lftp session to ftp.redhat.com. As you can see, lftp uses a number of typical bash commands. The command completion feature lists available subdirectories. I've navigated to the directory with RHEL 5 Source RPMs (RHEL Source RPMs are released to the public under the GPL-the GNU General Public License from www.fsf.org), and this doesn't require any subscription to the Red Hat Network.

image from book
Figure 1-6: Using lftp

Another advantage of lftp is that it can handle all of the basic upload and download commands of a regular FTP client. Some of these commands are described in Table 1-8.

Table 1-8: Standard lftp Client Commands

Command

Description

cd

Changes the current working directory at the remote host

ls

Lists files at the remote host

get

Retrieves one file from the remote host

mget

Retrieves many files from the remote host with wildcards or full filenames

put

Uploads one file from your computer to the remote host

mput

Uploads a group of files to the remote host

pwd

Lists the current working directory on the remote host

quit

Ends the FTP session

!ls

Lists files on your host computer in the current directory

lcd

Changes the local host directory for upload/download

!pwd

Lists the current working directory on the local host computer

Almost all commands from the FTP prompt are run at the remote host, similar to a Telnet session. To run a regular shell command on the local system, start the command with an exclamation point (!).

This is only a subset of the commands available through lftp. Typing the help command at the lftp prompt gives you a full list of the available commands. The command help cmd yields a brief description of the command itself.



RHCE Red Hat Certified Engineer Linux Study Guide (Exam RH302)
Linux Patch Management: Keeping Linux Systems Up To Date
ISBN: 0132366754
EAN: 2147483647
Year: 2004
Pages: 227
Authors: Michael Jang

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net