作者:技术交流 | 来源:互联网 | 2017-10-21 20:59
几乎所有的 linux系统都有man的存在,man中几乎包含了所有使用系统或进行开发的帮助文档(有些可能不太完整需要自行安装)但基本帮助文档都已包含。Man是分区段显示的,查找不同区段显示的内容可能不相同。如man sleep 和man 3 sleep会出现不同的结果。加上3就会显示第3区段的内容也就是库函数中的sleep,但在sleep的man中会有see also提示你还有那个章节与当前查询内容有些联系.具体各区段清单如下:
Executable programs or shell commands(一般的可执行程序和shell命令)
System calls (functions provided by the kernel) (系统调用)
Library calls (functions within program libraries) (库函数)
Special files (usually found in /dev) (特殊文件...设备)
File formats and conventions eg /etc/passwd (文件组成格式和习惯)
Games (游戏)
Miscellaneous (including macro packages and conven?
tions), e.g. man(7), groff(7) (其它杂项)
System administration commands (usually only for root)(管理员命令)
Kernel routines [Non standard] (内核指令)
可以用“man man” 来查看man的选项及其用法,“man 命令”来查看该命令具体用法或用“man -k keyword”来通过keyword来查找相应的帮助信息。