Corrupted Excel files, oplock_break(905) errors

Mattias.Gronlund Mattias.Gronlund at
Sat Oct 23 19:03:28 GMT 1999

Jeremy Allison wrote:
> Nicolas Williams wrote:
> >
> > Meantime, the client reconnected and a new smbd starts and the the
> > client attempts to re-establish the locks, oplocks, share modes that it
> > had held prior to reconnecting and the new smbd may wait for those locks
> > to be given up (by the old smbd) or, in the case of oplocks, it will
> > send an oplock_break to the old smbd (but the old smbd will not catch
> > the oplock_break as it is sleeping).
> This is the bit I find strange. Even if smbd is "sleeping" it
> should still be in a select() where the oplock udp socket is
> being listened to for read event status.

This is not that strange, at least on our site we get logs at the
that tells us that the NT-BDC was unreachable at just after the
I have not had the oppertuity to get enough network-traces to tell if it
is the clients network software or the switched network that just goes

> Can you give me a stack backtrace of an smbd in this state so
> I can discover why it isn't replying to oplock break requests
> in this state ?

It's because it is stuck in a read system call, the client has announced
that it will send a packet, and the client has sent some data. But the
data sent was just enought to let the select loose, not enought for the
following read call to return.

You are right that it could be smbd missinterpreting the client and
and then expecting more data than should be sent from the client. But
in either case smbd should not block! 

I have posted a patch for this "blocked in read" denial of service, but
when I finnished the implementation I realized that the right thing
to do is to make the socket nonblocking. That seems to be the best way
to fix both blocked in read and blocked in write.

I will try to implement the nonblocking socket patch before the 2.0.7

> Thanks,
>         Jeremy.
> --
> --------------------------------------------------------
> Buying an operating system without source is like buying
> a self-assembly Space Shuttle with no instructions.
> --------------------------------------------------------

More information about the samba-technical mailing list