[op5-users] merlin setup

Russell Jennings russ at geekwhiz.com
Thu Oct 29 21:22:43 CET 2009


So, I finally got all my merlin logisitics out.

on the noc:
each poller has it's own directory (though if i had multiple pollers  
per site, they would both share the same). this directory is where  
host/service definitions, templates and etc exist. It is setup in the  
following way:

n.* files are sync'd over to the node
.txt files are renamed on the node to become config files

this allows me to have 1 file, like n.server1.cfg, which houses all  
relevant definitions for that server (granted, there are other ways to  
handle definitions, this is just how i do it to keep it modular) which  
can also get sync'd over to the node. so, both nagios instances can  
read this file and not hiccup.

all other information is housed in a localdef.cfg file (which outlines  
templates and such) and also a n.nodenef.txt file, which has similar  
definitions so that i can use the same template in the server's file,  
and both local and remote have those definitions available. the local  
definitions are all defined as passive cehcks, and the remote ones are  
all defined as active.

on the poller:
a script runs every 5 minutes which rsync's the directory (only n.*  
files) and also, another rsync that does the commands.cfg file one  
level up the tree, since all nodes should have the same config.  
(though i just realized i should sync libexec too...)
the script then renames all txt files to cfg, and then restarts nagios.
Command exit codes are checked each step of the way, and a passive  
check is fired off if one fails in some way. otherwise it submits an  
OK passive check result at the end.

it's not ideal, but it'll work.

Cheers,
Russell


More information about the op5-users mailing list