Maintained by: NLnet Labs

deadlock in unbound-control commands

Poprocks
Mon Aug 24 21:05:46 CEST 2015


Hello!

On Mon, Aug 24, 2015 at 12:54:17PM +0200, W.C.A. Wijngaards via Unbound-users wrote:
> Hi Poprocks,
> 
> On 24/08/15 01:52, Poprocks via Unbound-users wrote:
> > Hello,
> > 
> > I have encountered an issue in which unbound appears to hang when
> > issuing commands via unbound-control. I am running unbound 1.5.4
> > built on an Ubuntu 12.04 system. I've configured unbound with the
> > same options available from the unbound package for Ubuntu
> > precise:
> 
> Thank you for the report with all the details.  I could not reproduce
> it, but code inspection reveals a deadlock that is caused when you
> interrupt the printout of unbound-control list_local_data.
> 
> You have so much local data (10000s) that the interrupt carries back
> to the daemon, and then there is a bug in the code path that deals
> with the interrupted TLS stream.  That does not properly unlock the
> zones.lock and thus the next lock attempt hangs.
> 
> It is fixed in the code repository for the next release.  Or, as a
> workaround, do not ^C the printout of unbound-control list_local_data.
> 
> Best regards,
>    Wouter
> 

Thank you for a prompt response!

Is it possible that piping the output of unbound-control list_local_data into `less` would cause the same problem? When I ran across this I did not ^C the output, but I did pipe the output directly to less (and then often exited less before scrolling all the way to the bottom). Is it also possible that the deadlock would manifest after several calls to unbound-control (e.g., call 'unbound-control list_local_data | less' several times before encoutering the deadlock)?

Is there an ETA for the next release? Many thanks again for the analysis and response!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 835 bytes
Desc: Digital signature
URL: <https://unbound.nlnetlabs.nl/pipermail/unbound-users/attachments/20150824/389c7389/attachment.sig>