1. cd 命令
cd 是切换目录的命令直接cd 空格直接加你想要进的目录直接就可以进去。
cd /etc
cd 切换到当前用户的家目录下
[root@localhost etc]# cd
[root@localhost ~]#
cd - 切换到上次所在的目录
[root@localhost ~]# cd /etc
[root@localhost etc]# cd -
/root
cd .. 切换到上级目录
[root@localhost ~]# cd ..
[root@localhost /]#
cd ~ 切换到当前用户的家目录下
[root@localhost etc]# cd ~
[root@localhost ~]#
cd ../.. 切换到上两级目录
[root@localhost etc]# cd ../..
[root@localhost /]#
2. ls 命令
ls -l 显示文件或者目录的详细信息 ls -l 等价于 ll
[root@localhost etc]# ls -l
总用量 1400
drwxr-xr-x. 3