1.man
对于那些不确定其用法的命令(比如是:ls),我们可以首先使用man命令来了解
使用格式:man ls
可以使用空格键翻页,或者使用上、下箭头键上下翻页,要退出,则输入 q或 CTRL-Z。
2.find
如果您知道文件的名称、或者甚至名称的一部分,但不知道它所处的目录,可以使用find命令。比如你要找文件file,
命令格式:find / -name 'file'
3.ln
用于在文件之间建立链接
命令格式: ln [OPTION]... TARGET [LINK_NAME]
常用的[OPTION]:-s, --symbolic make symbolic links instead of hard links
执行这个命令之后,[LINK_NAME]-->TARGET,二者建立了链接关系,所有指向[LINK_NAME]的动作都会重新指向TARGET.
4.tar
tar是个归档命令,通过使用适当的选项可以压缩/解压缩文件.常见的如:
解压缩.gz文件: tar -zxf ZipFileName.tar.gz
解压缩.bz2文件: tar -jxf ZipFileName.tar.bz2
5.yum
#following from man page
NAME
yum - Yellowdog Updater Modified
SYNOPSIS
yum [options] [command] [package ...]
DESCRIPTION
yum is an interactive, automated update program which can be used for
maintaining systems using rpm
command is one of:
* install package1 [package2] [...]
* update [package1] [package2] [...]
* check-update
* upgrade [package1] [package2] [...]
* remove | erase package1 [package2] [...]
* list [...]
* info [...]
* provides | whatprovides feature1 [feature2] [...]
* clean [ packages | headers | metadata | cache | dbcache | all ]
* makecache
* groupinstall group1 [group2] [...]
* groupupdate group1 [group2] [...]
* grouplist
* groupremove group1 [group2] [...]
* groupinfo group1 [...]
* search string1 [string2] [...]
* generate-rss [updates]
Unless the --help or -h option is given, one of the above commands must
be present.
6. uname
检查你使用的内核版本
-a, --all
print all information, in the following order:
-s, --kernel-name
print the kernel name
-n, --nodename
print the network node hostname
-r, --kernel-release
print the kernel release
-v, --kernel-version
print the kernel version
-m, --machine
print the machine hardware name
-p, --processor
print the processor type
-i, --hardware-platform
print the hardware platform
-o, --operating-system
print the operating system
--help display this help and exit
--version
output version information and exit
参考资料:
Linux 文件命令精通指南(上)
Linux 系统命令精通指南(下)
对于那些不确定其用法的命令(比如是:ls),我们可以首先使用man命令来了解
使用格式:man ls
可以使用空格键翻页,或者使用上、下箭头键上下翻页,要退出,则输入 q或 CTRL-Z。
2.find
如果您知道文件的名称、或者甚至名称的一部分,但不知道它所处的目录,可以使用find命令。比如你要找文件file,
命令格式:find / -name 'file'
3.ln
用于在文件之间建立链接
命令格式: ln [OPTION]... TARGET [LINK_NAME]
常用的[OPTION]:-s, --symbolic make symbolic links instead of hard links
执行这个命令之后,[LINK_NAME]-->TARGET,二者建立了链接关系,所有指向[LINK_NAME]的动作都会重新指向TARGET.
4.tar
tar是个归档命令,通过使用适当的选项可以压缩/解压缩文件.常见的如:
解压缩.gz文件: tar -zxf ZipFileName.tar.gz
解压缩.bz2文件: tar -jxf ZipFileName.tar.bz2
5.yum
#following from man page
NAME
yum - Yellowdog Updater Modified
SYNOPSIS
yum [options] [command] [package ...]
DESCRIPTION
yum is an interactive, automated update program which can be used for
maintaining systems using rpm
command is one of:
* install package1 [package2] [...]
* update [package1] [package2] [...]
* check-update
* upgrade [package1] [package2] [...]
* remove | erase package1 [package2] [...]
* list [...]
* info [...]
* provides | whatprovides feature1 [feature2] [...]
* clean [ packages | headers | metadata | cache | dbcache | all ]
* makecache
* groupinstall group1 [group2] [...]
* groupupdate group1 [group2] [...]
* grouplist
* groupremove group1 [group2] [...]
* groupinfo group1 [...]
* search string1 [string2] [...]
* generate-rss [updates]
Unless the --help or -h option is given, one of the above commands must
be present.
6. uname
检查你使用的内核版本
-a, --all
print all information, in the following order:
-s, --kernel-name
print the kernel name
-n, --nodename
print the network node hostname
-r, --kernel-release
print the kernel release
-v, --kernel-version
print the kernel version
-m, --machine
print the machine hardware name
-p, --processor
print the processor type
-i, --hardware-platform
print the hardware platform
-o, --operating-system
print the operating system
--help display this help and exit
--version
output version information and exit
参考资料:
Linux 文件命令精通指南(上)
Linux 系统命令精通指南(下)