farsightsec / fstrm

Frame Streams implementation in C
MIT License
59 stars 27 forks source link

Could not stop Unbound when fstrim reader is running #27

Closed pavel-odintsov closed 7 years ago

pavel-odintsov commented 7 years ago

Hello!

Originally it was bug report to Unbound: https://www.nlnetlabs.nl/bugs-script/show_bug.cgi?id=1144

But Unbound's maintainers recommended to ask this question to you.

Could you look on this issue? It prevent us from wide deployment of DNS TAP because Unbound handle on shutdown.

I think it's related with fstrm's shutdown code. But I do not see any issues and looking for you help.

Thank you so much for attention!

bapril commented 7 years ago

Hi Pavel,

We'll take a look. Sorry for the delay, I'm just getting home from a busy week in New Zealand (Including an earthquake).

Thanks Ben

On 11/17/16 5:02 AM, Pavel Odintsov wrote:

Hello!

Originally it was bug report to Unbound: https://www.nlnetlabs.nl/bugs-script/show_bug.cgi?id=1144

But Unbound's maintainers recommended to ask this question to you.

Could you look on this issue? It prevent us from wide deployment of DNS TAP because Unbound handle on shutdown.

I think it's related with fstrm's shutdown code. But I do not see any issues and looking for you help.

Thank you so much for attention!

Ben April - Director of Engineering Farsight Security, Inc.

pavel-odintsov commented 7 years ago

Oh, I hope you are well!

pavel-odintsov commented 7 years ago

I just found interesting behaviour. When I press CTRL+C it hangs but after ~5-7 minutes waiting it stops correctly. I'm not sure it's useful but it could help to debug such behaviour.

cmikk commented 7 years ago

I've tracked down the issue to golang-framestream not implementing the closing handshake of bidirectional fstrm. I just fixed this issue there, so:

go get -u github.com/farsightsec/golang-fstrm

and rebuilding golang-dnstap/dnstap should fix the problem.

Thanks, -Chris

pavel-odintsov commented 7 years ago

@cmikk thank you so much! Going to check soon!

pavel-odintsov commented 7 years ago

I could confirm that issue was fixed! :) I could stop Unbound correctly! Thank you!