首页 » 操作系统 » linux man page 命令手册

linux man page 命令手册

 

Linux提供了丰富的帮助手册,当你需要查看某个命令的参数时不必到处上网查找,只要man一下即可。
Linux的man手册共有以下几个章节:

1 Executable programs or shell commands
2 System calls (functions provided by the kernel)
3 Library calls (functions within program libraries)
4 Special files (usually found in /dev)
5 File formats and conventions eg /etc/passwd
6 Games
7 Miscellaneous (including macro packages and conventions), e.g. man(7), groff(7)
8 System administration commands (usually only for root)
9 Kernel routines [Non standard]

中文翻译:

章节号 代表内容
1 使用者在shell中可以操作的指令或可执行档
2 系統核心可呼叫的函数与工具等
3 一些常用的函数(function)与函数库(library),大部分是C的函数库(libc)
4 装置档案的说明,通常在/dev下的档案
5 设定档或者是某些档案的格式
6 游戏(games)
7 惯例与协定等,例如Linux档案系统、网络协定、ASCII code等等的說明
8 系統管理員可用的管理指令
9 跟kernel有关的文件

man命令的使用方式:
第一种方式:man 命令名称 如: man ls
第二种方式:man 章节号 命令名称 man 8 ifconfig

man命令是的搜索顺序:
man是按照手册的章节号的顺序进行搜索的,比如:
man sleep
只会显示sleep命令的手册,如果想查看库函数sleep,就要输入:
man 3 sleep

man命令内容简要说明:
我们输入命令 man pwd。 会显示pwd命令的相关内容。内容的第一行内容如下:
PWD(1) User Commands PWD(1)
现在我们说下第一行左边的PWD(1)的含义。
PWD是手册名称
(1)表示在第一章节。

技术交流

原文链接:linux man page 命令手册,转载请注明来源!

原文链接:linux man page 命令手册,转载请注明来源!

1