Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

monit smtp mail from problem #3238

Closed
Freddyvdh opened this issue Feb 15, 2019 · 4 comments
Closed

monit smtp mail from problem #3238

Freddyvdh opened this issue Feb 15, 2019 · 4 comments
Assignees
Labels
support Community support

Comments

@Freddyvdh
Copy link

Describe the bug
Monit mail sending fails over external smtp server.
We are using 1und1 as mail server. I set smtp.1und1.de (Port 465 SSL enabled) with an existing username/password. After applying the changes I see following logs:
monit[74501]: SMTP: Mailserver response error -- 550 invalid DNS MX or A/AAAA resource record
monit[74501]: Mail: Mailserver response error -- 550-Requested action not taken: mailbox unavailable

I thought I have a problem with the mail server, so I set up postfix as smtp relay. Then I got following error:
F340350D313: to=receiver@distination.de, relay=smtp.ionos.de[213.165.67.113]:25, delay=0.46, delays=0.05/0.07/0.31/0.04, dsn=5.0.0, status=bounced (host smtp.ionos.de[213.165.67.113] said: 550-Requested action not taken: mailbox unavailable 550 invalid DNS MX or A/AAAA resource record (in reply to MAIL FROM command))
F340350D313: from=monit@OPNsense.localdomain, size=804, nrcpt=1 (queue active)

So I think, the mail from is the problem. I found several issues and fixes ones, but nothing helped.

I updates from 18.7_5 to 19.1 in which System: Settings: Notifications was removed, which worked for me with version 18.7. I can't find an entry, to change to from field.

Environment
Software version used and hardware type if relevant.
OPNsense 19.1.1-amd64
FreeBSD 11.2-RELEASE-p8-HBSD
OpenSSL 1.0.2q 20 Nov 2018
AMD GX-412TC SOC (4 cores)
APU.2D4

@fichtner
Copy link
Member

550 Invalid DNS MX or A/AAAA resource record:

Die Absenderdomain des von Ihnen verwendeten E-Mail-Servers ist im Domain-Namensdienst (DNS) nicht RFC-konform konfiguriert. Hier können folgende Ursachen vorliegen:

Zur Absenderdomain ist weder ein A- noch ein MX-Record im DNS konfiguriert.
Der MX-Record verweist auf einen Domain-Namen, der nicht auflösbar ist.
Der MX-Record verweist direkt auf eine IP-Adresse.
Der MX-Server hat keinen gültigen A-Record sondern nur einen CNAME-Record.
Bitte wenden Sie sich an Ihren Administrator, damit dieser den fehlerhaften Eintrag im Domain-Namensdienst korrigiert. Eine Prüfung Ihrer Konfiguration kann unter http://www.intodns.com/ vorgenommen werden.

That would indicate @OPNsense.localdomain isn't accepted because it's not a real domain. Not sure what the old code did. Probably best to manipulate the sender / make it configurable.

@fichtner
Copy link
Member

@fbrendel
Copy link
Member

Hmm, the changelog of 19.1.r1 says:
system: removal of the old notification system in favour of Monit

It seems that you had a sender address configured at the old notification settings which was not migrated.
Either you set it after 18.7. ore something went wrong.

You can set the sender address at the alerts mail format now.
https://docs.opnsense.org/manual/monit.html?highlight=monit#alert-settings

@Freddyvdh
Copy link
Author

Yes, I had the nofication configured in 18.7.

Using the mail format works, notifications are send without any problem. Maybe it is better to set one mail from setting for monit, which can be overwritten by recipient mail-format.

Thanks for support!

@fichtner fichtner added the support Community support label Feb 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support Community support
Development

No branches or pull requests

3 participants