I've got various host groups that inherit from each other to get a "complete package" of checks for hosts.
The hostgroup relationship I have looks like the following:
Linux -> Nav-Common -> Dispatch-Common -> NFP-Common -> NFP-Live
I've set things up so that my hosts use the end groups only, in this case "NFP-Live". There are many other branches involving the above, this is just an example.
Linux is the base of many of the hostgroups I have and one of it's services is the check_users. The default being warning 5, critical 10. In one of my "NFP-Live" hosts has typicall 15-20 people logged in so I'm always getting a warning or a error for that host.
I really don't want to change the default values for the check_users that's part of the "Linux" hostgroup. Is there any way I can override the values for warning/critical for a specific hostgroup or host that inherits from the Linux hostgroup? The trouble right now is, even if I create a new service check for this specific host with a different configuration file, because of inheritance I'll still get the warning that's configured for all Linux machines. If I remove the check from the Linux hostgroup, I'd have to add multiple copies of the same check to various other groups and that makes things messy and harder to troubleshoot if/when anything goes wrong or needs to be tweaked.
Appreciate your input, thank you
Inheritance and possible overrides
Re: Inheritance and possible overrides
I would look at going an exclusion.
You can exclude one or more hosts from the service->hostgroup assignment, and then assign a service to one or more individual hosts that have the thresholds that you want, you should be able to achieve what you're looking for.
http://nagios.sourceforge.net/docs/3_0/ ... ricks.html
Code: Select all
define service{
host_name HOST1,HOST2,!HOST3,!HOST4,...,HOSTN
hostgroup_name HOSTGROUP1,HOSTGROUP2,!HOSTGROUP3,!HOSTGROUP4,...,HOSTGROUPN
service_description SOMESERVICE
other service directives ...
}http://nagios.sourceforge.net/docs/3_0/ ... ricks.html