Learn to use the view of Help files and learn basic commands by helping commands

Source: Internet
Author: User

Access to Linux command help:

Internal command:
# Help COMMAND
External command:
(1) Simple help with the command
# COMMAND--help
# command-h
(2) Command manual page
# Man [Chpater] KEYWORD
(3) Information page
# info COMMAND
(4) Help documentation for the program itself
README, INSTALL, change
(5) Documentation provided by the program
(6) Official documentation provided by the release version
Http://www.redhat.com/docs
(7) Google

Use of the Man Handbook:
/usr/share/man/
Man1, ..., man9
Man1: User command;
MAN2: System call;
MAN3:C library call;
MAN4: Equipment files and special documents;
MAN5: Configuration file format;
Man6: Game;
Man7: Miscellaneous;
MAN8: Management command;

The man may also store other paths:
Configuration file for man command:/etc/man.config
MANPATH

Man unzip its help manual to a temporary directory, and then calls the less command to display the contents of the file;

Paragraphs in the         Help manual:
             NAME
            Synopsis
             DESCRIPTION
             OPTIONS
             EXAMPLES
            AUTHOR
             See ALSO

Synopsis:
[]: Optional
<>: Required
A|b: Two Choose one
...: Similar content can appear multiple times

How to operate the man command:
Space: Turn a screen at the end of the file;
B: Turn the file to the first screen;
D: half-screen to the tail of the file;
U: Turn half screen to file header;
Return: Flip a line to the end of the file;
K or y: Flip a line to the file header;

#: Quick go to # line;
1 G: Return to the first line;
G: to the last line;

Q: Exit;

Exercise: 1. Get the use format of the date command:
Answer: Man date

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; margin:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M01/72/4C/ Wkiol1xglawwrhcoaaat3rorn2c897.jpg "width=" 244 "height=" "/>

2. What is the day of the week?

Answer: Date +%a

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; margin:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M02/72/4C/ Wkiol1xglaxx0343aaanhylv5kk172.jpg "width=" 244 "height="/>

3. Set the current system time?

Date–s 16:24:30

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; margin:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M00/72/4C/ Wkiol1xglaaixypkaaaos1fubu4122.jpg "width=" 244 "height=" "/>
4. Set the current system date?

Date 08282015

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; margin:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M01/72/4C/ Wkiol1xglaaikivjaaa3dmrryug955.jpg "width=" 244 "height=" "/>"

CentOS 7:timedatectl command to view and set the time?
Answer: 1) View time TIMEDATECTL status

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; margin:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M01/72/4C/ Wkiol1xglaet5wroaabthzfxcvg341.jpg "width=" 244 "height=" 111 "/>

2) Set time Timedatectl set-time 19:30:20

650) this.width=650; "title=" image "style=" border-left-0px; border-right-width:0px; Background-image:none; border-bottom-width:0px; padding-top:0px; padding-left:0px; padding-right:0px; border-top-width:0px "border=" 0 "alt=" image "src=" http://s3.51cto.com/wyfs02/M01/72/4F/ Wkiom1xgk47ymjrxaabkpv5wvxs650.jpg "width=" 244 "height=" 126 "/>

Learn to use the view of Help files and learn basic commands by helping commands

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.