check_apc.pl --> running multiple check commands
Posted: Fri Feb 07, 2020 7:06 pm
Does anyone know what the magic syntax is for running multiple check commands with this plugin would be?
(see attached help page, etc.)
techservices@vpd-nagios:/usr/local/nagios/libexec$ perl check_apc.pl -H192.168.60.3 -Cpublic -l out_status; bat_capacity; out_phase; out_load; bat_run_remaining
<output>
OK: UPS is Running on GridLine
bat_capacity: command not found
out_phase: command not found
out_load: command not found
bat_run_remaining: command not found
If I run the command like this...
techservices@vpd-nagios:/usr/local/nagios/libexec$ perl check_apc.pl -H192.168.60.3 -Cpublic -l bat_capacity out_phase out_load bat_run_remaining out_status
<output>
OK: UPS is Running on GridLine
(it only runs the last command)
If you take out the spaces between the checks, it errors (doesn't recognize the command)
(ex. bat_capacityout_phase)
I've also tried (ex. $bat_capacity) and other variations (e.g. using $, using \, using --, )
I just can't find it.
(see attached help page, etc.)
techservices@vpd-nagios:/usr/local/nagios/libexec$ perl check_apc.pl -H192.168.60.3 -Cpublic -l out_status; bat_capacity; out_phase; out_load; bat_run_remaining
<output>
OK: UPS is Running on GridLine
bat_capacity: command not found
out_phase: command not found
out_load: command not found
bat_run_remaining: command not found
If I run the command like this...
techservices@vpd-nagios:/usr/local/nagios/libexec$ perl check_apc.pl -H192.168.60.3 -Cpublic -l bat_capacity out_phase out_load bat_run_remaining out_status
<output>
OK: UPS is Running on GridLine
(it only runs the last command)
If you take out the spaces between the checks, it errors (doesn't recognize the command)
(ex. bat_capacityout_phase)
I've also tried (ex. $bat_capacity) and other variations (e.g. using $, using \, using --, )
I just can't find it.