Bookmark this page

Chapter 3. Getting Help in Red Hat Enterprise Linux

Abstract

Goal To resolve problems by using on-line help systems and Red Hat support utilities.
Objectives

  • Use the man Linux manual reader.

  • Use the pinfo GNU Info reader.

  • Use the Red Hat Package Manager (RPM) package documentation.

  • Use the redhat-support-tool command.

Sections
  • Reading Documentation Using man Command (and Practice)

  • Reading Documentation Using pinfo Command (and Practice)

  • Reading Documentation in /usr/share/doc (and Practice)

  • Getting Help From Red Hat (and Practice)

Lab
  • Viewing and Printing Help Documentation

Reading Documentation Using man Command

An overview of the Linux manual in man page format, including efficient navigation and searching.

Objectives

After completing this section, students should be able to locate documentation and research answers about commands.

Introducing the man command

Reading documentation using man command

The historical Linux Programmer's Manual, from which man pages originate, was large enough to be multiple printed books. Each contained information for specific types of files, which have become the sections listed below. Articles are referred to as topics, as pages no longer applies.

Table 3.1. Sections of the Linux manual

Section

Content type

1

User commands (both executable and shell programs)

2

System calls (kernel routines invoked from user space)

3

Library functions (provided by program libraries)

4

Special files (such as device files)

5

File formats (for many configuration files and structures)

6

Games (historical section for amusing programs)

7

Conventions, standards, and miscellaneous (protocols, file systems)

8

System administration and privileged commands (maintenance tasks)

9

Linux kernel API (internal kernel calls)


Note

Manual section 9 is a recent addition to Linux. Not all man section listings reference it.

To distinguish identical topic names in different sections, man page references include the section number in parentheses after the topic. For example, passwd(1) describes the command to change passwords, while passwd(5) explains the /etc/passwd file format for storing local user accounts.

To read specific man pages, use man topic. Topic contents display one screen at a time. Use arrow keys for single line scrolling or the space bar for the next screen. The man command searches manual sections in a configured order, displaying popular sections first. For example, man passwd displays passwd(1) by default. To display the man page topic from a specific section, include the section number argument: man 5 passwd displays passwd(5).

Navigate and search man pages

The ability to efficiently search for topics and navigate man pages is a critical administration skill. The following table lists basic man navigation commands:

Table 3.2. Navigating man pages

CommandResult
SpacebarScroll forward (down) one screen
PageDownScroll forward (down) one screen
PageUpScroll backward (up) one screen
DownArrowScroll forward (down) one line
UpArrowScroll backward (up) one line
dScroll forward (down) one half-screen
uScroll backward (up) one half-screen
/stringSearch forward (down) for string in the man page
nRepeat previous search forward (down) in the man page
NRepeat previous search backward (up) in the man page
gGo to start of the man page.
GGo to end of the man page.
qExit man and return to the command shell prompt

Important

When performing searches, string allows regular expression syntax. While simple text (such as passwd) works as expected, regular expressions use meta-characters (such as $, *, ., and ^) for more sophisticated pattern matching. Therefore, searching with strings which include program expression meta-characters, such as make $$$, might yield unexpected results.

Regular expressions and syntax are discussed in Red Hat System Administration II, and in the regex(7) man topic.

Searching for man pages by keyword

A keyword search of man pages is performed using man -k keyword, which displays a list of keyword-matching man page topics with section numbers.

[student@desktopX ~]$ man -k passwd
checkPasswdAccess (3) - query the SELinux policy database in the kernel.
chpasswd (8)          - update passwords in batch mode
ckpasswd (8)          - nnrpd password authenticator
fgetpwent_r (3)       - get passwd file entry reentrantly
getpwent_r (3)        - get passwd file entry reentrantly
...
passwd (1)            - update user's authentication tokens
sslpasswd (1ssl)      - compute password hashes
passwd (5)            - password file
passwd.nntp (5)       - Passwords for connecting to remote NNTP servers
passwd2des (3)        - RFS password encryption
...

Popular system administration topics are in sections 1 (user commands), 5 (file formats), and 8 (administrative commands). Administrators using certain troubleshooting tools also use section 2 (system calls). The remaining sections are commonly for programmer reference or advanced administration.

Note

Keyword searches rely on an index generated by the mandb(8) command, which must be run as root. The command runs daily through cron.daily, or by anacrontab within an hour of boot if out of date.

Important

The man command -K option performs a full-text page search, not just titles and descriptions like the -k. A full-text search can use greater systems resources and take more time.

References

man(1), mandb(8), man-pages(7), less(1), intro(1), intro(2), intro(5), intro(7), intro(8) man pages

Revision: rh124-7-1b00421