check_nrpe and "Connection Refused"


#1

Hello,

I am currently using ‘check_nrpe -u’ so that socket timeouts result in UNKNOWN instead of CRITICAL. This works great. I’d like to mimic this same behavior when a “Connection Refused” occurs. I have some service checks that use NRPE and have very low thresholds. When our solaris machines reboot, NRPE is killed early in the shutdown process, but these service checks still run (because nagios thinks the box is still up) and immediately get a “connection refused” which generates a CRITICAL notification. This is not desirable.

IS there a way to make check_nrpe return UNKNOWN when a “connection refused” is received? This would be incredibly helpful.

Thanks.