Re: file locking over NFS in 2.2.7

Trond Myklebust (trond.myklebust@fys.uio.no)
22 May 1999 03:16:22 +0200


thomas@Cuivre.FR.EU.ORG (Thomas Quinot) writes:

> Dans mail.linux.kernel, Trond Myklebust écrit :
>
> >File locking is not supported by the userland nfsd. If you want true
> >file locking, use knfsd. 2.0.x kernels supported local file locks
> >only: this is why they 'worked' (not at all), and 2.2.x will do the
> >same if you use the 'nolock' mount option.
>
> What about the case where a partition on a Linux server is mounted
> by a Solaris client? Solaris does not have a 'nolock' option for
> NFS mounts, and some software (eg Sendmail 8.9.3) insist on doing
> some sort of locking (Sendmail will always use either fcntl or lockf).
> It looks to me that knfsd is not quite stable yet, so I'm reluctant
> to move my production machines to it.

As far as I know, Solaris won't use locking if it doesn't detect a
lockd daemon. (Note that we could easily implement that in the 'mount'
program for Linux; just use 'pmap_getport'.)
Your Solaris client will thus only give you local file locking, and
access by 2 different machines to the same file is not safe.

Cheers,
Trond

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/