Six methods for getting Linux command help

Source: Internet
Author: User
Getting help is the first command to be mastered in Linux. Linux provides very detailed help tools and documents, so you must get into the habit of checking help documents (there is no need to remember everything ), this greatly reduces memory and improves efficiency.

I. help Command
Applicable to internal commands
Example:

Copy codeThe code is as follows: # type cd
Cd is a shell builtin
# Help cd
# Type ls
Ls is aliased to 'ls -- color = auto'
# Help ls
-Bash: help: no help topics match 'Ls'. Try 'help help' or 'man-k LS' or 'info ls '.
II. Command-help/-h
Applicable to external commands
For example:

Copy codeThe code is as follows:
# Ls -- help
3. man Command

Example:

Copy codeThe code is as follows:
# Man cd

Note: manual manuals are divided into chapters; man # Command (# indicates the chapter number)
1. commands available to all users
2. system kernel call. not every command has a system call (for example, man 2 read)
3. database call
4. special files, such as/dev/tty1
5. file format (command configuration file syntax, such as man 5 passwd)
6. game problems
7. Miscellaneous
8. administrator commands, such as fdisk

For man command query operations, refer to the command mode in vi, vim usage

Understand man command syntax
[]: Optional
<>: Required content
A | B | c: select one more
... : There can be multiple

IV. info Command
There is a hyperlink to the document. info is the information page, providing the Author, version, and when to release more detailed information. man manual tells you how to use it.

V. README
Most programs have corresponding help documents stored in the/usr/share/doc folder.
For example:

# Ls/usr/share/doc/ntp-4.2.4p8/
ChangeLog COPYRIGHT NEWS
6. Google
If you have any questions, refer to the official project documents first.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.