zoukankan      html  css  js  c++  java
  • ls

    ls:显示当前目录下文件
        -l:长格式

        -h:做单位转换

        -a:显示以.开头的隐藏文件
            .表示当前目录
            ..表示父目录


        -A:显示所有隐藏文件不包含..
        -d:显示目录自身属性

        -i:inode索引节点号

        -r:逆序显示
        -R:递归显示,就是在搜索的路径下找遍每个文件夹(recursive)

     -i:显示文件或目录的inode号

    [root@bogon admin]# ls -li /
    total 94
     12090 -rwxrwxrwx.   2 root root     0 Dec 22 00:55 a
        13 dr-xr-xr-x.   2 root root  4096 Aug 24 04:21 bin
         2 dr-xr-xrwx.   5 root root  1024 Nov 14 23:40 boot
    391681 drwxr-xr-x.   2 root root  4096 Jul 14  2010 cgroup
         4 drwxr-xr-x.  17 root root  3720 Dec 21 18:45 dev
    522242 drwxr-xr-x.  98 root root  4096 Dec 21 18:59 etc
    130563 drwxr-xr-x.  12 root root  4096 Sep 29 00:29 home
    261127 dr-xr-xr-x.  10 root root  4096 Aug 24 03:32 lib
    261124 dr-xr-xr-x.   9 root root 12288 Aug 24 04:21 lib64
        11 drwx------.   2 root root 16384 Aug 24 03:30 lost+found
        14 drwxr-xr-x.   2 root root  4096 Dec  4  2009 media
    130564 drwxr-xr-x.   3 root root  4096 Aug 24 03:36 mnt
        15 drwxr-xr-x.   2 root root  4096 Aug 24 03:37 opt
         1 dr-xr-xr-x. 147 root root     0 Dec 21 18:44 proc
    652802 dr-xr-x---.  25 root root  4096 Dec  5 00:19 root
    130565 dr-xr-xr-x.   2 root root 12288 Aug 24 04:21 sbin
         1 drwxr-xr-x.   7 root root     0 Dec 21 18:44 selinux
        16 drwxr-xr-x.   3 root root  4096 Sep 29 00:30 srv
         1 drwxr-xr-x.  13 root root     0 Dec 21 18:44 sys
    261122 drwxrwxrwt.  14 root root  4096 Dec 22 01:05 tmp
    652805 drwxr-xr-x.  13 root root  4096 Aug 24 03:30 usr
    783361 drwxr-xr-x.  22 root root  4096 Aug 24 03:33 var
    
      文件类型:
                    -:普通文件
                    d:目录文件
                    b:块设备文件(block)
                    c:字符设备文件(character)
                    l:符号链接文件(symboliclink file)
                    p:命令管道文件(pipe)
                    s:套接字文件(socket)
            -rw-r--r--. 1 root root 173 Sep  6 00:30 a
            文件权限:9位,每3位一组,每一组:rwx(读,写,执行)
            文件硬链接的次数
            文件的属主(owner)
            文件的属组(group)
            文件大小(size):单位是字节
            时间戳(timestamp):最近一次被修改的时间
                访问:access
                修改:modify
                改变:change,metadata,元数据
            文件名



    初学linux,每学到一点东西就写一点,如有不对的地方,恳请包涵!
  • 相关阅读:
    绕开安全沙箱跨域调用Swf中的方法
    使用Eclipse运行Java代码调用JDBC读写MySQL中文变成问号的终极解决办法
    Resource is out of sync with the file system的解决办法
    DBUnit入门
    Eclipse 中JSP文件出现String cannot be resolved as a type的解决办法
    Windows中cmd操作mysql
    windows中 关闭 启动 重启mysql的方法
    Mysql中文输入出现1366错误的解决办法
    How to implement collapse all in windows tree structure such as regedit
    word2010 2007中去掉页眉上的横线
  • 原文地址:https://www.cnblogs.com/forlive/p/8084372.html
Copyright © 2011-2022 走看看