flatcar-linux-update-operator
flatcar-linux-update-operator copied to clipboard
Ensure update-agent does not panics/segfaults when node is shutting down
Original issue: https://github.com/coreos/container-linux-update-operator/issues/184
This has been reported in the past and partially resolved, but it seems it is not finished.
See also coreos/container-linux-update-operator#184
We should make sure this is addressed, as it seems like it's the cause: https://github.com/coreos/container-linux-update-operator/issues/93#issuecomment-315911986
I can confirm that this is still happening:
I0927 12:48:56.022773 1 agent.go:237] Deleting 0 pods
I0927 12:48:56.023058 1 agent.go:267] Node drained, rebooting
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x38 pc=0x12cf0a3]
goroutine 32 [running]:
github.com/flatcar-linux/flatcar-linux-update-operator/pkg/updateengine.(*Client).ReceiveStatuses(0xc0003e0ac0, 0xc000490d20, 0xc000104ea0)
/usr/src/github.com/flatcar-linux/flatcar-linux-update-operator/pkg/updateengine/client.go:112 +0x223
created by github.com/flatcar-linux/flatcar-linux-update-operator/pkg/agent.(*Klocksmith).watchUpdateStatus
/usr/src/github.com/flatcar-linux/flatcar-linux-update-operator/pkg/agent/agent.go:340 +0x125