昨天我已经从4.3.4升级到Nagios 4.4。一切正常,直到今天12:00。
今天下午,在Nagios中配置的一小部分主机开始在主机/服务检查中返回关键状态。检查/usr/local/nagios/var/nagios.log显示:
[1529585857] Warning: Return code of 22 for check of host 'xxxxx.nl' was out of bounds.
[1529585863] Warning: Return code of 22 for check of service 'Check disk' on host 'vps-xxxxx.xxxxxx.nl' was out of bounds.
[1529585863] Warning: Return code of 22 for check of host 'vps-xxxxx-xxxxx.nl' was out of bounds.
[1529585864] Warning: Return code of 22 for check of host 'vps-xxxxx-xxxxx.nl' was out of bounds.
所有主机(约200台)使用相同的配置。只有一小部分受此问题影响。
我尝试执行检查,以手动返回“超出范围”的代码:
14:52:22 [nagios@monitoring]$ ./check_ssh xxxxx.xxxxx.nl
SSH OK - OpenSSH_7.4 (protocol 2.0) | time=0,010242s;;;0,000000;10,000000
15:03:44 [nagios@monitoring]$ ./check_ping -H xxxxx.xxxxx.nl -w 100.0,100% -c 500.0,100%
PING OK - Packet loss = 0%, RTA = 3.15 ms|rta=3.153000ms;100.000000;500.000000;0.000000 pl=0%;20;60;0
我试图找出返回码22代表什么,但在文档中找不到。我也不了解在CLI中运行完全相同的命令时响应会如何变化。
任何帮助都会得到感谢!