Hello Folks,
Is there a possibility to stop monitoring and alerting on service down, if the host is intentionally brought down. I mean at our environment the servers host are not always up and running, so we don't want the alerts to be generated when the host is down.
All the services should be monitored only when the associated host is up and running.
Thanks in advance.
Regards,
Swapnil
Monitoring Services only when the Host is up
Re: Monitoring Services only when the Host is up
I believe dependencies are what you are looking for. Check this out and let us know.
Former Nagios Employee.
me.
me.
Re: Monitoring Services only when the Host is up
Does that mean I can have a Service dependent on the Host status?
Re: Monitoring Services only when the Host is up
That would be one way to do it, but depending on your XI version you might have a better option. I added a configuration setting to the Nagios Core engine that will stop all checks and alerts on a service if the host is down. You can read about it here:
https://github.com/NagiosEnterprises/na ... 724930a3e7
Basically, if you are on Core 4.1.1 or later you can add host_down_disable_service_checks=1 to your /usr/local/nagios/etc/nagios.cfg and then run service nagios restart for it to take effect. There will be no status updates if services are skipped in this way, just a log message, so keep that in mind.
https://github.com/NagiosEnterprises/na ... 724930a3e7
Basically, if you are on Core 4.1.1 or later you can add host_down_disable_service_checks=1 to your /usr/local/nagios/etc/nagios.cfg and then run service nagios restart for it to take effect. There will be no status updates if services are skipped in this way, just a log message, so keep that in mind.
Former Nagios employee
Re: Monitoring Services only when the Host is up
Thanks a lot, it worked 
We had latest version of CCM.
Cheers,
Swapnil
We had latest version of CCM.
Cheers,
Swapnil
Re: Monitoring Services only when the Host is up
Glad to hear it! Are we all good to close out this ticket?
Former Nagios employee
Re: Monitoring Services only when the Host is up
Hello,
Everything was working perfect with existing hosts and services. However when we added new hosts, the service alerts for these new hosts started to appear even when the hosts are intentionally brought down. Please suggest.
We want to monitor the services only when the hosts are up.
Regards,
Swapnil
Everything was working perfect with existing hosts and services. However when we added new hosts, the service alerts for these new hosts started to appear even when the hosts are intentionally brought down. Please suggest.
We want to monitor the services only when the hosts are up.
Regards,
Swapnil
Re: Monitoring Services only when the Host is up
You could put the hosts into scheduled downtime before you bring them down - this should suppress all notifications for them (if properly configured).
This doc was written for Core but applies to XI as well:
https://assets.nagios.com/downloads/nag ... ntime.html
If the hosts go down for other reasons, then read this description from Box293 to start with https://support.nagios.com/forum/viewto ... 10#p103689
This doc was written for Core but applies to XI as well:
https://assets.nagios.com/downloads/nag ... ntime.html
If the hosts go down for other reasons, then read this description from Box293 to start with https://support.nagios.com/forum/viewto ... 10#p103689
Be sure to check out the Knowledgebase for helpful articles and solutions!
Re: Monitoring Services only when the Host is up
Hi,
The setting you provided worked, we have the services monitored only when the hosts are up and running.
However this is now impacting the availability reporting of the servers, because the servers which are supposed to be always ON and goes down by incident doesn't reflect the downtime in the Availability Reporting. I mean even if the server was down for couple of hours in that particular month, it still shows that it was 100% available through ping service, because ping server is checked only when the server is up.
Please provide a workaround for this problem.
Regards,
Swapnil
The setting you provided worked, we have the services monitored only when the hosts are up and running.
However this is now impacting the availability reporting of the servers, because the servers which are supposed to be always ON and goes down by incident doesn't reflect the downtime in the Availability Reporting. I mean even if the server was down for couple of hours in that particular month, it still shows that it was 100% available through ping service, because ping server is checked only when the server is up.
Please provide a workaround for this problem.
Regards,
Swapnil
Re: Monitoring Services only when the Host is up
There is no workaround to that - if the services are checked only when the host is up. Then again it could be a matter of interpretation = knowing that services are only checked when a host is up and you see services are down, then you 'll know they are not unavailable because their host is down, but because they are really down for whatever the reason and this is actually more accurate, when analyzing services.
When running your reports, choose the option "Hide Scheduled Downtime" if you do not want scheduled downtime counted as 'real' downtime.
When running your reports, choose the option "Hide Scheduled Downtime" if you do not want scheduled downtime counted as 'real' downtime.
You do not have the required permissions to view the files attached to this post.
Be sure to check out the Knowledgebase for helpful articles and solutions!