Linux 命令全称是 “GNU/Linux”,”GNU” 代表 GNU’s Not Unix,是一种自由软件操作系统,而 “Linux” 是指由 Linus Torvalds 开发的内核。
Linux命令是操作系统中最基本且强大的工具之一,掌握这些命令对于系统管理员和普通用户来说都非常重要,本文将详细介绍一些常用的Linux命令及其全称和功能,以便更好地理解和使用它们。
文件和目录操作
命令 |
中文名称 |
英文全称 |
ls |
列出文件和目录 |
List files and directories |
cd |
切换当前目录 |
Change directory |
pwd |
显示当前工作目录 |
Print working directory |
cp |
复制文件和目录 |
Copy file or directory |
mv |
移动文件和目录 |
Move file or directory |
rm |
删除文件和目录 |
Remove file or directory |
mkdir |
创建目录 |
Make directory |
rmdir |
删除空目录 |
Remove empty directory |
touch |
创建空文件或更新文件时间戳 |
Touch file or update timestamp |
命令 |
中文名称 |
英文全称 |
cat |
显示文件内容 |
Concatenate and display file contents |
less |
分页显示文件内容 |
Display file contents, one page at a time |
more |
分页显示文件内容 |
Display file contents, one page at a time (older version) |
head |
显示文件头部内容 |
Display the first part of a file |
tail |
显示文件尾部内容 |
Display the last part of a file |
grep |
在文件中搜索匹配模式的文本 |
Global regular expression print |
find |
查找文件和目录 |
Find files and directories |
权限和所有权管理
命令 |
中文名称 |
英文全称 |
chmod |
更改文件和目录的权限 |
Change mode/permissions |
chown |
更改文件和目录的所有者 |
Change owner |
chgrp |
更改文件和目录的所属组 |
Change group |
压缩和归档
命令 |
中文名称 |
英文全称 |
tar |
打包和解包文件和目录 |
Tape archive |
gzip |
压缩文件 |
GNU zip compression |
gunzip |
解压缩文件 |
GNU unzip decompression |
系统状态和进程管理
命令 |
中文名称 |
英文全称 |
top |
显示系统资源使用情况 |
Top system resource monitor |
ps |
显示进程状态 |
Process status |
kill |
终止进程 |
Kill process |
uptime |
显示系统运行时间和负载 |
Uptime and load averages |
df |
显示磁盘使用情况 |
Disk free space |
du |
显示目录或文件的磁盘使用情况 |
Disk usage |
网络相关
命令 |
中文名称 |
英文全称 |
ifconfig |
显示网络接口信息 |
Internet interface configuration |
netstat |
显示网络连接和统计信息 |
Network statistics |
ip |
显示和配置网络接口信息 |
Internet protocol settings |
ping |
测试网络连接是否正常 |
Packet interNet groper |
scp |
在本地主机和远程主机之间复制文件 |
Secure copy protocol |
ssh |
在本地主机和远程主机之间建立安全连接 |
Secure shell |
系统服务和日志管理
命令 |
中文名称 |
英文全称 |
systemctl |
系统服务管理命令 |
System control manager |
journalctl |
系统日志查询和管理命令 |
Journal control tool |
用户和组管理
命令 |
中文名称 |
英文全称 |
passwd |
修改用户密码 |
Change user password |
useradd |
添加新用户 |
Add new user account |
userdel |
删除用户 |
Delete user account |
usermod |
修改用户信息 |
Modify user account details |
groupadd |
添加新用户组 |
Add new group account |
groupdel |
删除用户组 |
Delete group account |
groupmod |
修改用户组信息 |
Modify group account details |
常见问题与解答(FAQ)

Q1:ls
命令中的-l
选项有什么作用?
A1:ls -l
命令用于以长格式列出文件和目录的详细信息,包括权限、所有者、大小、最后修改时间等,这对于查看文件属性非常有用。

Q2:grep
命令如何进行递归搜索?
A2:grep -r
或grep --recursive
命令用于在所有子目录中递归地搜索指定模式的文本。grep -r 'pattern' /path/to/directory
将在指定目录及其所有子目录中搜索包含"pattern"的行。

小伙伴们,上文介绍了“linux 命令全称”的内容,你了解清楚吗?希望对你有所帮助,任何问题可以给我留言,让我们下期再见吧。