<div dir="ltr">Thank you very much Mark. That helps a lot. I draw the whole thing out on paper first before I start messing with the files. I already crashed the service by putting a typo into the windows.cfg.</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Dec 24, 2014 at 11:03 AM, Frost, Mark {BIS} <span dir="ltr"><<a href="mailto:mark.frost1@pepsico.com" target="_blank">mark.frost1@pepsico.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="EN-US" link="blue" vlink="purple">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Justin,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Nagios (and thus Naemon) don’t care where those live. Essentially all that host, hostgroup, contact, service, etc stuff is a collection of object definitions.
Most of them refer to each other in some way. Nagios/Naemon cares that those references between objects are all complete. So if a service definition references a host, there has to be a definition for that host object for it somewhere that it can read.
So it doesn’t care where if finds the definitions as long as they represent a cohesive configuration and there are no missing bits.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I’ve seen people make things in a variety of different ways. When I first started, I saw one big configuration file. As things grew, that made less sense.
things got split into separate files by type (i.e. all hosts in their own definition file). As things grew further, even that made a little less sense so we broke things up into logical directories that matched what things we were monitoring and each of those
directories had their own individual files for hosts, etc.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">So really, the only thing that matters is that it makes sense to you and is maintainable by you. If you look at the naemon.cfg file you’ll see that there’s
a couple of different ways to make sure it finds your config files. You can either list them out one at a time with the cfg_file= directives, or you can point it to a whole tree of *.cfg files that Naemon will recurse into with the cfg_dir= directive.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Hope that helps.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Mark<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Naemon-users [mailto:<a href="mailto:naemon-users-bounces%2Bmark.frost1" target="_blank">naemon-users-bounces+mark.frost1</a>=<a href="mailto:pepsico.com@monitoring-lists.org" target="_blank">pepsico.com@monitoring-lists.org</a>]
<b>On Behalf Of </b>Justin Laughlin<br>
<b>Sent:</b> Wednesday, December 24, 2014 11:55 AM<br>
<b>To:</b> <a href="mailto:naemon-users@monitoring-lists.org" target="_blank">naemon-users@monitoring-lists.org</a><br>
<b>Subject:</b> [naemon-users] Naemon Sample Configuration Files<u></u><u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal">Hello Group,<u></u><u></u></p>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">I am new to Naemon/Nagios and heavily dependent on the documentation. I am following the example in<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"><a href="http://www.naemon.org/documentation/usersguide/monitoring-windows.html" target="_blank">http://www.naemon.org/documentation/usersguide/monitoring-windows.html</a><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">It shows separate config files for "hostgroups", "commands" and "services". In the sample config files that ship with the 0.8 build these are all combined into the hosts.conf file. Which model should I follow? I am going to have a few
dozen hosts to monitor at first along with some switches, a SAN, and some firewalls. It seems more logical to make them separate files but maybe there is a reason they are all in one. Is it somehow more efficient or was it done for expediency just to show
a few examples?<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Thank you!<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Justin<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div>
</div>
</div>
</blockquote></div><br></div>