Notification Alerts

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
ffolse
Posts: 10
Joined: Wed Jan 21, 2015 1:54 pm

Notification Alerts

Post by ffolse »

Hello,

I' setting up a different notification alert setting for my dev servers to only aletr during business hours. I have the host configured to only alert on a work hour time period and service checks with disabled notification alerts, however we are still getting alerts outside of the host notification alerts settings.
- Can you see any incorrect setting?
- Is it required to have 2 contacts? (1 for 24/7 and another for desired time)

HOST:
define host {
host_name host1
address xxx.xx.xx.xx
max_check_attempts 5
check_interval 5
retry_interval 1
check_period workhours_linux
contacts nagiosadmin
contact_groups linuxadmin
notification_interval 60
notification_period workhours_linux
first_notification_delay 0
notification_options d,r,s,
notifications_enabled 1
icon_image hp_ux.png
statusmap_image hp_ux.png
_xiwizard linuxsnmp
register 1
}


Checks: notification alert is off in Alert settings tab)

define service {
service_description tmp Disk Usage
hostgroup_name hostgroup1 (host1 is a member of this group)
check_command check_nrpe!check_tmp!!!!!!!
max_check_attempts 3
check_interval 3
retry_interval 1
check_period 24x7
notification_interval 30
first_notification_delay 0
notifications_enabled 0
_xiwizard nrpe
register 1
}

CONTACt:
define contact {
contact_name linuxadmin
alias admin1
host_notifications_enabled 1
service_notifications_enabled 1
host_notification_period 24/7
service_notification_period 24/7
host_notification_options d,u,r,f,s,
service_notification_options c,r,s,
can_submit_commands 1
email email_address
use xi_contact_generic (service notifiaction is skipped on this template)
}
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Notification Alerts

Post by lmiltchev »

In your host definition, you have:
contact_groups linuxadmin
Is the linuxadmin" contact a member of the "linuxadmin" contactgroup? This is not very clear. It's not a good practice to name the contact and the contactgroup with exactly the same names.
define contact {
contact_name linuxadmin
Also, can you post the "workhours_linux" timeperiod's definition and show us the actual email notification that you received?
Be sure to check out our Knowledgebase for helpful articles and solutions!
ffolse
Posts: 10
Joined: Wed Jan 21, 2015 1:54 pm

Re: Notification Alerts

Post by ffolse »

HI,

I was making the post as generic as I can, we have names configured differently in our set up and just changed to linuxadmin on this post.

Here is the email we got (changed the ips/hostname)

From: nagios01@zzzz [mailto:nagios01@zzzzz]
Sent: Friday, March 20, 2015 7:38 PM
To: linuxadmin
Subject: PROBLEM (CRITICAL) host1 HP-UX /tmp
Importance: High

Nagios has detected a problem with this service.
CHECK_NRPE: Socket timeout after 30 seconds.
(host1) IP: xxx.xx.xx.xx
2015-03-20 19:38:01


and here is the timeperiod definition:

define timeperiod {
timeperiod_name workhours_linux
alias Normal Linux Work Hours
friday 05:00-19:00
thursday 05:00-19:00
wednesday 05:00-19:00
tuesday 05:00-19:00
monday 05:00-19:00
}


Thanks,
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Notification Alerts

Post by lmiltchev »

I was making the post as generic as I can...
It's difficult to try to guess which names are "real" and which are "generic".
Is the "host1 HP-UX" same as "host1"? Is "tmp Disk Usage" same as "/tmp"? Notifications are disabled for the " tmp Disk Usage" service, so you shouldn't be getting alerts. Can you check if you have any multiple instances of nagios running?

Code: Select all

ps -ef | grep [b]in/nagios
Be sure to check out our Knowledgebase for helpful articles and solutions!
ffolse
Posts: 10
Joined: Wed Jan 21, 2015 1:54 pm

Re: Notification Alerts

Post by ffolse »

1. Is the "host1 HP-UX" same as "host1" == yes this is correct.
2. /tmmp Disk Usage" same as "/tmp"? Notifications are disabled for the " tmp Disk Usage" service === when the Notification Alerts tab is set to off, this will not inherit the setting for the HOST NOTIFICATION ALERT setting?
- does this mean that I need to define 2 service check for /tmp? One for 24/7 notification alerts and another /tmp service check but for "work hours" notification setting?
3. Can you check if you have any multiple instances of nagios running === Just 1 instance.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Notification Alerts

Post by lmiltchev »

When you have:

Code: Select all

notifications_enabled 0
in the service definition, the notifications will be disabled. See how this directive is used:

Code: Select all

http://nagios.sourceforge.net/docs/nagioscore/4/en/objectdefinitions.html#service
Can you email us your profile at [email protected]?

Admin->System Profile->Download Profile->save and email the "porfile.zip".

We will need to move this to our email ticketing system to further troubleshoot the issue. Thanks!
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked