linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Question about open(CLAIM_FH)
@ 2019-04-18 13:37 Scott Mayhew
  2019-04-18 14:38 ` Trond Myklebust
  0 siblings, 1 reply; 7+ messages in thread
From: Scott Mayhew @ 2019-04-18 13:37 UTC (permalink / raw)
  To: linux-nfs

When the client does an open(CLAIM_FH) and the server already has open
state for that open owner and file, what's supposed to happen?
Currently the server returns the existing stateid with the seqid bumped,
but it looks like the client is expecting a new stateid (I'm seeing the
state manager spending a lot of time waiting in
nfs_set_open_stateid_locked() due to NFS_STATE_CHANGE_WAIT being set in
the state flags by nfs_need_update_open_stateid()).

Looking at rfc5661 section 18.16.3, I see:

   | CLAIM_NULL, CLAIM_FH | For the client, this is a new OPEN request |
   |                      | and there is no previous state associated  |
   |                      | with the file for the client.  With        |
   |                      | CLAIM_NULL, the file is identified by the  |
   |                      | current filehandle and the specified       |
   |                      | component name.  With CLAIM_FH (new to     |
   |                      | NFSv4.1), the file is identified by just   |
   |                      | the current filehandle.  

So it seems like maybe the server should be tossing the old state and
returning a new stateid?

-Scott

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

end of thread, other threads:[~2019-04-30 18:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-18 13:37 Question about open(CLAIM_FH) Scott Mayhew
2019-04-18 14:38 ` Trond Myklebust
2019-04-18 15:26   ` Trond Myklebust
2019-04-18 20:43   ` Scott Mayhew
2019-04-18 21:31     ` Trond Myklebust
2019-04-30 18:44       ` Scott Mayhew
2019-04-30 18:56         ` Trond Myklebust

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).