Error when trying to add a check_netapp check

Marc Powell marc at ena.com
Wed Sep 3 16:30:36 CEST 2008


On Sep 3, 2008, at 8:40 AM, Page, Jeremy wrote:

> I am sorry for asking what I am sure is a very basic question, but  
> I’ve inherited my Nagios system and I’m trying to get a disk space  
> check in ASAP. Here is the error I’m getting:
>
> Checking services...
> Error: Service check command 'check_netapp -H gvr- 
> array02.gilbarco.com -C pubic -v DISKUSED -w 15 -c 10' specified in  
> service 'Disk space' for host 'gvr-array02' not defined anywhere!
>         Checked 1386 services.
>
> And here is the check command it’s choking on:
>
>   check_command                   check_netapp -H gvr- 
> array02.gilbarco.com -C pubic -v DISKUSED -w 15 -c 10
>         max_check_attempts              5
>         normal_check_interval           5
>         retry_check_interval            1
>         notification_interval           120
>         contact_groups                  admins
>         notification_period             24x7
>         }
>
> Where have I gone wrong? I know this command works if I run it from  
> the command line, so does that mean I need to do something in  
> another config file to define this check

The check_command in a service{} or host{} definition is a reference  
to a corresponding command{} definition, not the actual command line  
that would be run. You should use your current configs as a reference  
for how this is done as well as this documentation --

http://nagios.sourceforge.net/docs/2_0/xodtemplate.html#command
http://nagios.sourceforge.net/docs/2_0/xodtemplate.html#service

and to simplify configuration --

http://nagios.sourceforge.net/docs/2_0/macros.html

It will probably look something like --

	...
  	 check_command                   check_netapp
         max_check_attempts              5
         normal_check_interval           5
         retry_check_interval            1
         notification_interval           120
         contact_groups                  admins
         notification_period             24x7
         }

define command {
	command_name	check_netapp
	command_line	$USER1$/check_netapp -H $HOSTADDRESS$ -C pubic -v  
DISKUSED -w 15 -c 10
}

--
Marc


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list