[PATCH] Fix bug #13121 - Non-smbd processes using kernel oplocks can hang smbd

Jeremy Allison jra at samba.org
Wed Nov 15 21:32:21 UTC 2017


On Thu, Nov 16, 2017 at 09:19:41AM +1300, Gary Lockyer wrote:
> 
> 
> On 16/11/17 08:19, Jeremy Allison via samba-technical wrote:
> > On Thu, Nov 16, 2017 at 07:52:29AM +1300, Gary Lockyer wrote:
> >>
> >>
> >> On 16/11/17 07:06, Jeremy Allison via samba-technical wrote:
> >>> On Thu, Nov 16, 2017 at 06:55:13AM +1300, Gary Lockyer via samba-technical wrote:
> >>>> I'm now seeing significant numbers of builds hanging in:
> >>>>
> >>>> [558(3538)/2212 at 1h13m33s] samba3.smb2.kernel-oplocks(nt4_dc)
> >>>
> >>> Can you track down what part of the test it's hanging in ?
> >>> A strace on the smbtorture client process would help here.
> >> I'll kick off some builds now, and see what I can find.
> >>>
> >>> The test does depend on working kernel oplocks as the
> >>> test child holds the lease for 3 seconds. Also, the
> >>> child does a pause() waiting for a signal which is
> >>> expected to come when the smbd tries to open the leased
> >>> file. I could add a 5 second alarm() timeout to ensure
> >>> it can't ever hang there but under normal circumstances
> >>> it shouldn't hang.
> >>>
> >>> What platform are you testing on - if it's non-Linux
> >>> this test should not be running.
> >> Ubuntu 14.04
> > 
> > I'm also developing and testing on a variant of 14.04,
> > so the kernel should work.
> > 
> > I'm running with kernel 4.4.0-93-generic. What kernel
> > version is on yours ?
> > 
> It's running 3.13.0-92-generic

That's it. That kernel almost certainly has broken
lease support.

We didn't notice because we never had any tests before
for smbd interacting with non-smbd processes with
kernel leases.

Now we do :-). So it's detecting a broken kernel,
which is what it was designed to do.

I suggest we add my additional patch to master so
it doesn't hang anymore, and then you'll have to
carry an extra patch adding samba3.smb2.kernel-oplocks(nt4_dc)
to knownfail until you can run on a working kernel.

But at least we have tests for this now :-).

Cheers,

	Jeremy.



More information about the samba-technical mailing list