linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH V2 0/4] nfs4.0: Refetch lease_time after clientID reset
@ 2019-07-07 19:26 Donald Buczek
  2019-07-07 19:26 ` [PATCH V2 1/4] nfs: Fix copy-and-paste error in debug message Donald Buczek
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Donald Buczek @ 2019-07-07 19:26 UTC (permalink / raw)
  To: linux-nfs, trond.myklebust, anna.schumaker; +Cc: Donald Buczek

V2: Make sure, code doesn't depend on CONFIG_NFS_V4_1. I've scattered
#endifs and #ifdefs into the source instead of moving code into other
areas to be more friendly to git. Tell me if you prefer otherwise.

Currently, nfs mounts with vers=4.0 do not pick up a updated
lease_time after a restart of the nfs server. This was discussed in
the thread "4.0 client and server restart with decreased lease time" on
linux-nfs [1].

This patch set fixes the issue for nsf4.0 clients so that hey behave as
nfs4.1 and nfs4.2 clients do.  After a new clientID is established, the
lease_time is re-fetched and used.

Tested with

    CONFIG_NFS_V4=m CONFIG_NFS_V4_1=y CONFIG_NFS_V4_2=y   : mount
    CONFIG_NFS_V4=m CONFIG_NFS_V4_1=y CONFIG_NFS_V4_2=y   : mount vers=4.0
    CONFIG_NFS_V4=m CONFIG_NFS_V4_1=y CONFIG_NFS_V4_2=n   : mount
    CONFIG_NFS_V4=m CONFIG_NFS_V4_1=y CONFIG_NFS_V4_2=n   : mount vers=4.0
    CONFIG_NFS_V4=m CONFIG_NFS_V4_1=n CONFIG_NFS_V4_2=n   : mount

and several restarts of the nfs server with changed leases times, which
were picked up by the client.

[1] https://marc.info/?t=154954022700002&r=1&w=2

Donald Buczek (4):
  nfs: Fix copy-and-paste error in debug message
  nfs4: Make nfs4_proc_get_lease_time available for nfs4.0
  nfs4: Rename nfs41_setup_state_renewal
  nfs4.0: Refetch lease_time after clientid update

 fs/nfs/nfs4_fs.h   |  4 ++--
 fs/nfs/nfs4proc.c  |  6 +++++-
 fs/nfs/nfs4state.c | 46 +++++++++++++++++++++++-----------------------
 fs/nfs/nfs4xdr.c   | 14 ++++++++++++--
 4 files changed, 42 insertions(+), 28 deletions(-)

-- 
2.22.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-07-07 19:26 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-07 19:26 [PATCH V2 0/4] nfs4.0: Refetch lease_time after clientID reset Donald Buczek
2019-07-07 19:26 ` [PATCH V2 1/4] nfs: Fix copy-and-paste error in debug message Donald Buczek
2019-07-07 19:26 ` [PATCH V2 2/4] nfs4: Make nfs4_proc_get_lease_time available for nfs4.0 Donald Buczek
2019-07-07 19:26 ` [PATCH V2 3/4] nfs4: Rename nfs41_setup_state_renewal Donald Buczek
2019-07-07 19:26 ` [PATCH V2 4/4] nfs4.0: Refetch lease_time after clientid update Donald Buczek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).