cvs commit: src/sys/vfs/nfs nfs_vnops.c

Matthew Dillon dillon at
Fri Jun 15 10:25:57 PDT 2007

dillon      2007/06/15 10:25:05 PDT

DragonFly src repository

  Modified files:
    sys/vfs/nfs          nfs_vnops.c 
  Add vfs.nfs.pos_cache_timeout to complement vfs.nfs.neg_cache_timeout.
  Because NFSv3 is stateless, the client normally relies on the server
  returning ESTALE (Stale NFS handle) to determine whether a relookup is
  needed.  However, this does not cover namespace issues such as rename()s
  and it is possible to get into a situation where a NFS client winds up
  getting permanently out of sync with a server, requiring remounting to
  The positive cache timeout will force open/stat and other namespace
  operations to re-lookup the name, even if the file handle is still
  valid.  The performance impact tested via a buildworld with a read-only
  NFS mounted /usr/src appears to be minimal.
  The positive cache timeout defaults to 3 second, same as the negative cache
  timeout.  The timeout can be adjusted on the fly for any new namespace
  lookups but changing the sysctl will not change any namespace lookups already
  cached until they timeout.
  Reported-by: Joerg Sonnenberger <joerg at>
  Revision  Changes    Path
  1.72      +23 -14    src/sys/vfs/nfs/nfs_vnops.c

More information about the Commits mailing list