Nagios hosttemplate inheritance

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
grayloglearn
Posts: 222
Joined: Thu Jul 06, 2017 8:55 am

Nagios hosttemplate inheritance

Post by grayloglearn »

Hi Team,

I want to implement "A" template inheritance to "B" Template.

Step 1) I have created the cpu_load, memory services and added to " C" Hostgroup.
Step 2) I have created the httpd,mysqld services and added to "D" Hostgroup.

step 3) I will create one host template "resouces" and used "generic-host_template" and "C" hostgoup added(cpu_load, memory) to resouces template.
Now i created Testing1 host and added "resource" template to Testing1 host (then automatically cpuload,memory services will add to Testing1 host)

step 4) I will create one host template that is "services_status" and used "generic-host_template" and "D" hostgoup added( httpd,mysqld)
Now i created Testing2 host and added "services_status" template to Testing2 (then automatically httpd,mysqld services will add to Testing2 host)

Now my intention is "resource" template services should inherit to "service_status" template

While i am adding the new host i add the Service_status template then (cpuload, memory,httpd,mysqld) Services should add to Testing2 server.
User avatar
mbellerue
Posts: 1403
Joined: Fri Jul 12, 2019 11:10 am

Re: Nagios hosttemplate inheritance

Post by mbellerue »

I don't see why this wouldn't work. There is a document on object inheritance from the Nagios Core perspective. That should give the nitty gritty on how this all works.
https://assets.nagios.com/downloads/nag ... tance.html

I think the most relevant section for you is going to be Inheritance Chaining.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked