首页 > 系统服务 > 详细

linux 系统结构以及命令

时间:2017-10-19 17:31:06      阅读:297      评论:0      收藏:0      [点我收藏+]

1.目录结构

------------------------------

/ 根目录

~ 当前用户主目录

. 当前目录

.. 上一级目录

root@localhost /]#

--------------------------------

栗子:

[saber@localhost ~]$   #刚进入用户终端Terminal,saber代表普通用户,localhost代表本机,~代表当前用户主目录

[saber@localhost ~]$ cd .        #当前目录用.
[saber@localhost ~]$ pwd
/home/saber

[saber@localhost ~]$ cd ..        #上一级目录目录..
[saber@localhost home]$ pwd
/home

[saber@localhost home]$ cd ~    #当前用户主目录~
[saber@localhost ~]$ pwd
/home/saber

[saber@localhost ~]$ su            #进入root管理员权限,但是目录不改变
Password: 
[root@localhost saber]# cd .
/home/saber

[root@localhost saber]# cd ~     #当前用户主目录~
[root@localhost ~]# cd ..

[root@localhost /]#                     #根目录/
[root@localhost /]# pwd
/

[root@localhost /]# cd ~
[root@localhost ~]# pwd
/root

        

2.一些常用命令

  pwd   #查看绝对路径

  file filename        #查看file文件属性

  ls   #查看当前目录下的所有文件,list的简写

  ls -R   #递归显示子目录文件

  ls -la    列出所有文件,包括隐藏文件

  ls -l      列出所有文件,并显示其属性。

 

linux 系统结构以及命令

原文:http://www.cnblogs.com/saber-himesama/p/7693549.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!