Timestamps of a file on am NFSv4 volume are not updated when truncating an empty file

Solution Unverified - Updated -

Issue

  • The timestamps of an empty destination file (/mnt/nfs/file) are not updated after overwriting it with another empty file using cp command.

    $ touch file
    $ touch /mnt/nfs/file
    $ stat /mnt/nfs/file   # Shows initial timestamps
    $ cp file /mnt/nfs/file
    $ stat /mnt/nfs/file   # Timestamps remain unchanged
    

Environment

  • Red Hat Enterprise Linux 9
  • Red Hat Enterprise Linux 8
  • NFSv4 Client

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content