Apr
26th

Is Your MX Record Configured Correctly?

Filed under Server Tips | Posted by Gary

With the never ending fight against unsolicited email, more and more ISPs and businesses are including an MX check as part of their spam ‘scoring’ method. It’s important that you have your MX record configured correctly so that you don’t lose points due to misconfiguration.

Before we get into that, MX stands for Mail eXchanger. It tells the rest of the world which mail server will be responsible for any mail that should be delivered to your domain. So, as far as importance goes, the MX is right up there!

Basically, there are two golden rules.

1. Your MX IP number should resolve to the MX hostname.

2. Your MX DNS record should be an ‘A’ record.

So..how do you check that it’s right? I usually use DNSStuff.com (the banner at the top of the main page) as it does several additional checks, but lets look at how we would do this the old fashioned way. The first step (and we’ll use dedicatedserverdoc.com as the example) is to find out what the MX host is for your domain. This is easy enough from the unix command line. We’ll just use the ‘dig’ command:

dig dedicatedserverdoc.com mx

The answer I get is mail.optintrust.org. The next step is to look up the IP for that host and then look up the host for the IP:

nslookup mail.optintrust.org

The IP number is 72.36.158.194. So next we look up the IP number:

nslookup 72.36.158.194

The answer we get is:

Non-authoritative answer:
194.158.36.72.in-addr.arpa name = mail.optintrust.org

That’s what we want to see … 72.36.158.194 = mail.optintrust.org = 72.36.158.194. But what if you find that when you look up the IP it says something like 194.158.36.72.reverse.somehost.com? All you should need to do is contact your host and politely ask them to create a reverse DNS entry for your IP number. It should go something like this:

Dear Host, Could you please create a reverse DNS entry for my IP which is 72.36.158.194. I would like the hostname for that IP to point to my mail server – mail.optintrust.org.

You need to tell them your main IP number for your server AND the hostname you would like that IP number to point to.

The second golden rule is that your MX should be an ‘A’ record. Quite often I find that customers have set up their own DNS and their MX is a CNAME (i.e. an alias). There is a specific RFC (i.e. da rules) which states that an MX must be an ‘A’ record.

You must be logged in to post a comment.