Shell中find中的atime、ctime、mtime的区别

find用法:


-atime n File was last accessed n*24 hours ago. 访问(读取文件或执行文件)

-ctime n File’s status was last changed n*24 hours ago. 写入修改 更改属主

-mtime n File’s data was last modified n*24 hours ago. 文件状态被修改

-amin n File was last accessed n minutes ago. 这是按分钟来算的一般不用

-cmin n File’s status was last changed n minutes ago.

关于+n还是-n:


+n for greater than n, #N天以外的,N天前的

-n for less than n #N天以内的

n for exactly n #正好的
# find . -ctime 6   表示刚好第6天
# find . -ctime +6  表示第6天以外
# find . -ctime -6  表示第6天以内

相关文章:

  • 2021-06-21
  • 2021-12-19
  • 2021-05-14
  • 2021-08-20
  • 2021-09-29
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-09-20
  • 2021-11-17
  • 2022-02-10
  • 2021-06-09
相关资源
相似解决方案