Linux Know-How provides a collection of introductory texts on often needed Linux skills.


Is there a help command?

Most Linux commands can be run with the "--help" option. For example, this command will give you concise help on the Linux cp (copy) command:

cp --help | less

More extensive info is accessed from the command line using the so-called manual pages man topic. For example:

man cp

will display the manual page for the "cp" (copy) command. The manual pages are the standard "help" system under Linux, and contain a wealth of detailed, very technical information, but typically require some effort to be understood by a newbie.

The man command uses a simple utility called less that lets you scroll through a text. Use arrow keys to scroll, press "q" to quit. Actually, less can do more than this. Press "h" for help when running less, or learn more about less using the command

man less

There is also the info command info topic. For example:

info cp

will give you the help for the "cp" (copy) command. Often info contains information similar to man, but more up-to-date. Unfortunately, the info navigating utility is not very intuitive, so I use man pages more often. There is also pinfo (a substitute for the info interface, perhaps easier to use than info).

If you don't remember exactly the name of the command that you need to use, try apropos. For example, to obtain a list of commands which have something to do with "copy", I execute this from the command line:

apropos copy

The command whatis is similar to apropos, but matches only keywords, whereas apropos searches the complete database (keywords and their description). As a result, whatis tends to produce a shorter (perhaps more relevant) output.

In some menu driven programs, for example when configuring your system services using ntsysv (or setup, or linuxconf), you may press F1 for info about what the particular service does.

The list of bash built-in commands can be obtained by typing help on the command line. Then help on any specific bash built-in command can be obtained by issuing, for example:

help cd

Bash is the standard command line "shell", i.e., the Linux equivalent of the DOS command-line processor "COMMAND.COM".

The KDE environment includes a GUI-based "help browser", which can be started by clicking the appropriate icon on the "Kpanel" (the system bar, normally at the bottom of the screen). This browser can be used to access the KDE-specific help as well as the system manual pages. The Gnome desktop contains a similar help system.

If you want to learn about the many packages that come on your CDs in rpm format, you may want to use the GUI-based kpackage (type kpackage in an X-terminal) to browse through the packages, display the info that they contain, and install them if you wish (the installation has to be done as root). In place of kpackage, older distributions use glint (RH5.2) or gnorpm (RH6.0), which are slower and less convenient.


Last Update: 2010-12-16