man stands for manual, it teaches you how to use the commands available in Linux with full information for user's reference.
In this context, we shall look into how to check the manual by using the man command in Linux.
What is the syntax of man command ?
It is given below:
$ man [option]... [command]...
Its Options is explained below:
1. No option: show command manual:
$ man [command]
For example, If you want to see the manual of the mkdir command, then run the below command:
$ man mkdir
2. num: specifies the display of a specific section of the manual:
$ man [num] [command]
For example, If you want to show part 2 of the mkdir command, execute:
$ man 2 mkdir
3. -f: show function of command:
$ man -f [command]
For example, If you want to show the function of the cat command, execute:
$ man -f cat
4. -a: show all manual intro:
$ man -a [command]
$ man -a intro
5. -k: searches for the specified command as a regular expression:
$ man -k [command]
$ man -k ls
6. -w: returns the position of the command:
$ man -w [command]
$ man -w mkdir
[Need to fix any Linux System issue? We can help you. ]
This article covers how to use the man command in Linux. In fact, the man command allows users to view the reference manuals of a command or utility run in the terminal. The man page (short for manual page) includes a command description, applicable options, flags, examples, and other informative sections.
How to Enable Case-Sensitivity using man command ?
To search for manual pages using case-sensitivity, use the -I option. The syntax is:
$ man -I [command name]
The man default setting is to ignore case when looking up manual pages. To go back to default settings and ignore case, use the -i option.
How to Use man in Linux ?
In the terminal window, type man followed by the Linux command name which man page you want to see.
The output of the command displays the available man page headings for the specified command.
The list of possible headings includes:
- Name: The name of the command.
- Synopsis: The command's syntax.
- Configuration: Configuration details for a device.
- Description: A description of the command.
- Examples: Several examples demonstrating the use of the command.
- Defaults: The default functions of the command and how they can be overridden.
- Options: A list of options and flags that the command accepts.
- Exit Status: A list of possible exit status values for the command.
- Environment: A list and description of environment variables that affect the command.
- Files: A list of files used by the command.
- See also: Commands related to the described topic.
- Authors: The people who wrote or maintain the command.
- History: Command development history.
- Notes: Various notes, including permissions required, dependencies, etc.
- Bugs: Any known issues in this program version.