Page 2 of 2

Re: check_ms_windows_disk_load

Posted: Mon Jun 01, 2015 6:51 pm
by JohnFLi
I got it! The issue must be in the nsclient INI file.

Code: Select all

check_updates=cmd /c echo C:\scripts\Check-Updates.ps1; exit $LastExitCode | powershell.exe -command -
check_ms_diskload=cmd /c echo C:\scripts\check_ms_windows_disk_load.ps1 $ARG1$; exit $LastExitCode | powershell.exe -command –
The "check_updates" checks for windows updates. -------------------- That one works

so I renamed the "Check-Updates.ps1" to something else.
then I renamed "check_ms_windows.ps1" to "Check-Updates.ps1"

In Nagios, I forced the check for the check-updates and it worked!!

Next, I set the file names back correctly.
opened the ini file and manually retyped the line for the diskload (leaving out $ARG1$) using notepad++
saved, restart the service, and tried again......
now it works.....oy

Re: check_ms_windows_disk_load

Posted: Tue Jun 02, 2015 2:56 am
by WillemDH
Hello,

You need to supply at least one argument, due to the external command in nsclient.ini including $ARG1$

Provide this in $arg1$ => '-H localhost -ms 5 -dl C'

Grtz

Willem

Re: check_ms_windows_disk_load

Posted: Tue Jun 02, 2015 10:47 am
by lmiltchev
I am glad your issue has been resolved, JohnFLi! Is it safe to lock the topic?

Re: check_ms_windows_disk_load

Posted: Tue Jun 02, 2015 12:32 pm
by JohnFLi
yes, feel free to lock