Assuming you wanted to see one of the hosts config file, and not the actual Nagios server.
###############################################################################
#
# Host configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2015-09-09 11:24:10
# Version: Nagios 3.x config file
#
# --- DO NOT EDIT THIS FILE BY HAND ---
# Nagios QL will overwite all manual settings during the next update
#
###############################################################################
define host {
host_name SYD01SQL09
use xiwizard_windowsserver_host
address 10.81.174.159
hostgroups SQL-Servers,SYD01
max_check_attempts 5
check_interval 5
retry_interval 1
check_period xi_timeperiod_24x7
contact_groups L3_EAlert_Group,L3_SMSAlert_Group
notification_interval 60
notification_period xi_timeperiod_24x7
first_notification_delay 0
notification_options d,u,r,f,s
notifications_enabled 1
icon_image win_server.png
statusmap_image win_server.png
_xiwizard windowsserver
register 1
}
###############################################################################
#
# Host configuration file
#
# END OF FILE
#
###############################################################################
Unexpected Notification Behavior
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: Unexpected Notification Behavior
So I believe the issue is this in the hosts config file:
contact_groups L3_EAlert_Group,L3_SMSAlert_Group
The contact group defined on the host object is being inherited through to the service.
Try this:
Create a Contact Group called "No Contacts" with no contacts assigned to it
Save it and Apply Config
Go to the service
Alert Settings tab
Click Manage Contactgroups button
Add the "No Contacts" group to the right and make sure "standard" is selected
Close
Save
Apply Config
Does this fix your problem?
contact_groups L3_EAlert_Group,L3_SMSAlert_Group
The contact group defined on the host object is being inherited through to the service.
Try this:
Create a Contact Group called "No Contacts" with no contacts assigned to it
Save it and Apply Config
Go to the service
Alert Settings tab
Click Manage Contactgroups button
Add the "No Contacts" group to the right and make sure "standard" is selected
Close
Save
Apply Config
Does this fix your problem?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Unexpected Notification Behavior
Just to clarify this. By assigning the service to a no contact group with standard selected, would this mean that the service will inherit the host notifications?
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: Unexpected Notification Behavior
It means the service will NOT inherit the contactgroup from the host object. The contacts directive on the host and service are independent of the contactgroup directive.
Additive means combine the host and service object, null means do nothing and standard does not inherit.
When standard is selected but there are no contactgroup objects assigned it would inherit the host object, because the service definition does not end up with a contact group directive.
You could try setting the contactgroup option to null on the service as well (without selecting any contactgroup). I think that would do the same thing as selecting an empty contactgroup.
Additive means combine the host and service object, null means do nothing and standard does not inherit.
When standard is selected but there are no contactgroup objects assigned it would inherit the host object, because the service definition does not end up with a contact group directive.
You could try setting the contactgroup option to null on the service as well (without selecting any contactgroup). I think that would do the same thing as selecting an empty contactgroup.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Unexpected Notification Behavior
I see. Thanks for this.
I've done just that but now I'm not seeing any alerts for this service. If this service is now not inheriting from host group, but has no contacts assigned to it. Wouldn't this mean that there will be no notifications sent as there is no recipient?
I originally thought that assigning a contact or contact group to a service, and set the contact or contact group to NULL, the service would not inherit host group and will use its own notification settings.
I've done just that but now I'm not seeing any alerts for this service. If this service is now not inheriting from host group, but has no contacts assigned to it. Wouldn't this mean that there will be no notifications sent as there is no recipient?
I originally thought that assigning a contact or contact group to a service, and set the contact or contact group to NULL, the service would not inherit host group and will use its own notification settings.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: Unexpected Notification Behavior
If the service does not have any contacts assigned and the contactgroups for the service is set to null then it would still inherit contacts from the host object, just not contactgroups. However if the host object has no contacts then you will receive no notifications.jamesc23 wrote:I've done just that but now I'm not seeing any alerts for this service. If this service is now not inheriting from host group, but has no contacts assigned to it. Wouldn't this mean that there will be no notifications sent as there is no recipient?
I believe null means "use none" (separate setting for contacts and contactgroups) and whatever contacts or contactgroups you assigned will be ignored.jamesc23 wrote:I originally thought that assigning a contact or contact group to a service, and set the contact or contact group to NULL, the service would not inherit host group and will use its own notification settings.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Unexpected Notification Behavior
I see. I think I misunderstood the whole concept a bit.
Originally, I had a contact assigned to this service only, and not a contact group. I've just tried to add a test contact to a test contact group and assign the test contact group to this service and it seems like it's working.
I will keep an eye on this for the next few days to see how it's going.
Thanks for your help.
Originally, I had a contact assigned to this service only, and not a contact group. I've just tried to add a test contact to a test contact group and assign the test contact group to this service and it seems like it's working.
I will keep an eye on this for the next few days to see how it's going.
Thanks for your help.
Re: Unexpected Notification Behavior
Sounds good! Let us know if you need any more help.jamesc23 wrote:I see. I think I misunderstood the whole concept a bit.
Originally, I had a contact assigned to this service only, and not a contact group. I've just tried to add a test contact to a test contact group and assign the test contact group to this service and it seems like it's working.
I will keep an eye on this for the next few days to see how it's going.
Thanks for your help.
Former Nagios Employee.
me.
me.