Why are there "commands"?

Marc Powell marc at ena.com
Fri Aug 28 20:26:56 CEST 2009


On Aug 28, 2009, at 12:18 PM, David Dyer-Bennet wrote:

> I don't really understand the purpose / utility of the "command"  
> level of
> abstraction in Nagios configuration.  (2.10; we're still on Centos  
> 4.7).
>
> To define a new service to check particular Windows web services we've
> written, I define a service, and then it has to refer to a command,  
> and
> over in the command I have to hard-code the parameters needed to  
> test this
> specific service -- so in fact I need a separate command for each  
> service.

Can you give an example? I think you just don't know the flexibility  
that is available. You shouldn't need to hard code much except those  
things that are constant. Nagios has extensive macro capabilities and  
allows you to pass much data from service definitions and other parts  
of nagios to the commands being run. This allows you to re-use generic  
command definitions between many different services that check similar  
things. Have you read the Macro documentation, particularly passing  
arguments to commands?

> As a broader question, are there documents that give more of a logical
> overview of Nagios, explaining how and why things are broken up and  
> how
> they work together?

The published Documentation? Beyond that, ask specifics but be sure  
you've read the documentation first.

--
Marc


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
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