markpickford

Member
Mar 28, 2013
8
0
1
cPanel Access Level
Root Administrator
Hi,

I am very new to DNS and have encountered a problem that I can't seem to solve.

If I edit a DNS zone in WHM and then save the changes I get the following error:

zone mydomain.co.uk/IN: mydomain.co.uk/MX 'mail.mydomain.co.uk' is a CNAME (illegal) zone mydomain.co.uk/IN: loaded serial 2013032802 OK

Can anyone help me with this issue please.

Thanks in advance,

Mark
 

mtindor

Well-Known Member
Sep 14, 2004
1,363
65
178
inside a catfish
cPanel Access Level
Root Administrator
Sounds like you have your MX record pointing to mail.mydomain.co.uk AND mail.mydomain.co.uk is a CNAME to some other record.

MX records should not point to CNAMES.

Bad:

domain.com. IN A 1.2.3.4
domain.com. IN MX 10 mail.domain.com.
mail.domain.com. IN CNAME domain.com.

Good:

domain.com. IN A 1.2.3.4
domain.com. IN MX 10 domain.com.

Good:

domain.com. IN A 1.2.3.4
domain.com. IN MX 10 mail.domain.com.
mail.domain.com. IN A 5.6.7.8

m
 

markpickford

Member
Mar 28, 2013
8
0
1
cPanel Access Level
Root Administrator
Thanks for the quick reply.

The only MX and CNAME entries are:

mydomain.co.uk. 14400 in MX 0 mydomain.co.uk.
mydomain.co.uk. 14400 in MX 10 mail.mydomain.co.uk.
mail 14400 in CNAME 100.100.100.100 (not real IP address)
www 14400 in CNAME my domain.co.uk

I hope this helps and thanks for the assistance.
 

mtindor

Well-Known Member
Sep 14, 2004
1,363
65
178
inside a catfish
cPanel Access Level
Root Administrator
Mark,

A CNAME should not reference an IP address -- it should reference a hostname. And in the case of MX records, an MX record should not point to a CNAME.

So you've got two things wrong.

1. mail 14400 in CNAME 100.100.100.100 (not real IP address)

This is incorrect. a CNAME [if needed] should reference a hostname [not an IP] on the righthand side

2. mydomain.co.uk. 14400 in MX 10 mail.mydomain.co.uk.

This MX record is pointing to mail.mydomain.co.uk, which is currently an [improperly created] CNAME.

My recommendation:

Change:

mail 14400 in CNAME 100.100.100.100 (not real IP address)

To:

mail 14400 in A 100.100.100.100 (not real IP address)


NOTE: if mydomain.co.uk and mail.mydomain.co.uk point to the same IP, then there is no reason to have both of the MX's above. Use only the MX that points to mydomain.co.uk or the one that points to mail.mydomain.co.uk. But just make sure that mydomain.co.uk or mail.mydomain.co.uk is (a) an A record and (b) points to the IP address of the server responsible for handling mail.

m