Page 1 of 1

Dependencies.

Posted: Mon Feb 25, 2013 6:01 pm
by gshine
I gave added this into the special section of the GUI for nahios

parents Google DNS 8.8.4.4

I was expecting not to receive any alerts if this is down but I get many - Do I also need something for each service on the host I am trying to stop alerts from whrn the internet is down?

Help - 400 alerts everytime is killing me.

Thanks
Gary

Re: Dependencies.

Posted: Tue Feb 26, 2013 7:22 am
by gshine
Rely looking fo the special command to stop alerts when the internet is down?

Any help appreciated
Gary

Re: Dependencies.

Posted: Tue Feb 26, 2013 11:13 am
by slansing
When you want to disable notifications for a specific host or service, you can do so by viewing the host through the Web UI. Hosts > Hostname or Services > Service name, and clicking the disable Notifications button under Host Commands.

Why did you expect to get no notifications, you will receive notifications when a host or service is severed from Nagios, can you show us the definitions of these hosts as they are shown in their configuration files?

Re: Dependencies.

Posted: Tue Feb 26, 2013 1:27 pm
by gshine
I only want alerts when the parent is up - We monitor 8.8.8.8 as the 'parent' to all hosts - This means if Verizon or COX fail we do not get a milion false alerts. COnfig sections below as examples.

Do I need some sort of parent on each service as well as host . I get 400 alerts if the internet goes down as we are monitoring all servers and services remotely and I only want alerts when a host or service is down AND the internet is up.

define contact {
name generic-contact
host_notification_period 24x7
service_notification_period 24x7
host_notification_options d,r,f,s
service_notification_options c,r,f,s
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-email
register 0
}

define service {
name generic-service
active_checks_enabled 1
passive_checks_enabled 1
parallelize_check 1
obsess_over_service 1
check_freshness 0
notifications_enabled 1
event_handler_enabled 1
flap_detection_enabled 1
failure_prediction_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
register 0
is_volatile 0
check_period 24x7
max_check_attempts 3
normal_check_interval 3
retry_check_interval 1
notification_interval 60
notification_period 24x7
notification_options w,c,r
first_notification_delay 2
}

define host {
name generic-host
register 0
max_check_attempts 10
check_command check-host-alive
notifications_enabled 1
notification_interval 0
notification_period 24x7
notification_options d,r
event_handler_enabled 1
flap_detection_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
}


# host_id_3
define host {
host_name ADSL Router
alias ADII
address 1.2.3.4
contact_groups admins, P Technical Staff
icon_image nagiosimages/router.jpg
#notes_url /nagios2mwiki.php?host=$HOSTNAME
#action_url https://www.example.com/na/host/edit/id/3
use generic-host
notification_interval 0
parents GOOGLE MOAP
}

# service_id_3_8
define service {
use generic-service
host_name ADSL Router
service_description ssh
display_name OpenSSH
check_command check_ssh
contact_groups admins, Proartemis Technical Staff
}

Re: Dependencies.

Posted: Tue Feb 26, 2013 5:58 pm
by slansing
You should give this document a read through, it shows how to set hosts to a parent, and how to exclude the unreachable notification when a parent goes down and triggers that state.

http://nagios.sourceforge.net/docs/3_0/ ... ility.html

Re: Dependencies.

Posted: Tue Feb 26, 2013 7:23 pm
by gshine
Was hoping for a little more than RTM.

Hopefully theer are 'experts' here that may be able to solve this easily......

Gary

Re: Dependencies.

Posted: Wed Feb 27, 2013 11:47 am
by slansing
Gary, you stated the following:
Do I need some sort of parent on each service as well as host . I get 400 alerts if the internet goes down as we are monitoring all servers and services remotely and I only want alerts when a host or service is down AND the internet is up.
This documentation was written by 'experts' to be read and implemented in their environments, it goes over the differences between down and unreachable states, and gives you the knowledge and tools to safely determine host/service parent/child relationships within your network to tell Nagios that when x host stops submitting ping data and y host is down due to connectivity issues that nagios should treat x host as unreachable. This is what you were asking for and what is placed in the documentation that I gave you, here it is again:

http://nagios.sourceforge.net/docs/3_0/ ... ility.html

Now if you are having an issue with something other than what you stated above please ask it and we will be more than happy to assist you with the additional issue.