Not able to receive alerts
Not able to receive alerts
HI,
currently am using Nagios xi 5.6.1, am not able to receive alerts(notifications) from nagios xi where as i can receive test emails,custom notifications from nagios xi.
contact has Notification commands as "xi_host_notification_handler and xi_service_notification_handler"
i checked /var/log/maillog i can see the alerts sent but they were delivered. am i missing something?
I added new monitoring on new servers, to check every 15 minutes i got alerted for the first time after that i didn't get any alerts from those Hosts/services. I checked the state History in Reports, even state also didn't change.
am i missing something?
currently am using Nagios xi 5.6.1, am not able to receive alerts(notifications) from nagios xi where as i can receive test emails,custom notifications from nagios xi.
contact has Notification commands as "xi_host_notification_handler and xi_service_notification_handler"
i checked /var/log/maillog i can see the alerts sent but they were delivered. am i missing something?
I added new monitoring on new servers, to check every 15 minutes i got alerted for the first time after that i didn't get any alerts from those Hosts/services. I checked the state History in Reports, even state also didn't change.
am i missing something?
Re: Not able to receive alerts
when i run, tail -f /usr/local/nagiosxi/var/eventman.log
PHP Warning: file_put_contents(/usr/local/nagiosxi/tmp/phpmailer.log): failed to open stream: Permission denied in /usr/local/nagiosxi/html/includes/utils-email.inc.php on line 212
PHP Warning: file_put_contents(/usr/local/nagiosxi/tmp/phpmailer.log): failed to open stream: Permission denied in /usr/local/nagiosxi/html/includes/utils-email.inc.php on line 212
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Not able to receive alerts
Can you show the permissions of that file?ISSB_MAOST wrote:when i run, tail -f /usr/local/nagiosxi/var/eventman.log
PHP Warning: file_put_contents(/usr/local/nagiosxi/tmp/phpmailer.log): failed to open stream: Permission denied in /usr/local/nagiosxi/html/includes/utils-email.inc.php on line 212
Code: Select all
ls -l /usr/local/nagiosxi/tmp/phpmailer.log
Re: Not able to receive alerts
# ls -l /usr/local/nagiosxi/tmp/phpmailer.log
-rw-r--r-- 1 apache nagios 194 May 31 14:17 /usr/local/nagiosxi/tmp/phpmailer.log
-rw-r--r-- 1 apache nagios 194 May 31 14:17 /usr/local/nagiosxi/tmp/phpmailer.log
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Not able to receive alerts
We need to allow the nagios user to write to this file, lets run the following
this should remove the error you are seeing, and allow you to see data in the logs
Code: Select all
chmod g+w /usr/local/nagiosxi/tmp/phpmailer.log
Re: Not able to receive alerts
I made the changes you suggested but still i cant receive any alerts, and the alerts are not even logged in to event logs.
Re: Not able to receive alerts
Also to add, some services are set to monitor for every 15 minutes and 0 notification interval and 0 first notification delay we are receiving alerts for every 1hr 15 mins.
Am i missing anything or something wrong in configuration.
Am i missing anything or something wrong in configuration.
You do not have the required permissions to view the files attached to this post.
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Not able to receive alerts
Can you show the output of the following?
Code: Select all
tail -20 /usr/local/nagiosxi/tmp/phpmailer.log
Re: Not able to receive alerts
# tail -20 /usr/local/nagiosxi/tmp/phpmailer.log
[06-03-2019 11:01:01] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:50] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:53] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:56] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:05] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:23] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:26] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:32] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:41] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:34:26] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:15:50] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:15:53] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:43] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:46] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:49] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:17] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:20] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:23] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:32] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:49:16] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:01:01] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:50] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:53] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:14:56] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:05] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:23] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:26] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:32] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:15:41] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 11:34:26] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:15:50] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:15:53] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:43] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:46] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:29:49] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:17] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:20] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:23] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:30:32] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
[06-03-2019 12:49:16] Message sent! (method=sendmail), Referer: includes/components/xicore/xicore.inc.php > Event Handler Notification Email
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Not able to receive alerts
So this is showing that the messages are being sent.
Could they be going to a spam filter or blocked based on the sender address?
Have you successfully sent a test message?
Could they be going to a spam filter or blocked based on the sender address?
Have you successfully sent a test message?