Bug 145976 - Sub-second mtime changes without modifying file
Summary: Sub-second mtime changes without modifying file
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: kernel
Version: 4.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: ---
Assignee: Stephen Tweedie
QA Contact: Brian Brock
URL:
Whiteboard:
: 155406 (view as bug list)
Depends On:
Blocks: 139847 154907 156322
TreeView+ depends on / blocked
 
Reported: 2005-01-24 14:17 UTC by Stephen Tweedie
Modified: 2007-11-30 22:07 UTC (History)
5 users (show)

Fixed In Version: RHSA-2005-514
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-10-05 12:42:29 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Upstream 2.6 patch to implement fs-specific timestamp granularities (81.53 KB, patch)
2005-01-24 14:23 UTC, Stephen Tweedie
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2005:514 0 qe-ready SHIPPED_LIVE Important: Updated kernel packages available for Red Hat Enterprise Linux 4 Update 2 2005-10-05 04:00:00 UTC

Description Stephen Tweedie 2005-01-24 14:17:52 UTC
*** This bug has been split off bug 139884 ***

------- Original comment by Patrick J. LoPresti on 2004.11.18 12:05 -------

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5)
Gecko/20041111 Firefox/1.0

Description of problem:
The 2.6 kernel's buffer cache has sub-second resolution for file
times.  The ext3 file system does not.  Consequently, the observable
mtime for a file changes unpredictably.

This is causing problems for us while compiling our product, because
"make" relies on file modification times to determine what to compile.
 But the bug is easily observed without running make; see the steps below.


Version-Release number of selected component (if applicable):
kernel-2.6.9-1.678_FC3

How reproducible:
Always

Steps to Reproduce:
1. touch /tmp/foo

2. ls -l --full-time /tmp/foo

3. (reboot system)

4. ls -l --full-time /tmp/foo

    

Actual Results:  The visible file modification time changes (gets
rounded down) as a result of the reboot.  The rounding down happens
whenever the kernel's buffer cache for the file gets flushed, which on
an active system is essentially random.


Expected Results:  The file modification time should not change for a
file which is not modified.


Additional info:

This was discussed on the linux-kernel mailing list back in April, but
as far as I can tell it was never resolved:

  http://www.ussg.iu.edu/hypermail/linux/kernel/0404.0/0193.html

And now it is causing a real problem for us.  This is clearly a kernel
bug; a file's modification time should not change unless the file is
modified.

Comment 2 Stephen Tweedie 2005-01-24 14:23:21 UTC
Created attachment 110123 [details]
Upstream 2.6 patch to implement fs-specific timestamp granularities

Comment 13 Stephen Tweedie 2005-09-30 15:38:26 UTC
*** Bug 155406 has been marked as a duplicate of this bug. ***

Comment 15 Red Hat Bugzilla 2005-10-05 12:42:29 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2005-514.html



Note You need to log in before you can comment on or make changes to this bug.