[Nagiosplug-help] Creating a plugin

Claudio Nunes ca-nunes at criticalsoftware.com
Mon Aug 8 09:17:04 CEST 2011


Hi Robert, sorry for the late replay

command definition

define command {
       command_name                             check_nt
       command_line                             $USER1$/check_nt -H $HOSTADDRESS$ -p $USER7$ -s $USER8$ -v $ARG1$ $ARG2$
}



About using check_nt for host check instead of group service checks, all my hosts have those services and the idea is to monitor in every host those service,  i didn´t think about grouping, how do i get that?


Best Regards

Cláudio Nunes
________________________________________
De: Robert Marxreiter [rmarxreiter at web.de]
Enviado: quinta-feira, 4 de Agosto de 2011 17:59
Para: Nagios Plugin Help List
Assunto: Re: [Nagiosplug-help] Creating a plugin

Hello Claudio,

you'll have to post your command definition, too.

By the way - are you seriously using check_nt for the host check? You
should use service groups if you want to group service checks. Otherwise
you will get confused which service runs on which host.

Regards
- Robert

> Hello Robert
>
> Here is the host definition and service definition
>
>
> define host {
>         host_name                       pdcitems.mydomain
>         use                             windows-server
>         address                         192.168.1.40
>         check_command
> check_nt!iTems\\$control-manager-service-PDCITEMS-1!iTems\\$proxy-configurator-service-PDCITEMS-1!iTems\\$proxy-local-service-PDCITEMS-1!iTems\\$system-guard-service-PDCITEMS-1!MSSQL\\$iTEMS!!!
>         initial_state                   o
>         max_check_attempts              5
>         check_interval                  5
>         retry_interval                  1
>         check_period                    24x7
>         first_notification_delay        0
>         notification_options            d,u,r,f,s
>         notifications_enabled           1
>         register                        1
>         }
>
> AT CHECK COMMAND , are all the services i want to check and all of them
> contains the dollar symbol, noticed that i´m using \\$  i already tried
> \$$, \$ or $$ and none of them works, evertime i get check_nt could not
> parse arguments
>
> define service {
>         host_name                       pdcitems.mydomain
>         service_description             MSSQL
>         use
> xiwizard_windowsserver_nsclient_service
>         check_command
> check_xi_service_nsclient!critical!SERVICESTATE!-l MSSQL$iTEMS -d
> SHOWALL
>         max_check_attempts              5
>         check_interval                  5
>         retry_interval                  1
>         check_period                    xi_timeperiod_24x7
>         notification_interval           60
>         notification_period             xi_timeperiod_24x7
>         contacts                        claudio
>         _xiwizard                       windowsserver
>         register                        1
>         }
> ________________________________________
> De: Robert Marxreiter [rmarxreiter at web.de]
> Enviado: quarta-feira, 3 de Agosto de 2011 9:38
> Para: Nagios Plugin Help List
> Assunto: Re: [Nagiosplug-help] Creating a plugin
>
> Hello Claudio,
>
> I think the error comes from the extra space between "-" and "t".
> Additionally, you need to escape the "$" so the shell won't expand
> "$iTEMS" as a variable.
>
> Try
>
> ./check_nt -H myHostIP -p 12489 -s password -t 5 SERVICESTATUS -l
> 'MSSQL$iTEMS' -d SHOWALL
>
> Additionally, we'd need your command- and service definition to see
> whether there is some problem there.
>
> Regards
> - Robert
>
>> Hello Robert,
>>
>> I´m using check_nt to check service on my domain machines called
>> MSSQL$iTEMS
>>
>> i´m using check_nt here a full e.g on command line
>>
>> ./check_nt -H myHostIP -p 12489 -s password - t 5 SERVICESTATUS -l
>> MSSQL$iTEMS -d SHOWALL
>> check_nt: could not parse arguments
>>
>> Best Regards
>>
>> Cláudio Nunes
>> ________________________________________
>>
>> De: Robert Marxreiter [rmarxreiter at web.de]
>> Enviado: quarta-feira, 3 de Agosto de 2011 1:28
>> Para: nagiosplug-help at lists.sourceforge.net
>> Assunto: Re: [Nagiosplug-help] Creating a plugin
>>
>> Hello Claudio,
>>
>> please show us the command- and service definition for that check.
>>
>> Regards
>> - Robert
>>


------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Nagiosplug-help mailing list
Nagiosplug-help at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagiosplug-help
::: Please include plugins version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
________________________________
DISCLAIMER: This message is confidential and may contain privileged information. It is for use only by the people or entities to whom it is addressed. If you are not an intended recipient, you should not disclose, distribute, copy, print, rely on or otherwise make use of this message. If an addressing or transmission error has misdirected it to you we would be grateful if you would please notify the sender by return, before deleting it from your system.
________________________________
Are you controlling information disclosure? Decide what you need to keep secret and enforce it with csSECURE. See how at www.csSECURE.net.




More information about the Help mailing list