allow touch/settime to fix out of range timestamps [PSARC/2008/508 FastTrack timeout 08/14/2008]
Don Cragun
don.cragun at sun.com
Thu Aug 7 13:34:55 PDT 2008
I am sponsoring this fasttrack case for Milan Jurik.
The project team asks for a patch release binding.
The timer expires on August 14, 2008.
- Don
Template Version: @(#)sac_nextcase 1.66 04/17/08 SMI
This information is Copyright 2008 Sun Microsystems
1. Introduction
1.1. Project/Component Working Name:
allow touch/settime to fix out of range timestamps
1.2. Name of Document Author/Supplier:
Author: Milan Jurik
1.3 Date of This Document:
07 August, 2008
2. Project Summary
2.1. Project Description:
Some filesystems allow users to set file timestamps to values
that won't fit in a 32-bit "seconds since the epoch" field.
Although 64-bit Solaris kernels are able to work with such
files, most Solaris 32-bit utilities aren't. Since timestamps
like this won't occur naturally until 03:14:08 on Tuesday,
January 19, 2038 UTC, we don't believe it is important for all
utilities to handle long-range timestamps now. But, it should
be possible to change timestamps to fit in the 32-bit range so
other utilities can operate on them correctly. The settime and
touch utilities (which are hard links to the same binary) will
be modified to set timestamps correctly even when stat() fails
with EOVERFLOW errors.
2.2. Risks and Assumptions:
None.
4. Technical Description:
4.1. Details:
The settime and touch utilities use stat() to determine if a
file currently exists, and if it exists to get the current
access and modification timestamps of the file. If an
EOVERFLOW occurs, settime and touch currently fail even if the
current timestamps are both being replaced by new values.
The settime and touch utilities will be modified to fail in
this case only when one of the timestamps is to be preserved
(-a or -m is specified, but not both) or when timestamps from
a reference file are out of range ('settime -f ref_file' and
'touch -r ref_file').
Note that stat64() still only provides 32-bit "seconds since
the epoch" values in timestamps, so it won't help in 32-bit
binaries. And, since 64-bit binaries won't run on the x86
hardware we support, converting settime and touch to be 64-bit
utilities would not entirely fix the problem.
4.2. Bug/RFE Number(s):
CR 6709455 - settime should be able to manipulate files with
wrong timestamp
4.3. In Scope:
The settime and touch utilities (see touch(1)).
4.4. Out of Scope:
Other utilities. There is a 64-bit version of the ls utility
to handle this case, but it only works on 64-bit kernels. The
rm utility will be fixed to allow removing files with out of
range timestamps, but that is not part of this case. (See CR
6734496.)
4.6. Doc Impact:
The touch(1) man page will be updated. (See touch.1.txt in the
materials directory.)
5. Reference Documents:
CR 6248065 - *ls* should be isaexec'ed (64bit on 64bit kernel,
32bit on 32bit kernel)
CR 6629604 - ZFS: lstat64() on ZFS file returns EOVERFLOW
CF 6734496 - *rm* should be isaexec'ed (64bit on 64bit kernel,
32bit on 32bit kernel)
6. Resources and Schedule:
6.1. Projected Availability:
August 2008
6.2. Cost of Effort:
1 week
6.4. Product Approval Committee requested information:
6.4.1. Consolidation or Component Name:
ON
6.4.3. Type of CPT Review and Approval expected:
RFE
6.4.7. Target RTI Date/Release:
August 2008
6.5. ARC review type:
FastTrack
6.6. ARC Exposure:
open
6. Resources and Schedule
6.4. Steering Committee requested information
6.4.1. Consolidation C-team Name:
ON
6.5. ARC review type: FastTrack
6.6. ARC Exposure: open
More information about the opensolaris-arc
mailing list