Email alerts not send for a new contact
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Email alerts not send for a new contact
Hello:
We add another contact to nagios to send email alerts to another email account , when was created the new user we received an email confirmation from Nagios in the user mailbox (the email domain is different like the nagiosadmin email account domain).
We add the user to contacts and setiing the email alerts for host and services in a sever test, but the alerts only arrive to the original nagiosadmin email account, not arrive at the new user.
The settings in the alert settings tab are copy form the nagiosadmin settings.
We need the alert email arrives to both accounts.
We add another contact to nagios to send email alerts to another email account , when was created the new user we received an email confirmation from Nagios in the user mailbox (the email domain is different like the nagiosadmin email account domain).
We add the user to contacts and setiing the email alerts for host and services in a sever test, but the alerts only arrive to the original nagiosadmin email account, not arrive at the new user.
The settings in the alert settings tab are copy form the nagiosadmin settings.
We need the alert email arrives to both accounts.
Re: Email alerts not send for a new contact
Go to CCM->Contacts->click on the "View Text Config" action button, and show us the contact definition (hide sensitive info).
BTW, can you run the following command:
and compare the email you see to the one in the config file.
BTW, can you run the following command:
Code: Select all
echo 'select * from xi_users;' | psql nagiosxi nagiosxi | grep <put user's name in here>Be sure to check out our Knowledgebase for helpful articles and solutions!
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Re: Email alerts not send for a new contact
Code: Select all
user_id | username | password | name | email | backend_ticket | enabled
---------+-------------+----------------------------------+--------+-------------------------+---------------------------------------------------------------
49 | jrey | 125bccb62bdxxxxxxxxxxxxxxxxxxxxx | Javier | [email protected] | xxxxxxxxx | 1Re: Email alerts not send for a new contact
Did you X out all those fields or is it actually displaying that for some reason? lmiltchev was asking you to compare the email in the output of that command to the one in your config file.
Former Nagios employee
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Re: Email alerts not send for a new contact
The X is sensitive information , I only replace the real values for "X" , the user is added correctly in the SQL database"
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Re: Email alerts not send for a new contact
The email is correct.
Re: Email alerts not send for a new contact
Go to:
Core Config Manager->Hosts->View Text Config and copy/paste the config of the "test" host
Core Config Manager->Contacts->View Text Config and copy/paste the config of the contact in question
Note: Hide sensitive info.
Core Config Manager->Hosts->View Text Config and copy/paste the config of the "test" host
Core Config Manager->Contacts->View Text Config and copy/paste the config of the contact in question
Note: Hide sensitive info.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Re: Email alerts not send for a new contact
The relevant information about host, service and contact in text file.
###############################################################################
#
# Host configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2014-04-23 09:13:02
# 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 LRXXXXX
use xiwizard_windowsserver_host
alias BCK_VC_ESX_5_XXX
address 192.168.XXX.XXX
max_check_attempts 5
check_interval 5
retry_interval 1
check_period xi_timeperiod_24x7
contacts jrey,nagiosadmin
contact_groups admins
notification_interval 60
notification_period xi_timeperiod_24x7
notification_options d,r,f,
notifications_enabled 1
icon_image win_server.png
statusmap_image win_server.png
_xiwizard windowsserver
register 1
}
###############################################################################
#
# Host configuration file
#
# END OF FILE
#
###############################################################################
define service {
host_name LRXXXX
service_description Drive E: Disk Usage
use xiwizard_windowsserver_nsclient_service
check_command check_xi_service_nsclient!!USEDDISKSPACE!-l E -w 80 -c 95!!!!!
max_check_attempts 1
check_interval 1
retry_interval 1
check_period xi_timeperiod_24x7
notification_interval 60
first_notification_delay 0
notification_period xi_timeperiod_24x7
notification_options w,u,r,c,f,s
notifications_enabled 1
contacts jrey,nagiosadmin
contact_groups admins
_xiwizard windowsserver
register 1
}
###############################################################################
#
# Contact configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2014-04-23 09:17:30
# 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 contact {
contact_name jrey
alias XXXX
contactgroups admins,xi_contactgroup_all
host_notifications_enabled 1
service_notifications_enabled 1
host_notification_period nagiosadmin_notification_times
service_notification_period nagiosadmin_notification_times
host_notification_options d,u,r,
service_notification_options w,c,r,
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-email
email [email protected]
}
###############################################################################
#
# Host configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2014-04-23 09:13:02
# 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 LRXXXXX
use xiwizard_windowsserver_host
alias BCK_VC_ESX_5_XXX
address 192.168.XXX.XXX
max_check_attempts 5
check_interval 5
retry_interval 1
check_period xi_timeperiod_24x7
contacts jrey,nagiosadmin
contact_groups admins
notification_interval 60
notification_period xi_timeperiod_24x7
notification_options d,r,f,
notifications_enabled 1
icon_image win_server.png
statusmap_image win_server.png
_xiwizard windowsserver
register 1
}
###############################################################################
#
# Host configuration file
#
# END OF FILE
#
###############################################################################
define service {
host_name LRXXXX
service_description Drive E: Disk Usage
use xiwizard_windowsserver_nsclient_service
check_command check_xi_service_nsclient!!USEDDISKSPACE!-l E -w 80 -c 95!!!!!
max_check_attempts 1
check_interval 1
retry_interval 1
check_period xi_timeperiod_24x7
notification_interval 60
first_notification_delay 0
notification_period xi_timeperiod_24x7
notification_options w,u,r,c,f,s
notifications_enabled 1
contacts jrey,nagiosadmin
contact_groups admins
_xiwizard windowsserver
register 1
}
###############################################################################
#
# Contact configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2014-04-23 09:17:30
# 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 contact {
contact_name jrey
alias XXXX
contactgroups admins,xi_contactgroup_all
host_notifications_enabled 1
service_notifications_enabled 1
host_notification_period nagiosadmin_notification_times
service_notification_period nagiosadmin_notification_times
host_notification_options d,u,r,
service_notification_options w,c,r,
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-email
email [email protected]
}
Re: Email alerts not send for a new contact
It seems you changed the "default" notification handlers. In the contact's definition, you have:
Try changing it to:
Let me know if this fixed your issue.
Code: Select all
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-emailCode: Select all
host_notification_commands xi_host_notification_handler
service_notification_commands xi_service_notification_handlerBe sure to check out our Knowledgebase for helpful articles and solutions!
-
SistemesLRC
- Posts: 6
- Joined: Mon Apr 14, 2014 4:39 am
Re: Email alerts not send for a new contact
The change fixed the error, we received the alarms email now.
Thank you
Thank you