[Nagiosplug-help] Nsclient++ Parameters

D.Parise at iaea.org D.Parise at iaea.org
Tue Feb 27 13:33:50 CET 2007


Maybe if I allow_arguments=1 it works better :-)))
 
Damn I have lost two days on this stupid thing!
 
Ciao
 
davide
 

________________________________

From: nagiosplug-help-bounces at lists.sourceforge.net
[mailto:nagiosplug-help-bounces at lists.sourceforge.net] On Behalf Of
D.Parise at iaea.org
Sent: 27 February 2007 13:10
To: nagiosplug-help at lists.sourceforge.net
Subject: Re: [Nagiosplug-help] Nsclient++ Parameters


Has anyone any idea on my problem ?
 
if I define a command in the NSC.ini of windows like :
 
check_file_size=inject CheckFileSize ShowAll MaxWarn=1024M $ARG1$
File:WIN=c:\WINDOWS\*.*
 
and a command in Nagios as:
 
#NRPE Test
define command {
        command_name    check_nrpe_win_size
        command_line    $USER1$/check_nrpe -H $HOSTADDRESS$ -p 5666 -c
check_file_size -a $ARG1$
        }

and the service template as:
 
define service{
        name                            nrpe_drive-tmpl
        use                             remote-service
        service_description             NRPE Drive Status
        check_command
check_nrpe_win_size!'MaxCrit=8192M'
        register                        0
        }
 
It should result in the client receiving:
 
check_file_size=inject CheckFileSize ShowAll MaxWarn=1024M MaxCrit=8192M
File:WIN=c:\WINDOWS\*.* 
 
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs
for error messages.
 
And in the windows log:
 
2007-02-27 12:51:59: error:.\NRPEListener.cpp:308: NRPEException:
Request contained arguments (not currently allowed).
 
If I define the command in NSC.ini as:
 
check_file_size=inject CheckFileSize ShowAll MaxWarn=1024M MaxCrit=8192M
File:WIN=c:\WINDOWS\*.*
 
and I call it as:
#NRPE Test
define command {
        command_name    check_nrpe_win_size
        command_line    $USER1$/check_nrpe -H $HOSTADDRESS$ -p 5666 -c
check_file_size 
        }

and the service template as:
 
define service{
        name                            nrpe_drive-tmpl
        use                             remote-service
        service_description             NRPE Drive Status
        check_command                   check_nrpe_win_size
        register                        0
        }
 
everything works fine, but I don't want to define the "tuning
parameters"on the clients. It would be a nightmare to change them later.
By the way Nagios is version 2.7 and the client is the last version
released on 2006-12-02
 
Regards,
 
Davide
 
 


________________________________

From: nagiosplug-help-bounces at lists.sourceforge.net
[mailto:nagiosplug-help-bounces at lists.sourceforge.net] On Behalf Of
D.Parise at iaea.org
Sent: 26 February 2007 17:59
To: nagiosplug-help at lists.sourceforge.net
Subject: [Nagiosplug-help] Nsclient++ Parameters



Dear All, 

        There is something I do not understand: 

1) I have NSClient++ running on a windows Xp machine. 
2) I define a command in the NSC.ini 

[NRPE Handlers] 
check_uptime=inject checkUpTime MinWarn=1d MinWarn=12h 

3) I call the command with 

./check_nrpe -H 161.5.116.1 -c check_uptime 

and everything works fine 

The question is: how should I define the command in the in the NSC.ini
to read the parameters through the -a option the net check_nrpe command
?

Regards 


Davide Parise 
Safeguards Systems Analyst 
Division of Technical Support (SGTS) 
International Atomic Energy Agency (IAEA) 
Tel.: +43 1 2600 26496 (Office) 
Fax: +43 1 2600 29317 (21st Floor) 
e-mail: d.parise at iaea.org 



This email message is intended only for the use of the named recipient.
Information contained in this email message and its attachments may be
privileged, confidential and protected from disclosure. If you are not
the intended recipient, please do not read, copy, use or disclose this
communication to others. Also please notify the sender by replying to
this message and then delete it from your system. 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/help/attachments/20070227/3ba547d7/attachment.html>


More information about the Help mailing list