惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Schneier on Security
F
Fortinet All Blogs
B
Blog
GbyAI
GbyAI
P
Proofpoint News Feed
量子位
The Register - Security
The Register - Security
宝玉的分享
宝玉的分享
大猫的无限游戏
大猫的无限游戏
云风的 BLOG
云风的 BLOG
V
Visual Studio Blog
B
Blog RSS Feed
WordPress大学
WordPress大学
Recorded Future
Recorded Future
Recent Announcements
Recent Announcements
V
Vulnerabilities – Threatpost
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
S
Secure Thoughts
雷峰网
雷峰网
Stack Overflow Blog
Stack Overflow Blog
C
Cybersecurity and Infrastructure Security Agency CISA
Webroot Blog
Webroot Blog
AWS News Blog
AWS News Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
The GitHub Blog
The GitHub Blog
爱范儿
爱范儿
O
OpenAI News
月光博客
月光博客
H
Hacker News: Front Page
S
Security Affairs
W
WeLiveSecurity
The Hacker News
The Hacker News
aimingoo的专栏
aimingoo的专栏
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Help Net Security
Help Net Security
MongoDB | Blog
MongoDB | Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
D
Docker
T
The Blog of Author Tim Ferriss
Spread Privacy
Spread Privacy
Blog — PlanetScale
Blog — PlanetScale
J
Java Code Geeks
S
Securelist
Microsoft Azure Blog
Microsoft Azure Blog
TaoSecurity Blog
TaoSecurity Blog
T
Threat Research - Cisco Blogs
M
MIT News - Artificial intelligence
A
About on SuperTechFans

博客园 - 刘伟_luvi

C项目错误情况小记 s3c2440设置从nfs或从board启动 Hash Functions for Hash Table Lookup 自写linux下的简单man帮助文件 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘<’ token C数组测试 - 刘伟_luvi - 博客园 在本地计算机无法启动MySQL服务。错误1067:进程意外终止 嵌入式中地址-函数之间的转换 对C语言中结构体的测试分析 悄悄地,你走了 AMBA片上总线 Linux系统环境下的Socket编程详细解析 C语言宏定义技巧(常用宏定义)【转】 s3c2410 MMU详述 可重入函数与不可重入函数(转) 程序的书写规则(程序的编码规范) ARM中C和汇编混合编程及示例 嵌入式系统 Boot Loader 技术内幕(转) 关于Linux系统下网卡手写配置文件的介绍
Linux MAN命令
刘伟_luvi · 2008-10-10 · via 博客园 - 刘伟_luvi

(1)所有的手册页都属于一个特定的领域,用一个字符来表示。

Linux下最通用的领域及其名称及说明如下:

领域 名称 说明

1 用户命令, 可由任何人启动的。

2 系统调用, 即由内核提供的函数。

3 例程, 即库函数。

4 设备, 即/dev目录下的特殊文件。

5 文件格式描述, 例如/etc/passwd。

6 游戏, 不用解释啦!

7 杂项, 例如宏命令包、惯例等。

8 系统管理员工具, 只能由root启动。

9 其他(Linux特定的), 用来存放内核例行程序的文档。

n 新文档, 可能要移到更适合的领域。

o 老文档, 可能会在一段期限内保留。

l 本地文档, 与本特定系统有关的。

例如:man ls就会有LS(1)

(2)man的一些常用参数和用法

man -a cmd

打开所有领域内的同名帮助,例如 man fam ,你首先会进入一个fam(1M)的命令版fam帮助,你再按q键

就会进入FAM(3X),库函数版的帮助

man -aw cmd

显示所有cmd的所有手册文件的路径,如 man -aw fam 就是

/usr/share/man/man1/fam.1m.gz

/usr/share/man/man3/fam.3x.gz

man 领域代号 cmd

直接指定特定领域内搜索手册页,如 man 3 fam 直接进入库函数版的帮助

man -M cmd

指定手册文件的搜索路径,如 man -M /home/mysql/man mysql 显示的就是你安装的mysql的帮助,

而不是系统自带的旧版mysql的帮助

man cmd| col -b > cmd.txt

把man手册信息输出到文本文件

LANG=语言代号

man -w cmd

man 特定语言manpage文件的路径

查看特定语言版本的手册页

例如,要查看mplayer的中文man

shell> LANG=zh

shell> man -w mplayer

/usr/share/man/zh/man1/mplayer.1.gz

新开一个shell窗口(或在原窗口 shell> LANG=en_US.UTF-8)

shell> man /usr/share/man/zh/man1/mplayer.1.gz

(3)man的配置文件/etc/man.config

如果你不想每次man cmd都要用-M指定路径,那么可以通过修改配置文件,添加内容如

MANPATH /home/mysql/man

man在各领域的搜索次序可以通过修改

MANSECT 1:8:2:3:4:5:6:7:9:tcl:n:l:p:o

实现,一般不推荐修改。