No performance data if thresholds are provided as an argument


#1

Hi,

I’m trying to specify custom thresholds for check_memory, etc. which works fine, but whenever I add a custom warning and critical threshold, no performance data will be provided:

[[email protected] ~]# /usr/lib64/nagios/plugins/check_nrpe -H windows_host -c check_memory -a "warn=90" "crit=95"
OK: committed = 7.811GB, physical = 5.917GB
[[email protected] ~]# /usr/lib64/nagios/plugins/check_nrpe -H windows_host -c check_memory
WARNING: committed = 7.813GB, physical = 5.913GB|'committed'=7.81273GB;7.3996;8.32455;0;9.2495 'committed %'=84%;80;90;0;100 'physical'=5.913GB;6.3996;7.19955;0;7.9995 'physical %'=74%;80;90;0;100
[[email protected] ~]#

Not sure why the performance data gets dropped if I want to specify custom thresholds.

Thanks a lot in advance for your help!

Matt


#2

Solution to the problem, specify a threshold term (requires allow nasty characters = true in nsclient.ini):

# /usr/lib64/nagios/plugins/check_nrpe -H windows-host -c check_memory -a "warn=(used > 90%)" "crit=(used > 95%)"
OK: committed = 7.613GB, physical = 5.826GB|'committed'=7.61256GB;8.32455;8.78702;0;9.2495 'committed %'=82%;90;95;0;100 'physical'=5.82566GB;7.19955;7.59952;0;7.9995 'physical %'=73%;90;95;0;100