Worker crash if hostname is not resolving
guillaume-u opened this issue · comments
I removed a host from my bind configuration. So NRPE is not able to resolve it anymore.
I get this error :
File "/var/lib/shinken/modules/booster-nrpe/module.py", line 508, in work
self.do_work(s, returns_queue, c)
File "/var/lib/shinken/modules/booster-nrpe/module.py", line 547, in do_work
self.launch_new_checks()
File "/var/lib/shinken/modules/booster-nrpe/module.py", line 446, in launch_new_checks
n = NRPEAsyncClient(host, port, use_ssl, timeout, unknown_on_timeout, cmd)
File "/var/lib/shinken/modules/booster-nrpe/module.py", line 189, in init
self.create_socket(family, socket.SOCK_STREAM)
UnboundLocalError: local variable 'family' referenced before assignment
And I get this log :
WARNING: [Shinken] [monitoring-cme001] The worker 1 goes down unexpectedly!
As the result, shinken doesn't execute NRPE check after a while and probes status are staled.
Guillaume.