How to setup correct from email in WHM?
Emails send from server's root are being returned by 1&1 email host with following error.
# echo "Subject: sendmail test" | sendmail -v me@domain.com
SMTP>> MAIL FROM:<root@ns512222> SIZE=1328
SMTP<< 550-Requested action not taken: mailbox unavailable
550 invalid DNS MX or A/AAAA resource record
SMTP>> QUIT
I tried sending to gmail where it is delivered but goes to spam folder.
So it seems that my server/WHM is not correctly setup for email sender (root).
Following are my settings
WHM >> Change System Mail Preferences
Cpanel root
Nobody Blank
root "my e-mail address"
/etc/localdomains
It has the server name ns512222 listed there.
I suspect, and probably it's obvious, that ns512222 is not a FQDN? Is this is the reason? How to fix it?
-
Where are the MX record(s) of domain.com pointing to? Is domain.com in /etc/localdomains ? It looks like the mail is delivered to the local server but there is no such mailbox. 0 -
Where are the MX record(s) of domain.com pointing to? Is domain.com in /etc/localdomains ?
domain.com is external email hosted on 1&1, all records are at 1&1.0 -
But for some reason Exim in your server is trying to do local delivery. Is the DNS Zone for domain.com in your server? > I suspect, and probably it's obvious, that ns512222 is not a FQDN? Is this is the reason? How to fix it? It's not a FQDN but it's not the reason. 0 -
But for some reason Exim in your server is trying to do local delivery. Is the DNS Zone for domain.com in your server?
No, DNS zone for domain.com is not on my server, it never has been. Following is the complete log #echo "Subject: sendmail test" | sendmail -v me@domain.com LOG: MAIN cwd=/root 3 args: sendmail -v me@domain.com LOG: MAIN <= root@ns512222 U=root P=local S=296 T="sendmail test" [root@ns512222 ~]# LOG: MAIN cwd=/var/spool/exim 4 args: /usr/sbin/exim -v -Mc 1moq7t-0008Fs-Ne delivering 1moq7t-0008Fs-Ne Connecting to mx00.1and1.co.uk [113.111.11.11]:25 ... connected SMTP<< 220 kundenserver.de (mxeue010) Nemesis ESMTP Service ready SMTP>> EHLO ns512222.ip-123-49-15.net SMTP<< 250-kundenserver.de Hello ns512222.ip-123-49-15.net [111.11.11.11] 250-8BITMIME 250-SIZE 157286400 250 STARTTLS SMTP>> STARTTLS SMTP<< 220 OK LOG: MAIN [113.111.11.11] SSL verify error: certificate name mismatch: DN="/C=DE/O=IONOS SE/ST=Rheinland-Pfalz/L=Montabaur/CN=mx.kundenserver.de" H="mx00.1and1.co.uk" SMTP>> EHLO ns512222.ip-123-49-15.net SMTP<< 250-kundenserver.de Hello ns512222.ip-123-49-15.net [111.11.11.11] 250-8BITMIME 250 SIZE 157286400 SMTP>> MAIL FROM: SIZE=1328 SMTP<< 550-Requested action not taken: mailbox unavailable 550 invalid DNS MX or A/AAAA resource record SMTP>> QUIT SMTP(close)>> LOG: MAIN ** me@domain.com R=lookuphost T=remote_smtp H=mx00.1and1.co.uk [113.111.11.11] X=TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256 CV=no: SMTP error from remote mail server after MAIL FROM: SIZE=1328: 550-Requested action not taken: mailbox unavailable\n550 invalid DNS MX or A/AAAA resource record LOG: MAIN cwd=/var/spool/exim 8 args: /usr/sbin/exim -v -t -oem -oi -f <> -E1moq7t-0008Fs-Ne LOG: MAIN <= <> R=1moq7t-0008Fs-Ne U=mailnull P=local S=1848 T="Mail delivery failed: returning message to sender" LOG: MAIN Completed LOG: MAIN cwd=/var/spool/exim 4 args: /usr/sbin/exim -v -Mc 1moq7u-0008G6-UG delivering 1moq7u-0008G6-UG LOG: MAIN Sender identification U=mailnull D=-system- S=mailnull Connecting to mx00.1and1.co.uk [113.111.11.11]:25 ... connected SMTP<< 220 kundenserver.de (mxeue010) Nemesis ESMTP Service ready SMTP>> EHLO ns512222.ip-123-49-15.net SMTP<< 250-kundenserver.de Hello ns512222.ip-123-49-15.net [111.11.11.11] 250-8BITMIME 250-SIZE 157286400 250 STARTTLS SMTP>> STARTTLS SMTP<< 220 OK LOG: MAIN [113.111.11.11] SSL verify error: certificate name mismatch: DN="/C=DE/O=IONOS SE/ST=Rheinland-Pfalz/L=Montabaur/CN=mx.kundenserver.de" H="mx00.1and1.co.uk" SMTP>> EHLO ns512222.ip-123-49-15.net SMTP<< 250-kundenserver.de Hello ns512222.ip-123-49-15.net [111.11.11.11] 250-8BITMIME 250 SIZE 157286400 SMTP>> MAIL FROM:<> SIZE=2926 SMTP<< 250 Requested mail action okay, completed SMTP>> RCPT TO: SMTP<< 250 OK SMTP>> DATA SMTP<< 354 Start mail input; end with . SMTP>> writing message and terminating "." SMTP<< 250 Requested mail action okay, completed: id=1N9eg1-1md2UA3EWL-015Uwb SMTP>> QUIT SMTP(close)>> LOG: MAIN => me@domain.com R=dkim_lookuphost T=dkim_remote_smtp H=mx00.1and1.co.uk [113.111.11.11] X=TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256 CV=no C="250 Requested mail action okay, completed: id=1N9eg1-1md2UA3EWL-015Uwb" LOG: MAIN Completed0 -
I would suggest that you correct your hostname, in WHM -> Networking Setup -> Change Hostname. 0 -
ns512222.ip-123-49-15.net is the hostname, is there anything wrong with it? For privacy reasons I've changed the digits in the hostname but you get the idea. 0 -
Somethign seems to be wrong because I see: >SMTP>> MAIL FROM: SIZE=1328 (unless you changed that). Just to make sure change (or set) the hostname again. 0 -
Somethign seems to be wrong because I see: >SMTP>> MAIL FROM: SIZE=1328 (unless you changed that). Just to make sure change (or set) the hostname again.
Yes, you are right. This is what I meant in my very first question. ns512222 is not hostname. I'm not sure where this value is coming from. The only place I could find this value is in /etc/localdomains, is this the place where it's getting this value? if not where else to look for ns512222 value?0
Please sign in to leave a comment.
Comments
8 comments