All of lore.kernel.org
 help / color / mirror / Atom feed
* CLOSE/OPEN race
@ 2016-11-12 11:08 Benjamin Coddington
  2016-11-12 12:54 ` Jeff Layton
  2016-11-12 18:16 ` Trond Myklebust
  0 siblings, 2 replies; 17+ messages in thread
From: Benjamin Coddington @ 2016-11-12 11:08 UTC (permalink / raw)
  To: List Linux NFS Mailing

I've been seeing the following on a modified version of generic/089
that gets the client stuck sending LOCK with NFS4ERR_OLD_STATEID.

1. Client has open stateid A, sends a CLOSE
2. Client sends OPEN with same owner
3. Client sends another OPEN with same owner
4. Client gets a reply to OPEN in 3, stateid is B.2 (stateid B sequence 2)
5. Client does LOCK,LOCKU,FREE_STATEID from B.2
6. Client gets a reply to CLOSE in 1
7. Client gets reply to OPEN in 2, stateid is B.1
8. Client sends LOCK with B.1 - OLD_STATEID, now stuck in a loop

The CLOSE response in 6 causes us to clear NFS_OPEN_STATE, so that the OPEN
response in 7 is able to update the open_stateid even though it has a lower
sequence number.

I think this case could be handled by never updating the open_stateid if the
stateids match but the sequence number of the new state is less than the
current open_state.

Any thoughts?

Ben

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

end of thread, other threads:[~2016-11-14 18:40 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-12 11:08 CLOSE/OPEN race Benjamin Coddington
2016-11-12 12:54 ` Jeff Layton
2016-11-12 15:31   ` Benjamin Coddington
2016-11-12 16:52     ` Jeff Layton
2016-11-12 18:03       ` Benjamin Coddington
2016-11-12 21:16         ` Jeff Layton
2016-11-13  2:56           ` Jeff Layton
2016-11-13 13:34             ` Benjamin Coddington
2016-11-13 14:22               ` Benjamin Coddington
2016-11-13 14:33               ` Jeff Layton
2016-11-13 14:47             ` Trond Myklebust
2016-11-14 14:53               ` Benjamin Coddington
2016-11-14 16:29                 ` Trond Myklebust
2016-11-14 18:40                   ` Benjamin Coddington
2016-11-12 18:16 ` Trond Myklebust
2016-11-12 18:46   ` Benjamin Coddington
2016-11-13  3:09   ` Jeff Layton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.