Access, Modify, Change Time of Linux File

All these 3 time can be viewed by "stat " command.

Access time is influenced by read operation, such as command cat, more, less, head, tail, grep, sed, etc. This time is queried by "find . -atime -1", and can be set by "touch -a" command;

Change time is the time when inode is changed, which influenced by command mv, chmod, chown, etc;

Modification time is the time the content of the file changed, and be listed by "ls -l" command. It‘s influenced by command vi, etc, and can be set by "touch -m" command;

"touch -t" set access and modification time to the specified time;

Creation time is not saved. So it‘s impossible to query files according to creation time;

Ref:

Linux文件的??access time,change time,modify time

http://stackoverflow.com/questions/14842195/how-to-get-file-creation-date-time-in-bash-debian

Access, Modify, Change Time of Linux File,古老的榕树,5-wow.com

郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。