linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC] server's statd and lockd will not sync after its nfslock restart
@ 2009-12-15 10:02 Mi Jinlong
  2009-12-15 12:41 ` J. Bruce Fields
  2009-12-15 15:10 ` Chuck Lever
  0 siblings, 2 replies; 18+ messages in thread
From: Mi Jinlong @ 2009-12-15 10:02 UTC (permalink / raw)
  To: Trond.Myklebust, J. Bruce Fields, NFSv3 list, Chuck Lever

Hi,

When testing the NLM at the latest kernel(2.6.32),  i find a bug.
When a client hold locks, after server restart its nfslock service, 
server's statd will not synchronize with lockd.
If server restart nfslock twice or more, client's lock will be lost.

Test process:

  Step1: client open nfs file.
  Step2: client using fcntl to get lock.
  Step3: server restart it's nfslock service.

After step3, server's lockd records client holding locks, but statd's 
/var/lib/nfs/statd/sm/ directory is empty. It means statd and lockd are 
not sync. If server restart it's nfslock again, client's locks will be lost.

The Primary Reason:

  At step3, when client's reclaimed lock request is sent to server, 
client's host(the host struct) is reused but not be re-monitored at
server's lockd. After that, statd and lockd are not sync.

Question:

In my opinion, if lockd is allowed reuseing the client's host, it should
send a SM_MON to statd when reuse. If not allowed, the client's host should 
be destroyed immediately.
 
What should lockd to do?  Reuse ? Destroy ? Or some other action?


thanks,

Mi Jinlong


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

end of thread, other threads:[~2009-12-19 16:42 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-15 10:02 [RFC] server's statd and lockd will not sync after its nfslock restart Mi Jinlong
2009-12-15 12:41 ` J. Bruce Fields
2009-12-16  9:46   ` Mi Jinlong
2009-12-15 15:10 ` Chuck Lever
2009-12-16 10:27   ` Mi Jinlong
2009-12-16 13:49     ` Jeff Layton
     [not found]       ` <20091216084902.64f722ad-9yPaYZwiELC+kQycOl6kW4xkIHaj4LzF@public.gmane.org>
2009-12-17  9:34         ` Mi Jinlong
2009-12-16 19:33     ` Chuck Lever
2009-12-17 10:07       ` Mi Jinlong
2009-12-17 16:18         ` Chuck Lever
2009-12-17 20:14           ` J. Bruce Fields
2009-12-17 20:35             ` Chuck Lever
2009-12-17 20:27           ` Trond Myklebust
2009-12-17 20:34             ` Chuck Lever
2009-12-17 20:48               ` Trond Myklebust
2009-12-17 23:14           ` Neil Brown
     [not found]             ` <20091218101438.48eb06a4-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2009-12-18 15:18               ` Chuck Lever
2009-12-19 16:42                 ` Steve Dickson

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