tzo.com logo
View Entry
Subject Email error: all relevant MX records point to non-existent hosts or (invalidly) to IP addresses
Author Scott Prive

MX which do not point to a hostname (or invalidly to an IP address)

Short explanation

The recipient domain has a broken MX record. Some email server software can handle broken MX records, while many server applications can not (actually, most can not).

In any case, the recipient's domain has serious email problems they should know about. MOST domains emailing TO them will be mis-routed or bounced along the way, so they're losing inbound email. Additionally the domain with the bad MX is probably losing some OUTBOUND email as well, because there some anti-spam software will flag email from such a domain as spam (invalid MX records are assumed to be a sign of a spam outfit).

This problem is rare (or short-lived) simply because the problem will cause so many email problems that the admin will eventually discover the problem. You can demonstrate the problem at the DNS level using a third party diagnostic tool such as DNSReport.com, and perhaps send the results to their admin as this is a very easy problem to fix/.

Technical Details

According to RFC 1035 section 3.3.9, DNS MX records MUST resolve to a DNS A record. Using an IP address in the MX record is considered broken, and using a value which is a CNAME will have unpredictable results.

Because the DNS RFC's expressly forbid IPs in an MX, any email both TO and FROM that domain is subject to failure or delay. While some mail servers may be able to recover from such DNS errors, such servers are few. This rule is not so much a policy issue but it is how most mailservers are developed.

For example Sendmail, Exim, and Postfix, and Courier are 4 of the most popular and widely used mail routers. These mailservers together carry the bulk of the Internet's email. None of these will route mail to a domain if the domain has MX set to an IP.

Note: while an MX record is normally assumed not to impact outgoing email, that assumption is not always true if the MX is invalid in this way. Anti-spam software may assume that the broken MX is a sign of fly-by-night spammers, or a compromised server. As a result, email to or from that domain may have unpredictable results. This is not much different that mail servers who require valid reverse DNS on a sender IP.

Correcting the problem

If domain's DNS is managed by TZO

There is never a technical need to set the MX to an IP address; however (currently) the TZO DNS panel does not prevent this in your MX field. Most likely this will change in a future Control Panel, as this 'feature' causes delivery failures, where the third party mailserver either blackholes email or generates cryptic messages like 'failure at sender's DNS service', which is misleading and not easily answered in Support.

If all of your hosts are behind a single Internet/WAN IP address (or you have multiple IP addresses but have all inbound ports on the same IP), then you can dynamically invent a subdomain (such as mail.example.com) and it will resolve back to the domain root record's IP automatically.

If you have multiple WAN IP addresses and mail WAN IP is different than the root record's WAN IP, you will need a new hostname that resolves to the second IP. For TZO Premiere customers, contact TZO Support and we will create an additional subdomain for that IP, and then you can enter that IP into the MX.

Once the corrected hostname is entered into the MX in TZO's DNS management panel, the change should become 'live' within 5-10 minutes (change is immediate but some servers may have old values cached).

If domain's DNS is managed by third parties

If domain's with the IP address in the MX field has DNS managed by a remote party, there is not anything TZO can do to fix or workaround the problem. They should contact their DNS support for assistance.

When you send email to this party using TZO email servers, the mail will fail delivery and you will receive a Notification/Receipt. Within the body of the failure, TZO will put the diagnostic information so you may share it with the affected domain owner. The relevent error text is:
all relevant MX records point to non-existent hosts or (invalidly) to IP addresses

Chances are, if DNS is broken this way the admin is unaware and appreciates the warning, although they may not understand and require help from their DNS or email provider. The recipient's admin will 'eventually' correct the issue, in the same way that it takes folks time to realize what it means to be on a spam blacklist, or suffer rejections due to reverse DNS failures on their mail IP address.

Once the invalid MX record is corrected, mail to that domain through TZO would resume almost immediately; TZO's mail servers do not cache such failures for more than a few minutes.

Further Reading

Copyright 1998-2008, Tzolkin Corporation. All rights reserved.