All standard VM checks dependent on NRPE service change

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
philip.ianni
Posts: 29
Joined: Tue Dec 29, 2015 12:35 pm

All standard VM checks dependent on NRPE service change

Post by philip.ianni »

I've read documentation but I'm afraid Im not doing this right.

I'm running Nagios XI and Im looking to make the services on a particular host be dependent on the services tied to that host.

In in Service Dependancies, I've added all the relevant hostgroups, and NRPE.

I've left dependent hosts and hostgroups blank, then I've put the names of the other services that depend on NRPE in "Service Dependancies".

Is this correct?
You do not have the required permissions to view the files attached to this post.
bwallace
Posts: 1145
Joined: Tue Nov 17, 2015 1:57 pm

Re: All standard VM checks dependent on NRPE service change

Post by bwallace »

This looks right- if I'm following you correctly. Is there any particular step here which arouses suspicion and doubt?
Here is a 78 second tutorial on configuring Service Dependencies, perhaps it will clear a few things up if you haven't already seen it.
https://www.youtube.com/watch?v=U_vWdRtCtPI
Be sure to check out the Knowledgebase for helpful articles and solutions!
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: All standard VM checks dependent on NRPE service change

Post by lmiltchev »

philip.ianni, go to CCM->Advanced->Service Dependencies, click on the "View Text Config" actions button on the right (the diskette icon), and show us the text config.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: All standard VM checks dependent on NRPE service change

Post by Box293 »

https://support.nagios.com/kb/article.php?id=505

Make sure your master service goes down HARD before the dependent services.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
philip.ianni
Posts: 29
Joined: Tue Dec 29, 2015 12:35 pm

Re: All standard VM checks dependent on NRPE service change

Post by philip.ianni »

My only doubt is when I actually save my settings and apply my configuration, then go back that same configuration, it seems Nagios is automatically removing all dependant service except my CPU stats.

To verify that this is just not a visual glitch, by viewing "/usr/local/nagios/etc/servicedependencies.cfg" I can see that CPU stats is indeed the only service listed in this.

define servicedependency {
# config_name NRPE Dependency for Trusted, Governed, and Linux Tools
dependent_service_description CPU Stats
hostgroup_name Governed VMs,Linux Tools Vms,SHS - UAT - HOSTS [formerly QA-NEXT],Trusted Environment
service_description NRPE
inherits_parent 1
execution_failure_criteria w,u,c,p,
notification_failure_criteria w,u,c,p,
dependency_period 24x7

}


Maybe I have to make a dependency individually for each base VM service?
You do not have the required permissions to view the files attached to this post.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: All standard VM checks dependent on NRPE service change

Post by Box293 »

Dependencies can get a bit confusing, lets check this first.

Can you do the following.

Look at the file /usr/local/nagios/var/objects.cache

Search for your dependencies in this file. Can you post them please, there may be more than one.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
philip.ianni
Posts: 29
Joined: Tue Dec 29, 2015 12:35 pm

Re: All standard VM checks dependent on NRPE service change

Post by philip.ianni »

Code: Select all

define servicedependency {
        host_name       subversion - inhoci03
        service_description     NRPE
        dependent_host_name     subversion - inhoci03
        dependent_service_description   CPU Stats
        dependency_period       24x7
        inherits_parent 1
        notification_failure_options    w,u,c,p
        }
[/icode]

The file basically contains one of the above for each host configured in my system. This is a good sign however its only for the "CPU Stats" service, and now I want to do it for the rest of them. Im guessing that you cant handle more than one dependent service in the above declaration alone, you have to define another dependency for each of my services. In other words, in the XI gui, keep copying the existing service dependency and replace CPU stats with another base VM check until I have all services covered?

Thanks
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: All standard VM checks dependent on NRPE service change

Post by Box293 »

What version of XI is this? I want to see if this is a bug.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
philip.ianni
Posts: 29
Joined: Tue Dec 29, 2015 12:35 pm

Re: All standard VM checks dependent on NRPE service change

Post by philip.ianni »

This is on 5.2.2

I believe the same thing is happening on our older Nagios box as well (version 2014R2.7)
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: All standard VM checks dependent on NRPE service change

Post by lmiltchev »

The file basically contains one of the above for each host configured in my system. This is a good sign however its only for the "CPU Stats" service, and now I want to do it for the rest of them. Im guessing that you cant handle more than one dependent service in the above declaration alone, you have to define another dependency for each of my services. In other words, in the XI gui, keep copying the existing service dependency and replace CPU stats with another base VM check until I have all services covered?
This shouldn't be the case. I am not able to recreate the issue. I was able to add a few dependent services under the CCM with "one go". Here's what my service dependency config looks like:

Code: Select all

define servicedependency {
	#	config_name	test
		dependent_host_name           		CentOS6-NRPE
		dependent_service_description 		/ Disk Usage,APICHECK,CPU Stats,Load,Open Files
		host_name                     		CentOS6-NRPE
		service_description           		Ping
		inherits_parent               		1
		execution_failure_criteria    		w,c,
		notification_failure_criteria 		w,c,
		dependency_period             		24x7

}
Are your services added to more than one host, hostgroup, or a service group? Can you post the service configs for a review?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked