Check host and service notification contacts
Check host and service notification contacts
Is there a quick and easy method to check the notification contacts and/or contact groups for hosts and services? I want to make sure all hosts and services have the proper contacts/contactgroups assigned for notifications.
Re: Check host and service notification contacts
If you run this:
it will tell you if any hosts or services are missing contacts. However it is not possible for Nagios to tell you if you have the wrong contact assigned since our software doesn't have any knowledge of your notification needs.
You can look under /usr/local/nagios/var/objects.cache for a compiled list of all the objects in your setup, but it might take some parsing to grab the host/service name and the contacts.
Code: Select all
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfgYou can look under /usr/local/nagios/var/objects.cache for a compiled list of all the objects in your setup, but it might take some parsing to grab the host/service name and the contacts.
Former Nagios employee
Re: Check host and service notification contacts
Sorry, I might not have been real clear.
I want to check and see what contact or contactgroups are assigned to each host, service or hostgroup. Is that possible?
I want to check and see what contact or contactgroups are assigned to each host, service or hostgroup. Is that possible?
Re: Check host and service notification contacts
You can do this easily via the Bulk Modifications Tool, which is part of Nagios XI Enterprise Edition. Go to CCM->Bulk Modifications->Remove Contact (or Remove Contact Group)->select a contact/contactgroup from the "Contact"/"Contact Group" drop-down menu and click on "Find Relationships". After you are done, click on "Cancel".
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Check host and service notification contacts
I guess there is no "report" or means in which to export this information?
Re: Check host and service notification contacts
No, there isn't a report you that you can get this information easily.
This file, /usr/local/nagios/var/objects.cache has all of the information but it would have to be parsed to make it easier to get what you want.
This file, /usr/local/nagios/var/objects.cache has all of the information but it would have to be parsed to make it easier to get what you want.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Check host and service notification contacts
In addition to what tgriep said:
Not at this time but we have an internal feature request in place about adding this functionality (task id=761). I don't have an ETA, so I am not sure when/if this will be implemented. One more thing, I almost forgot, you don't even need Enterprise to view the relationships. You can go to CCM->Contacts/Contact Groups->and click on the "Relationship Info" button (the blue circle with white "i" in it).I guess there is no "report" or means in which to export this information?
Be sure to check out our Knowledgebase for helpful articles and solutions!