1.1    Linux中的时间分为三种

1.mtimemodify time   修改时间,文件/目录的修改时间,文件内容修改

2.ctimechange time     改变时间,文件/目录的属性的变化,修改时间,大小,硬链接数,权限,所有者,所属组,类型

3.atimeaccess time      访问时间,文件/或目录的访问时间,查看文件之后,内容没变化之前再次访问的话,访问时间不变化

使用stat查看文件详细信息

[root@qizhong tmp]# stat test.txt

  File:`test.txt'

  Size:0          Blocks: 0          IO Block:4096   regular empty file

Device: 803h/2051d Inode:398305      Links: 1

Access: (0644/-rw-r--r--)  Uid: (   0/    root)   Gid: (   0/    root)

Access: 2017-07-29 15:02:22.478435838 +0800           ##访问时间

Modify: 2017-07-29 15:02:22.478435838 +0800           ##修改时间

Change: 2017-07-29 15:02:22.478435838 +0800           ##改变时间

[root@qizhong tmp]# echo 1 >test.txt

[root@qizhong tmp]# stat test.txt

  File:`test.txt'

  Size:2          Blocks: 8          IO Block:4096   regular file

Device: 803h/2051d Inode:398305      Links: 1

Access: (0644/-rw-r--r--)  Uid: (   0/    root)   Gid: (   0/    root)

Access: 2017-07-29 15:02:22.478435838 +0800

Modify: 2017-07-29 15:03:09.540436756 +0800

Change: 2017-07-29 15:03:09.540436756 +0800

[root@qizhong tmp]# cat test.txt

1

[root@qizhong tmp]# stat test.txt

  File:`test.txt'

  Size:2          Blocks: 8          IO Block:4096   regular file

Device: 803h/2051d Inode:398305      Links: 1

Access: (0644/-rw-r--r--)  Uid: (   0/    root)   Gid: (   0/    root)

Access: 2017-07-29 15:03:30.688435443 +0800

Modify: 2017-07-29 15:03:09.540436756 +0800

Change: 2017-07-29 15:03:09.540436756 +0800

[root@qizhong tmp]#




<>>新手,请多多指教<><><><><><><><><><><><<><><><><><><><><><><><>>