[TAG] NFS file locking?
Karl-Heinz Herrmann
kh1 at khherrmann.de
Fri Oct 21 00:04:21 MSD 2005
Hi,
I ran into a weird problem today. For some time now gimp complains about
"permission denied" when it tries to lock files and today openoffice 2.0
refused to write its config and documents. soffice seems to open the
file for read to check if it exists already, closes the handle and
reopens with a lock flag set -- which fails with "permission denied".
Don't have the exact strace here right now, but can send it tomorrow.
I finally found for openoffice that this is *only* on files systems
mounted from our server via nfs. Writing local files as well as
writing to *NFS MOUNTS* from other machines are ok.
Now I can not find any obvious difference in the setup. both server (non
working locks) and other non-servers (working file locks)
export with kernel nfsd, export lines are just ip(rw,sync), the
hosts.allow entires for lockd, statd,... include my client IP ---
everything looks ok.
I tried to mount with "-o mand,lock" but no improvement whatsoever. I
now found out that mand only works with special group permission set --
nut I do not think that soffice requires mandatory file locking just to
write a file. The lock should be default (only nolock is required for
old NFS servers according to manpage).
I also tried to write a perl script which locks a file to allow quicker
testing, but the advisory file lock "flock" works (at least the flock
(FH) or die "..." clause is not triggered).
All systems are rather similar debian testing, rather up to date (server
maybe a few months behind "current").
The problem now exists for some time -- surviving the occasional
upgrade. It never bothered me too much since for gimp it was only an
annoying error message on the terminal. Now it keeps me from saving
files ;-/
Any ideas?
K.-H.
More information about the TAG
mailing list