在 Centos7 上,按照nrpe 插件安装步骤,在测试 Nagios 服务器和远程代理之间的连接时,我收到了这个错误...
/usr/local/nagios/libexec/check_nrpe -H 192.168.50.5
CHECK_NRPE: Error - Could not connect to 192.168.50.5: Connection reset by peer
在 /etc/xinetd.d/nrpe 中,我将 Nagios 服务器的 IP 地址添加到 only_from 字段。
# default: off
# description: NRPE (Nagios Remote Plugin Executor)
service nrpe
{
disable = no
socket_type = stream
port = 5666
wait = no
user = nagios
group = nagios
server = /usr/local/nagios/bin/nrpe
server_args = -c /usr/local/nagios/etc/nrpe.cfg --inetd
only_from = 127.0.0.1 ::1 {server_IP}
log_on_success =
}
然后我重新启动了 xinetd 服务;但是,在检查服务状态时,会出现此错误日志消息...
Aug 09 09:32:21 localhost.localdomain xinetd[1448]: bind failed (Address already in use (errno = 98)). service = nrpe
Aug 09 09:32:21 localhost.localdomain xinetd[1448]: Service nrpe failed to start and is deactivated.