<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
make sure you have hostgroup definitions setup ...<BR>
<BR>
define hostgroup{<BR> hostgroup_name DUMMY2<BR> alias Dummy2 Servers<BR>}<BR>
<BR>
Also NOTE in my test host, I have the line:<BR>
use dummy-hosts1,dummy-hosts2 <BR>
<BR>
Each defines group DUMMY1 and DUMMY2 respectively...<BR>
<BR>
after restarting Nagios, the host is only a member of the DUMMY2 group.<BR>
<BR>
definining options like this the inheritance "overrides" settings with the values of the subsquent templates listed. so the group of the last template listed is the one used.<BR><BR>-- <BR>Mat W. - <A href="http://www.techadre.com/">http://www.techadre.com</A><BR><BR><BR> <BR>> Date: Wed, 23 Sep 2009 11:05:11 -0400<BR>> From: jtata@gpworldwide.com<BR>> To: nagios-users@lists.sourceforge.net<BR>> Subject: [Nagios-users] Object Definitions with Multiple Templates<BR>> <BR>> I am having a problem getting Nagios to accept multiple templates in<BR>> object definitions. <BR>> <BR>> Here is an example. I have two templates defined in templates.cfg: <BR>> <BR>> <BR>> define host {<BR>> use host #This is my "generic" template with<BR>> all my basic options in it<BR>> name prod-host<BR>> hostgroups prod_servers #Production server host<BR>> group<BR>> notification_period 24x7<BR>> register 0<BR>> }<BR>> <BR>> <BR>> define host {<BR>> use host<BR>> name win-host<BR>> hostgroups win_servers #Windows server host group<BR>> register 0<BR>> }<BR>> <BR>> Defining an object with either of these templates works fine. However<BR>> what I really need to do is: <BR>> <BR>> define host {<BR>> use prod-host,win-host <BR>> name windows-server<BR>> address 192.1.1.1<BR>> alias My Windows Production Server<BR>> }<BR>> <BR>> Instead when I run nagios -v I get:<BR>> <BR>> "Error: Template 'prod-host,win-host' specified in host definition could<BR>> not be not found" etc.<BR>> <BR>> http://nagios.sourceforge.net/docs/3_0/objectinheritance.html indicates<BR>> this should be possible, and that the resulting object should have<BR>> properties of both hosts, but something isn't working. Am I not<BR>> defining something correctly or is this possibly a bug/documentation<BR>> error?<BR>> <BR>> Thanks<BR>> <BR>> <BR>> ------------------------------------------------------------------------------<BR>> Come build with us! The BlackBerry® Developer Conference in SF, CA<BR>> is the only developer event you need to attend this year. Jumpstart your<BR>> developing skills, take BlackBerry mobile applications to market and stay <BR>> ahead of the curve. Join us from November 9-12, 2009. Register now!<BR>> http://p.sf.net/sfu/devconf<BR>> _______________________________________________<BR>> Nagios-users mailing list<BR>> Nagios-users@lists.sourceforge.net<BR>> https://lists.sourceforge.net/lists/listinfo/nagios-users<BR>> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. <BR>> ::: Messages without supporting info will risk being sent to /dev/null<BR> <br /><hr />Hotmail® has ever-growing storage! Don’t worry about storage limits. <a href='http://windowslive.com/Tutorial/Hotmail/Storage?ocid=TXT_TAGLM_WL_HM_Tutorial_Storage_062009' target='_new'>Check it out.</a></body>
</html>