[Nagiosplug-help] check_nt runs but just reports "(null)"

Kevin O'Donnell kevino at kevino.net
Fri Nov 29 09:56:02 CET 2002


Andreas Baetz wrote:

>You have to tell check_nt what to check for.
>Please use ./check_nt -h to view the parameters.
>
>Example:
>./check_nt -H serveraddress -v CLIENTVERSION
>
>should report the version of nsclient on serveraddress.
>  
>
Thanks Andreas, that worked niceley.

% ./check_nt -H 192.168.20.57 -v CLIENTVERSION
1.0.6.2

The "-h" usage statement should probably be patched to reflect that "-v" 
is a mandatory argument. :)

% diff -u check_nt.c.orig check_nt.c
--- check_nt.c.orig     Fri Nov 29 09:48:25 2002
+++ check_nt.c  Fri Nov 29 09:48:48 2002
@@ -502,7 +502,7 @@

 void print_usage(void)
 {
-       printf("Usage: %s -H host [-p port] [-s password|-S 
passwordfile] [-v variable] [-w warning] [-c critical] [-l params] [-d 
SHOWALL] [-t timeout]\n",PROGNAME);
+       printf("Usage: %s -H host -v variable [-p port] [-s password|-S 
passwordfile] [-w warning] [-c critical] [-l params] [-d SHOWALL] [-t 
timeout]\n",PROGNAME);
 }

Maybe this is fixed in 1.07.0, but 1.06.02 states that "-v" is optional. 
Thanks for the help, I can now put Nagios into production and get rid of 
Big Brother.

% 09:46:29 kevino at moseley [libexec]: ./check_nt -h
Usage: check_nt -H host [-p port] [-s password|-S passwordfile] [-v 
variable] [-w warning] [-c critical] [-l params] [-d SHOWALL] [-t timeout]






More information about the Help mailing list