Time Period w/ Service Definitions using Hostgroup Name

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
OUberLord
Posts: 17
Joined: Wed Mar 25, 2015 8:31 am

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by OUberLord »

tmcdonald wrote:Services will automatically pick up the notification_period of a host if one is not set on the service. It is called Implied Inheritance:

http://nagios.sourceforge.net/docs/3_0/ ... nheritance
I had no idea this functionality existed; this seems exactly like what I am after. Let me dig into this, but in the mean time thank you for pointing this out.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by lmiltchev »

Let us know if this worked out for you. We will keep this topic open for a while.
Be sure to check out our Knowledgebase for helpful articles and solutions!
OUberLord
Posts: 17
Joined: Wed Mar 25, 2015 8:31 am

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by OUberLord »

This definitely worked, but there is an unexpected consequence. Though the services are inheriting the notification_period from their associated hosts, it is causing a bit of havoc when I run the pre-flight check:

Code: Select all

Warning: Service 'memory pages per sec' on host 'servername' has no check time period defined!
Warning: Service 'operating system' on host 'servername' has no check time period defined!
Warning: Service 'time' on host 'servername' has no check time period defined!
Warning: Service 'uptime' on host 'servername' has no check time period defined!
....
Is there a way that I can make the pre-flight check not flag warnings as such?
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by tmcdonald »

That would require a patch to Core, I am afraid. I can assure you though, those warnings (as well as most warnings in general) are pretty harmless, if annoying.
Former Nagios employee
OUberLord
Posts: 17
Joined: Wed Mar 25, 2015 8:31 am

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by OUberLord »

I figured as much, but also figured I'd ask just in case there was some lesser-known switch that I could flip on. Beyond that, I'm poking through the web interface to look at the resulting config for our hosts and services and it appears that it is exactly matching the anticipated settings. This seems like a rather elegant way of addressing the issue, so thanks again for pointing me towards the Implied Inheritance functionality.
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Time Period w/ Service Definitions using Hostgroup Name

Post by tgriep »

Is it alright to close this post?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked