check_nt -> wrong -l argument

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
egburgoa
Posts: 1
Joined: Fri Aug 26, 2011 9:36 am

check_nt -> wrong -l argument

Post by egburgoa »

Hello....

I try to chek the disk "c" with the command from the shell

/usr/lib/nagios/plugins/check_nt -H xxx.xxx.xxx.xxx -v USEDDISKSPACE -p 12489 -l c

and works fine....but the service defined in nagios when execute the command return the error "wrong -l argument"

This is the definition of service is

define service{
use generic-service
hostgroup_name SERVERS
service_description Drive C
check_command check_nt!USEDDISKSPACE!-l c
normal_check_interval 10
retry_check_interval 360
notification_interval 720
notification_options w,c
}

The version of Nagios core is 3.2.1

Why the nagios send the error ??

Thanks.

Emilio G. Burgoa
egburgoa@hotmail.com
San Juan - Argentina
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: check_nt -> wrong -l argument

Post by SDohmen »

I had the same problem on several nagios installations. What i did to resolve the problem is the following:

Open nt.cfg (/etc/nagios-plugins/config/nt.cfg)

The first check_nt command should say:
define command {
command_name check_nt
command_line /usr/lib/nagios/plugins/check_nt -H '$HOSTADDRESS$' -v '$ARG1$'
}

Change the command_line too:
command_line /usr/lib/nagios/plugins/check_nt -H '$HOSTADDRESS$' -p 12489 -v '$ARG1$' '$ARG2$'

Save and reload nagios. That should fix the problem (at least it did for me)
Locked