[issue1308] hammer: stat returns wrong time when using tids

Matthew Dillon dillon at apollo.backplane.com
Fri Mar 6 20:19:29 PST 2009

:Ah now I see, it always reports to ctime of the inode.  I suppose we don'=
:keep track of mtimes then?
:   simon

    mtime and atime are updated in-place, without rolling a new inode
    record, so a snapshot will not snapshot either field unless some
    other action (e.g. like a file append, chmod, chown, etc) rolls a
    new inode record after the snapshot was made.

    Because of this the snapshot stat code always reports the ctime in
    the atime and mtime fields to guarantee consistency.

    It is possible to change this behavior, but probably not desirable 
    since it could very well result in a large number of inode records
    getting rolled for no good reason (particularly for atime updates).

					Matthew Dillon 
					<dillon at backplane.com>

More information about the Bugs mailing list