部署很多台nrpe客户端都很正常,只有两台有这种怪异的错误,网上常见的错误解决方法都不管用,决定详细找下原因。

redhat6.2系统

nagios监控页面报   CHECK_NRPE: Error - Could not complete SSL handshake. 

/var/log/message报    Jan 27 11:47:32 localhost kerne l: nrpe[16266]: segfault at 34f04c16a0 ip 00000034f04a9354 sp 00007fffd8e802b0 error 7 in libcrypto.so.1.0.0[34f0400000+173000]

/usr/local/nagios/libexec/check_nrpe -H 192.168.1*
CHECK_NRPE: Error - Could not complete SSL handshake.

试了rpm包安装也不行,分析可能还是跟ssl相关,因为编译的时候有相关ssl的错误,虽然能安装成功。

发现openssl有两个版本

# rpm -qa openssl*
openssl-devel-1.0.0-20.el6.x86_64
openssl-1.0.0-20.el6.x86_64
openssl098e-0.9.8e-17.el6.x86_64

卸载openssl098e-0.9.8e-17.el6.x86_64 和openssl-devel-1.0.0-20.el6.x86_64,再重新安装下openssl-devel-1.0.0-20.el6.x86_64

再次启动nrpe ,ok了。。。

[root@localhost ~]#  /usr/local/nagios/libexec/check_nrpe -H 192.168.1.*
NRPE v2.12

总结:其它nrpe正常的机器上也有openssl098e-0.9.8e-17.el6.x86_64包,觉得还是可能跟系统相关服务有关,发现这两个有问题的机器上都有sfcb服务,其它的机器没有安装。