find

Dennis G. Rears FSAC drears at pica.army.mil
Wed Dec 13 04:25:50 AEST 1989


Sim:

   You write:

>
> Can anyone explain what's the difference between atime, mtime,
>  ctime?
>  

atime - The last time the file was read or modified.  The system
calls creat(2), mknod(2), utimes(2), read(2), and write(2) will affect the
atime value.

mtime - The last time the contents of the file was modified.  The
systems calls creat(2), mknod(2), utimes(2), and write(2) affect the
mtime value.  Open(2) will if called with the O_WRONLY flag.

ctime - The last time information about the file was changed or the
file was written to.  This is affected by systems calls like chmod(2),
chown(2), creat(2) link(2), mknod(2), unlink(2), utimes(2), and write(2).


   If the file is a directory atime is not modified when the
directory is searched.  On some occasions atime will not be modified
when the file is written to. (Zample: ULTRIK -> echo "
">>filename).  Read the manual page for stat.  That explains it
pretty well.

Dennis
  



More information about the Comp.unix.questions mailing list