Email notification for contacts treated as external
Posted: Tue Apr 21, 2020 12:16 pm
Hi,
So being trying to get email notifications working on NagiosXI 5.6.13 and hit a brick wall. We are using smtp pointed at our companys internal smtp server. I have put the smtp setting into the section Admin>Email Settings>SMTP Settings. The smtp server is used by my team widely for sending internal mails and works fine for all our apps. We do not need any special arrangements to use it other than put the FQDN and port 25 in any of our apps to use it.
The problem I face is,If we do test mails from the Admin console "Send a Test mail" to an addresses in own domain e.g [email protected] it works perfectly, appears to use our internal smtp servers and I can see in the test mail in phpmailer.log.
However if I then set up my own email address as a contact ([email protected]) and assign that address as a contact to receive email alerts for a host/service and then break it to test, I never receive the mails.
If Iook in /var/log/maillog I see that for some reason despite my address being same domain as the test addresses, it does not seem to use the smtp server specified and instead must be using the MX record for our domain as I can see it is trying to send to my companys external email infrastructure which it won't be able to reach.
Any idea why this is happening and what I can check as I don't get why it works for the test address which is a regular Admin's address same as mine and not using the smtp server we provided in the config?
Worst case scencario, is there a config at the terminal level I can edit to force it to use the internal mail server?
Thanks andy help would be appreciated as this is really puzzling.
So being trying to get email notifications working on NagiosXI 5.6.13 and hit a brick wall. We are using smtp pointed at our companys internal smtp server. I have put the smtp setting into the section Admin>Email Settings>SMTP Settings. The smtp server is used by my team widely for sending internal mails and works fine for all our apps. We do not need any special arrangements to use it other than put the FQDN and port 25 in any of our apps to use it.
The problem I face is,If we do test mails from the Admin console "Send a Test mail" to an addresses in own domain e.g [email protected] it works perfectly, appears to use our internal smtp servers and I can see in the test mail in phpmailer.log.
However if I then set up my own email address as a contact ([email protected]) and assign that address as a contact to receive email alerts for a host/service and then break it to test, I never receive the mails.
If Iook in /var/log/maillog I see that for some reason despite my address being same domain as the test addresses, it does not seem to use the smtp server specified and instead must be using the MX record for our domain as I can see it is trying to send to my companys external email infrastructure which it won't be able to reach.
Any idea why this is happening and what I can check as I don't get why it works for the test address which is a regular Admin's address same as mine and not using the smtp server we provided in the config?
Worst case scencario, is there a config at the terminal level I can edit to force it to use the internal mail server?
Thanks andy help would be appreciated as this is really puzzling.