[Samba] Question about Posix Locking and Windows XP/SP3 clients

Ray Van Dolson rvandolson at esri.com
Thu Nov 19 09:46:43 MST 2009

On Thu, Nov 19, 2009 at 08:37:56AM -0800, John_DeBella at notes.teradyne.com wrote:
> Hi Ray,
> Thanks for the reply.
> I'm trying to understand what the risk is of turning off the posix
> locking for the [home] shares? I don't fully understand the issue and
> further more, why this is now raising its "ugly" head after migrating
> from Samba 2.2.7a on Solaris to 3.0.33 on Redhat.
> Thanks,
> -John

I honestly have never tried to really wrap my head around it.  My
understanding is that your CIFS client is requesting a file lock which
is in turn mapped into a POSIX lock request and this is presumably
passed on to the NLM (NFS lock manager) on your remote NFS server.

In our case, many times those NLM's were buggy or would get hung up
which causes everything to come to a grinding halt.

Disabling posix locking for these particular NFS servers resolved the

In your case, NetApp has a pretty solid NFS implementation so I'm a bit
surprised.  Are you fully patched (on the NetApp side)?  Are their any
locking related knobs that can be turned in the NetApp configuration
you could take a look at?  This could potentially be an issue with your
NFS client as well I suppose, though, in my experience I typically do
not need to disable posix locking for most NFS servers..

I've run our same configuration on a RHEL5 machine w/ Samba 3.0.33 as
well.. all I can tell you is we experinenced issues with certain hosts
on both the RHEL and Solaris platforms.  I'm not sure how or why the
behavior would change from an older version of Samba to the 3.0.x
series other than to suggest perhaps Samba 2.2.7a wasn't actually
properly acquiring the POSIX locks like it said it was. :)

If you really want to track this down, you'll likely need to reproduce
the problem and do a packet capture on some of the traffic and see if
you can pull out the NLM requests.  You could probably post that data
here, or open a bug report on RHEL's bugzilla instance.  I've had good
results in the past working with their developers there.

Perhaps someone else can comment.  And, of course, re-exporting NFS via
CIFS is a hacky and ugly thing to do.  Don't do it! (unless you have
to :)


More information about the samba mailing list