Next: , Previous: , Up: Finding Files   [Contents][Index]

2.5 Time

Each file has three timestamps, which record the last time that certain operations were performed on the file:

  1. access (read the file’s contents)
  2. change the status (modify the file or its attributes)
  3. modify (change the file’s contents)

Some systems also provide a timestamp that indicates when a file was created. For example, the UFS2 filesystem under NetBSD-3.1 records the birth time of each file. This information is also available under other versions of BSD and some versions of Cygwin. However, even on systems which support file birth time, files may exist for which this information was not recorded (for example, UFS1 file systems simply do not contain this information).

You can search for files whose timestamps are within a certain age range, or compare them to other timestamps.