Newbie would like to learn templating

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
wyoder
Posts: 50
Joined: Mon Dec 29, 2014 3:21 pm
Location: Raleigh, NC
Contact:

Newbie would like to learn templating

Post by wyoder »

This question may relate to an earlier question about modifying the Linux Server monitoring wizard, since it appears that the Configuration Monitoring Wizards use templates behind the curtains.

My understanding is that templating is the way to go for cranking out cookie-cutter configurations. I've looked at the CCM-->Configure-->Templates items (Host, Service, and Contact) and they look helpful, but I don't know how to create, modify, or apply them. Could you point me at some documentation or a tutorial for using templates?

Thanks,
--Bill
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Newbie would like to learn templating

Post by jdalrymple »

Templating isn't necessarily what you need to study so much as "object inheritance." This document is for an older version of core but almost all principles still apply in the same way today on XI as they did then in core:

http://nagios.sourceforge.net/docs/3_0/ ... tance.html

Also worth mentioning - the cookie-cutter approach is also well serviced by leveraging hostgroups a lot, and even servicegroups - some. Start with that document and you should have a more clear understanding of what goes on under the hood in XI with templates and inheritance.
wyoder
Posts: 50
Joined: Mon Dec 29, 2014 3:21 pm
Location: Raleigh, NC
Contact:

Re: Newbie would like to learn templating

Post by wyoder »

Thanks for the pointer to the inheritance document and your suggestion about hostgroups. I appreciate your help.
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Newbie would like to learn templating

Post by jdalrymple »

Absolutely happy to help.

Were you able to understand how that all works and create a strategy that fits your needs? If so we'll go ahead and lock this topic. If you need further help we're happy to leave it open.
wyoder
Posts: 50
Joined: Mon Dec 29, 2014 3:21 pm
Location: Raleigh, NC
Contact:

Re: Newbie would like to learn templating

Post by wyoder »

Yes, we are good. Please lock this topic.

Thanks for all your help.
--Bill Yoder
Locked