7-STABLE NFS: fatal: "select lock: Permission denied"

Chuck Swiger cswiger at mac.com
Mon Apr 4 19:26:46 UTC 2011


On Apr 4, 2011, at 12:14 PM, Marc G. Fournier wrote:
>> OK-- Cyrus IMAP uses a variant of maildir, so you're relatively safe even if locking is not available.
> 
> So, just to get this clear ...
> 
> If I were to boot a diskless station using an NFS backend, then that instance would be prone to corruption since lockd wouldn't work, even though the only processes handling the files on that mount?

If you're running a diskless system using NFS filesystem for storage, and you run stuff that wants to do fcntl/lockf/flock locking, and rpc.lockd isn't available, then yes, there is risk of data corruption.  However, Postfix can use .dotfile locking, even if fcntl (etc) locking is broken, and maildir is designed to avoid needing locking the way mbox does:

   http://www.postfix.org/NFS_README.html

> And this may be where I'm mis-understanding things:
> 
> Does rpc.lockd work at the process level or file system?  For instance, in my test case, I'm trying to operate within a jail ... does the rpc.lockd runnig at the primary OS level handle communications between client<->server, irrelevent of whether the process is running in a jail or not?

rpc.lockd provides locking at the filesystem level.  Locks are performed against file descriptors either for entire files or record-level locking; they are not specific to a single process (indeed, locking would be mostly useless if it was only visible within a single process).

Regards,
-- 
-Chuck



More information about the freebsd-net mailing list