Email Notifications Don't Work
Email Notifications Don't Work
Hello,
I am facing an issue with a fresh VM NagiosXI Installation, after temporarily disabling notifications through monitoring engine status and re-enabling I am not getting any email notifications.
Email settings are correct as I am able to get all the test emails (notification and email settings test).
I tried to send forced notifications and even though they get displayed in the core view:(sample)
AU_Firewall_2 Log Partition CUSTOM (CRITICAL) 03-29-2019 14:53:35 nagiosadmin xi_service_notification_handler SNMP CRITICAL - Slot-1 Management Log Partition *3530056* KB
They never get emailed.
All the services are configured having notifications enabled and are directly linked to all the users.
All the users have their notifications enabled and their notification method set by email.
The core contacts linked to the users have their notification commands set to xi_host_notification_handler and service respectively.
The emails are sent via smtp without auth or security.
In tail -F /usr/local/nagiosxi/tmp/phpmailer.log
there seem to be no entries regarding forced or not notifications.
Thank you for your time,
George Panou
I am facing an issue with a fresh VM NagiosXI Installation, after temporarily disabling notifications through monitoring engine status and re-enabling I am not getting any email notifications.
Email settings are correct as I am able to get all the test emails (notification and email settings test).
I tried to send forced notifications and even though they get displayed in the core view:(sample)
AU_Firewall_2 Log Partition CUSTOM (CRITICAL) 03-29-2019 14:53:35 nagiosadmin xi_service_notification_handler SNMP CRITICAL - Slot-1 Management Log Partition *3530056* KB
They never get emailed.
All the services are configured having notifications enabled and are directly linked to all the users.
All the users have their notifications enabled and their notification method set by email.
The core contacts linked to the users have their notification commands set to xi_host_notification_handler and service respectively.
The emails are sent via smtp without auth or security.
In tail -F /usr/local/nagiosxi/tmp/phpmailer.log
there seem to be no entries regarding forced or not notifications.
Thank you for your time,
George Panou
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: Email Notifications Don't Work
Hello, @gpanou. Please run the following command to clear out email tables in the database:
If notifications don't resume please trigger a few alerts from the GUI and then take a screenshot of the Event Log and upload it in the ticket. Also, you can go to the Admin Menu, then click on Manage Email Settings in the left column and check the Debugging option:echo "truncate table xi_events; truncate table xi_meta; truncate table xi_eventqueue;" | mysql -uroot -pnagiosxi nagiosxi
Then after email notifications were supposed to go out you can look into those log files and let us know if there are any errors.This will enable debug logging for phpmailer emails. The log is located here: /usr/local/nagiosxi/tmp/phpmailer.log
Sendmail log location depends on your system (examples: /var/log/maillog or /var/log/mail.log)
You do not have the required permissions to view the files attached to this post.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: Email Notifications Don't Work
Still no notifications, the logs where enabled, there dont seem to be any errors, here is the event log:
Terminal log
Test notifications and email test work.
Code: Select all
Type Date / Time Information
Service Notification 2019-04-01 10:34:23 SERVICE NOTIFICATION: nagiosadmin;AU_Firewall_2;Log Partition;CUSTOM (CRITICAL);xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB;Nagios Admin;test notification
Service Notification 2019-04-01 10:34:23 SERVICE NOTIFICATION: mntouros;AU_Firewall_2;Log Partition;CUSTOM (CRITICAL);xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB;Nagios Admin;test notification
Service Notification 2019-04-01 10:34:23 SERVICE NOTIFICATION: algo;AU_Firewall_2;Log Partition;CUSTOM (CRITICAL);xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB;Nagios Admin;test notification
Service Notification 2019-04-01 10:30:53 SERVICE NOTIFICATION: nagiosadmin;AU_Firewall_2;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB
Service Notification 2019-04-01 10:30:53 SERVICE NOTIFICATION: mntouros;AU_Firewall_2;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB
Service Notification 2019-04-01 10:30:53 SERVICE NOTIFICATION: algo;AU_Firewall_2;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *3716536* KB
Service Critical 2019-04-01 10:29:27 SERVICE ALERT: HP-Stack-BuildB;4/37 Status;CRITICAL;HARD;5;CRITICAL: Interface 4/37 (index 193) is down.
Service Notification 2019-04-01 10:29:27 SERVICE NOTIFICATION: nagiosadmin;HP-Stack-BuildB;4/37 Status;CRITICAL;xi_service_notification_handler;CRITICAL: Interface 4/37 (index 193) is down.
Service Notification 2019-04-01 10:29:27 SERVICE NOTIFICATION: mntouros;HP-Stack-BuildB;4/37 Status;CRITICAL;xi_service_notification_handler;CRITICAL: Interface 4/37 (index 193) is down.
Service Notification 2019-04-01 10:29:27 SERVICE NOTIFICATION: algo;HP-Stack-BuildB;4/37 Status;CRITICAL;xi_service_notification_handler;CRITICAL: Interface 4/37 (index 193) is down.
Service Critical 2019-04-01 10:28:29 SERVICE ALERT: HP-Stack-BuildB;4/37 Status;CRITICAL;SOFT;4;CRITICAL: Interface 4/37 (index 193) is down.
Service Critical 2019-04-01 10:27:30 SERVICE ALERT: HP-Stack-BuildB;4/37 Status;CRITICAL;SOFT;3;CRITICAL: Interface 4/37 (index 193) is down.
Service Recovery 2019-04-01 10:26:58 SERVICE ALERT: AU_Offices1_SW;Ping;OK;SOFT;2;OK - 192.168.212.1: rta 403.035ms, lost 0%
Service Critical 2019-04-01 10:26:32 SERVICE ALERT: HP-Stack-BuildB;4/37 Status;CRITICAL;SOFT;2;CRITICAL: Interface 4/37 (index 193) is down.
Service Warning 2019-04-01 10:26:00 SERVICE ALERT: AU_Offices1_SW;Ping;WARNING;SOFT;1;WARNING - 192.168.212.1: rta 402.856ms, lost 80%
Service Critical 2019-04-01 10:25:34 SERVICE ALERT: HP-Stack-BuildB;4/37 Status;CRITICAL;SOFT;1;CRITICAL: Interface 4/37 (index 193) is down.
Service Notification 2019-04-01 10:19:44 SERVICE NOTIFICATION: nagiosadmin;AU_Firewall_1;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *2672252* KB
Service Notification 2019-04-01 10:19:44 SERVICE NOTIFICATION: mntouros;AU_Firewall_1;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *2672252* KB
Service Notification 2019-04-01 10:19:44 SERVICE NOTIFICATION: algo;AU_Firewall_1;Log Partition;CRITICAL;xi_service_notification_handler;SNMP CRITICAL - Slot-1 Management Log Partition *2672252* KB
Service Notification 2019-04-01 10:19:44 SERVICE NOTIFICATION: George Panou;AU_Firewall_1;Log Partition;CRITICAL;notify-service-by-email;SNMP CRITICAL - Slot-1 Management Log Partition *2672252* KB
Host Recovery 2019-04-01 09:59:13 HOST ALERT: AU_Cameras_SW;UP;SOFT;1;OK - 192.168.212.5: rta 403.443ms, lost 0%
Host Down 2019-04-01 09:59:00 HOST ALERT: AU_Cameras_SW;DOWN;SOFT;1;CRITICAL - 192.168.212.5: rta nan, lost 100%
Service Recovery 2019-04-01 09:58:35 SERVICE ALERT: HP-5412-BuildC;F13 Status;OK;HARD;5;OK: Interface F13 (index 173) is up.
Service Notification 2019-04-01 09:58:35 SERVICE NOTIFICATION: nagiosadmin;HP-5412-BuildC;F13 Status;OK;xi_service_notification_handler;OK: Interface F13 (index 173) is up.
Service Notification 2019-04-01 09:58:35 SERVICE NOTIFICATION: mntouros;HP-5412-BuildC;F13 Status;OK;xi_service_notification_handler;OK: Interface F13 (index 173) is up.
Service Notification 2019-04-01 09:58:35 SERVICE NOTIFICATION: algo;HP-5412-BuildC;F13 Status;OK;xi_service_notification_handler;OK: Interface F13 (index 173) is up.
Code: Select all
[04-01-2019 10:29:33] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:29:33] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:31:02] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:31:02] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:31:02] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:34:29] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:34:30] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:34:30] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first
SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
Re: Email Notifications Don't Work
When I try with sendmail I get this error:
Code: Select all
[04-01-2019 10:46:23] Could not instantiate mail function. (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[04-01-2019 10:46:23] Could not instantiate mail function. (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Email Notifications Don't Work
This from address is failing [email protected]Code: Select all
SMTP code: 503 Additional SMTP info: 5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello first SMTP code: 503 Additional SMTP info: 5.5.2 (method=smtp;host=192.68.7.27;port=25;security=none), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email [04-01-2019 10:31:02] The following From address failed: [email protected] : MAIL FROM command failed,Send hello first
Is it a valid email address?
Re: Email Notifications Don't Work
Yes it is a valid address, the mail goes through a relay
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Email Notifications Don't Work
You are going to want to check the logs on 192.68.7.27 SMTP server because it is giving the error messagegpanou wrote:Yes it is a valid address, the mail goes through a relay
Re: Email Notifications Don't Work
Code: Select all
,503,5.5.2SMTP server error: MAIL FROM command failed Detail: Send hello firstRe: Email Notifications Don't Work
initializing the variable :
public $Helo = 'helo';
in
/usr/local/nagiosxi/html/includes/phpmailer/class.phpmailer.php
the emails get sent
public $Helo = 'helo';
in
/usr/local/nagiosxi/html/includes/phpmailer/class.phpmailer.php
the emails get sent
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Email Notifications Don't Work
This is bizarre, I've never seen this, but maybe because you are using IP vs. hostname.