Nagios nrpe.cfg running a python command issues


#1

I created a service and command to run a python script in nrpe.cfg.

When I run the following command: command[check_perforce_disk_usage]=/usr/local/nagios/libexec-custom/Check_Disk_Usage.py %–warning=$ARG1$% %–critical=$ARG2$% %–include=$ARG3$% with the arguments delimited with “%” the python script is executed correctly.

Previously I had the command as follows:command[check_perforce_disk_usage]=/usr/local/nagios/libexec-custom/Check_Disk_Usage.py --warning=$ARG1$ --critical=$ARG2$ --include=$ARG3$ and the python script could not parse the arguments correctly reporting this was not an integer blah blah blah.

My questions is why does the “%” around the argument work in the nrpe.cfg. I basically just guess and it worked. Any answer would much be appreciated :wink: