Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
Directory
santoshkp
bysantoshkp, October 27, 2011
Thanks for the script.
I am facing some issues when running this script from a path where path name contains a space (eg; C:\Program Files\NSClient++\scripts). My entry is like as follows in nsc.ini file at "NRPE handler section).
Entry in NRPE handle section:
check_nbu_backup=cmd /c echo & 'C:\Program Files\NSClient++\scripts\check_nbu_backstat.ps1' $ARG1$ $ARG2$; exit $LastExitCode | powershell.exe -command -
On executing the command from collector:
[root@inblr-gitotest1 libexec]# ./check_nrpe -H inhyd-gitos2 -c check_nbu_backup -a "-nbuClient" "test"
getting the output as "ECHO is on.
The filename, directory name, or volume label syntax is incorrect."
If one will go by your instaructions, the standalone run of the script wants 2 arguments ( 1 option - "-nbuClient" and [nbu client name - let be named as "test"). If this is the case then how can be command in NSC.ini file will be with one argument as (check_nbu_backstat=check_nbu_backstat.ps1 $ARG1$
).
If i am configuring the way you mentioned then the PS script is not invoked by the nrpe.
Please guide if i am doing anything wrong here.
let me know if u need any more details here.
Thanks,
Santosh
I am facing some issues when running this script from a path where path name contains a space (eg; C:\Program Files\NSClient++\scripts). My entry is like as follows in nsc.ini file at "NRPE handler section).
Entry in NRPE handle section:
check_nbu_backup=cmd /c echo & 'C:\Program Files\NSClient++\scripts\check_nbu_backstat.ps1' $ARG1$ $ARG2$; exit $LastExitCode | powershell.exe -command -
On executing the command from collector:
[root@inblr-gitotest1 libexec]# ./check_nrpe -H inhyd-gitos2 -c check_nbu_backup -a "-nbuClient" "test"
getting the output as "ECHO is on.
The filename, directory name, or volume label syntax is incorrect."
If one will go by your instaructions, the standalone run of the script wants 2 arguments ( 1 option - "-nbuClient" and [nbu client name - let be named as "test"). If this is the case then how can be command in NSC.ini file will be with one argument as (check_nbu_backstat=check_nbu_backstat.ps1 $ARG1$
).
If i am configuring the way you mentioned then the PS script is not invoked by the nrpe.
Please guide if i am doing anything wrong here.
let me know if u need any more details here.
Thanks,
Santosh