mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* nfs NLM locks greater than 8 bytes
@ 2003-11-04  0:52 Bill Akers
  2003-11-05  4:19 ` Trond Myklebust
  0 siblings, 1 reply; 2+ messages in thread
From: Bill Akers @ 2003-11-04  0:52 UTC (permalink / raw)
  To: linux-kernel

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Has anyone looked at the NFS NLM byte lock size issue between the Linux kernel 
based NFS server and BSD 5 clients?  BSD 5 uses a large cookie for locking 
(16 or even 20 bytes).  Linux automatically rejects any lock attempts with a 
cookie over 8 bytes.  This issue has become important for us because of 
Apple's release of OS X 10.3 (Panther), which is based on BSD 5.

Jonathan Lennox summed it up pretty well on the Freebsd bug list:

> Linux's implementation of NFS NLM locks is buggy: it doesn't support lock
> cookies longer than 8 bytes in size.  See the comment in
> <http://lxr.linux.no/source/include/linux/lockd/xdr.h?v=2.6.0-test2> on the
> definition of 'struct nlm_cookie': "NLM cookies. Technically they can be 1K,
> Nobody uses over 8 bytes however."
>
> Unfortunately, this is actually "nobody" except FreeBSD 5.x, which uses
> 16-byte cookies.  As a result, any attempt by a FreeBSD client to lock an
> NFS-mounted file from a Linux server results in the process on the FreeBSD
> client hanging, unkillably.

His full original post is:
http://lists.freebsd.org/pipermail/freebsd-bugs/2003-September/003069.html

I have checked out every recent version of the kernel on kernel.org (2.4 and 
2.6) and haven't seen any modifications to xdr.h or xdr.c that might address 
this issue.  Nor have I been able to find any posts on Linux lists that 
discuss the issue.  There is a BSD patch to dumb down their client code and 
make the cookie size smaller.  The fear being that it will take a long time 
to get a linux patch into the kernel.  But if no one has even brought up the 
issue here, it will certainly take forever.  :-)

I can probably dust off enough of my old coding skills to up the check from 8 
bytes to some higher number (16, 20, 1024 bytes?).  But I certainly don't 
know enough about the Linux kernel to know what ramifications that will have.

Thanks,

- -- 
Bill Akers
Director of Network Operations
UCLA Graduate School of Education and Information Studies
akers@gseis.ucla.edu
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE/pvhUHuBhMoY9pyIRAn5iAKCpWedBMVY4c41vz1/dNicIx1WJNACcClN2
jf6yR5yyOxTD0i1kx91Tyiw=
=+5DB
-----END PGP SIGNATURE-----



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

end of thread, other threads:[~2003-11-05  4:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-11-04  0:52 nfs NLM locks greater than 8 bytes Bill Akers
2003-11-05  4:19 ` Trond Myklebust

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®