[Gllug] what is causing disk activity ?

Peter Corlett abuse at cabal.org.uk
Thu Nov 20 17:43:15 UTC 2008


On Thu, Nov 20, 2008 at 12:04:14PM -0500, Andrew Farnsworth wrote:
[...]
> Out of curiosity, does reading the last access time of a file update the
> access time of that file? and if so, does it update before or after the
> atime is read?

No. One could argue that it's because you're accessing the inode rather than
the file, but really it just comes down to whether it's useful or not. And
it's not at all useful to bump the atime when merely doing a stat() on the
file.

Updating beforehand would be particularly useless as it'd just be an
expensive gettimeofday().

-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list