Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault with managed dynamic configs #90

Open
agis opened this issue Aug 13, 2018 · 1 comment
Open

Segfault with managed dynamic configs #90

agis opened this issue Aug 13, 2018 · 1 comment
Labels

Comments

@agis
Copy link
Member

agis commented Aug 13, 2018

After upgrading the relay to ab7647a (the latest master, as of now), it started throwing segfaults:

Aug 13 14:00:32 foo relay[557]: time="2018-08-13T14:00:32+03:00" level=info msg="Using config file '/etc/relay.conf'."
Aug 13 14:00:32 foo relay[557]: time="2018-08-13T14:00:32+03:00" level=info msg="Relay 8b3dcfd8-41ec-44f7-a5ac-a3c1652fe9c1 is initializing."
Aug 13 14:00:32 foo relay[557]: time="2018-08-13T14:00:32+03:00" level=info msg="Started 16 request workers."
Aug 13 14:00:33 foo relay[557]: time="2018-08-13T14:00:33+03:00" level=info msg="Managed bundle dynamic configs enabled."
Aug 13 14:00:33 foo relay[557]: time="2018-08-13T14:00:33+03:00" level=info msg="Refreshing bundle dynamic configs every 5s."
Aug 13 14:00:35 foo relay[557]: panic: runtime error: invalid memory address or nil pointer dereference
Aug 13 14:00:35 foo relay[557]: [signal SIGSEGV: segmentation violation code=0x1 addr=0x28 pc=0x7404e8]
Aug 13 14:00:35 foo relay[557]: goroutine 1 [running]:
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay.(*DynamicConfigUpdater).refreshConfigs(0xc4203e0000)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/dynamic_config.go:104 +0xd8
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay.(*DynamicConfigUpdater).Run(0xc4203e0000, 0x24, 0xc420016009)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/dynamic_config.go:55 +0x19c
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay.(*cogRelay).handleBusEvents(0xc420010540, 0x87a600, 0xc420296d80, 0x0)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/relay.go:133 +0x5bc
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay.(*cogRelay).(github.com/operable/go-relay/relay.handleBusEvents)-fm(0x87a600, 0xc420296d80, 0x0)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/relay.go:79 +0x48
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay/bus.(*MQTTConnection).Connect(0xc420296d80, 0xc42025b920, 0x2e, 0xc420018010, 0x10, 0xc42001603f, 0x15, 0x75b, 0x0, 0x0, ...)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/bus/mqtt.go:51 +0x3b0
Aug 13 14:00:35 foo relay[557]: github.com/operable/go-relay/relay.(*cogRelay).Start(0xc420010540, 0x878240, 0xc420010540)
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/relay/relay.go:91 +0x4f9
Aug 13 14:00:35 foo relay[557]: main.main()
Aug 13 14:00:35 foo relay[557]: /Users/agis/dev/go/src/github.com/operable/go-relay/main.go:182 +0x214

After bisecting, it's apparent that 6a9d3ec caused this.

We do have the managed dynamic configuration mode enabled.

@agis agis added the type/bug label Aug 13, 2018
@wasilak
Copy link

wasilak commented Jun 7, 2019

Same happens to me. For the time being downgrading to operable/relay:1.0.1 did the trick.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants