Yep, kind of what I expected. When I put check_file_age=cscript.exe scripts\check_file_age.vbs -f "c:\temp\test.txt" -w 1 -c 3 in the NCS.ini file and then run ./check_nrpe -H hostname -c check_file_age from the linux prompt I get the appropriate respons. In this case, "WARNING". When I replace the NCS.ini entry with check_file_age=cscript.exe scripts\check_file_age.vbs $ARG1$ and then run ./check_nrpe -H computername -c check_file_age -f "c:\temp\test.txt" -w 1 -c 3 It returns nothing. Just getting the "\" character involved me using the extended ascii code and on my keyboard the @ and " (quote) files were swapped. Obviously the argument string is not arriving correctly at the client machine.
Greg -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Natxo Asenjo Sent: Tuesday, June 22, 2010 12:15 PM To: Opsview Users Subject: Re: [opsview-users] (no subject) On Tue, Jun 22, 2010 at 8:08 PM, Greg Fishback <[email protected]> wrote: > So what am I doing wrong here.... > When I execute > > "cscript.exe scripts\check_file_age.vbs -f "c:\temp\test.txt" -w 1 -c 3" > > from the command line, it returns OK or Error but when I put ok > "check_file_age=cscript.exe scripts\check_file_age.vbs $ARG1$" for testing, just replace that with: check_file_age=cscript.exe scripts\check_file_age.vbs -f "c:\temp\test.txt" -w 1 -c 3 and reload the nsclient service in the windows server. From the opsview server, in order to test quickly without having to reload the web interface, what I do is in a command prompt (shell) run the plugin by hand. I assume you have a windows workstation, so you start putty and login the opsview server. You go to the plugins directory: # cd /usr/local/nagios/libexec # ./check_nrpe -H hostname -c check_file_age the swith -H is for the host, and -c for the remote command to be executed on that host. The command name must exactly be the same you defined in nsc.ini. If all goes well then you go to the next step which is define the check in the web ui of opsview. -- natxo _______________________________________________ Opsview-users mailing list [email protected] http://lists.opsview.org/lists/listinfo/opsview-users _______________________________________________ Opsview-users mailing list [email protected] http://lists.opsview.org/lists/listinfo/opsview-users
