Page 1 of 1
NSCA + Notifications
Posted: Wed Sep 11, 2013 1:59 pm
by blrg891
Hello All!
I am running both passive checks and active checks on the the same Nagios Server. The issue is that on the Nagios dashboard I see:
Last Notification: N/A (notification 0)
For my passive checks. They are configured virtually the same as the active checks, however i am not getting notifications. I have notifications turned on at the service, host, and system level. Am I missing anything?
Thanks!!
Re: NSCA + Notifications
Posted: Wed Sep 11, 2013 2:15 pm
by lmiltchev
Can you show us the config of one hosts/services that you are not getting notifications about?
Re: NSCA + Notifications
Posted: Wed Sep 11, 2013 2:55 pm
by blrg891
Sure:
Code: Select all
define service{
use passive-service ; Name of service template to use
hostgroup_name fh-services
service_description FH SERVER
check_command check_dummy!3!"No Data Received" ; put into unknown state
notifications_enabled 1
action_url /nagiosgraph/cgi-bin/show.cgi?host=$HOSTNAME$&service=$SERVICEDESC$
}
Code: Select all
define hostgroup{
hostgroup_name fh-services
alias fh servers
members server1
}
Code: Select all
define host{
use linux-server
host_name server1
alias server1
address 192.168.0.1
action_url /nagiosgraph/cgi-bin/showhost.cgi?host=$HOSTNAME$
notifications_enabled 1
notification_options d,u,r,f,s ;
}
Code: Select all
define service{
use generic-service
name passive-service
active_checks_enabled 0
passive_checks_enabled 1
check_period 24x7
notification_period 24x7
notification_options w,u,c,r
flap_detection_enabled 0
max_check_attempts 1
notification_interval 0
is_volatile 0
contact_groups admins_LOG
}
Code: Select all
define service{
name generic-service
active_checks_enabled 1
passive_checks_enabled 1
parallelize_check 1
obsess_over_service 1
check_freshness 1
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
is_volatile 0
max_check_attempts 3
normal_check_interval 5
retry_check_interval 3
contact_groups admins_LOG
notification_options w,u,c,r
notification_interval 180
check_period 24x7
notification_period 24x7
register 0
}
Re: NSCA + Notifications
Posted: Wed Sep 11, 2013 4:49 pm
by slansing
Can you show us the "linux-server" and "passive-service" templates? The config's you shared do not show the full notification definitions that are required.
Also, does this service have passive data being pushed to it? Is it in a state that should be sending you a notification?
Re: NSCA + Notifications
Posted: Thu Sep 12, 2013 8:36 am
by blrg891
The passive service is listed above. I believe that it is second to the bottom. This is the linux server definition:
define host{
name linux-server
use generic-host
check_period 24x7
check_interval 5
retry_interval 5
max_check_attempts 3
check_command check-host-alive
notification_period 24x7
notification_interval 120
notification_options d,u,r
contact_groups admins_LOG
register 0
}
The service is passing data, the state is critical yet no notifications emails or notification indications are being listed on the dashboard.
I think I actually fixed it. I am getting updates through a port forwarded tunnel and Nagios was running host checks. It would seem that if the host check fails it doesn't care about any services running on the host and their state.
Interesting.
Thanks for the help!!!!
Re: NSCA + Notifications
Posted: Thu Sep 12, 2013 11:00 am
by slansing
Correct if the host is unreachable or down the service states will not matter unless they changed before the host failed. Glad to hear this got worked out!