Template question

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
daveinvb
Posts: 67
Joined: Tue Jun 02, 2015 9:06 am

Template question

Post by daveinvb »

I've read the documentation regarding inheritance and I want to make sure I understand templates correctly.
I have multiple locations and multiple different types of items at each location. I want there to be alerts based off of the type and the location. Each item will also be in an Infrastructure host group and a Location host group.
I create two templates, 1 for infrastructure and 1 for location.
The Infrastructure template assigns to the host group, has all of the checks set up, and it also it also has notifications.
The location template assigns to the location host group, has everything else set to skip except for notifications
If the host goes down, will it notify everyone listed in both templates?

For example, if I have a Domain Controller at Plant A and a Domain Controller at Plant B.
I have templates Domain Controller (notifies me), Plant A (notifies Plant Manager A), and Plant B (notifies Plant Manager B)
Domain Controller A is assigned templates Domain Controller and Plant A.
Domain Controller B is assigned templates Domain Controller and Plant B.
Domain Controller A goes down, will it notify me AND Plant Manager A?
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Template question

Post by jdalrymple »

daveinvb wrote:I want to make sure I understand templates correctly.
I'm here to help - understanding this is the key difference between an elegant and clean deployment vs a barbarian/caveman deployment :)
daveinvb wrote:The location template assigns to the location host group, has everything else set to skip except for notifications
If the host goes down, will it notify everyone listed in both templates?
When you're assigning contacts in the host/service/host-template/service-template that is what the + in the lower left hand corner is for. If you click the + it will compliment the existing contacts coming down through the templating system. If you use the standard radio button it will replace those contacts. This typically is only important for hosts since *generally* service templates aren't in place. If they are though the same rules apply.
daveinvb wrote:Domain Controller A goes down, will it notify me AND Plant Manager A?
It's all about that little (+) radio button. You've got it though otherwise.
daveinvb
Posts: 67
Joined: Tue Jun 02, 2015 9:06 am

Re: Template question

Post by daveinvb »

Awesome. So can the + radio button be set on all the templates to make sure nothing is overwritten? And what should I do for the second template (location) regarding the notification period? Can I leave all of the other things blank and have them picked up from the first template (infrastructure)?
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Template question

Post by jdalrymple »

Your logic is sound.

Be careful not to inadvertantly override your notification period at the contact. Contact wins over service/host in that regard.
daveinvb
Posts: 67
Joined: Tue Jun 02, 2015 9:06 am

Re: Template question

Post by daveinvb »

Okay. But the contact will not override the entire host will it? Say I have the template set to 24x7 and one contact in the group is 9-5, everyone else will still be notified at night right?
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Template question

Post by ssax »

That is correct.
daveinvb
Posts: 67
Joined: Tue Jun 02, 2015 9:06 am

Re: Template question

Post by daveinvb »

Awesome. Thanks.
Locked