Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have two domains: '' and '' and a server - ''

At the moment the mail for '' is hosted elsewhere so I have set up postfix, dovecot etc to be able to host email on two domains. The setup seems fine with local command line testing.

So I have two mx records on '' pointing to hosted mail servers elsewhere which i want to eventually delete.

I have an A record pointing to 123.456.123.456 ( on both DNS zones '' and '' and I did have a '' MX record pointing to ip address until i changed the FQDN to

Now I have added an MX record to to point to (can I add an A record -

I can't now add an MX record on to point to

If i dig mx it is not showing anything - its only been a couple of hours maybe it needs time to propogate.

so DNS zone ''

@               IN  300 A
@               IN  300 MX  10
@               IN  300 MX  20

www             IN  300 A   #(

mail            IN  300 A
mail2           IN  300 A

DNS zone ''

@               IN  3600    A   #(
@               IN  3600    MX  10

mail            IN  3600    A
www             IN  3600    A

Can anyone tell me what I am doing wrong here?

share|improve this question

1 Answer 1

There seems to be a degree of misunderstanding about the function of MX records, but in essence the problem seems to be that although the MX record for points to, there's no A record for

I think if in the zonefile for you define an A record for pointing to, then mail for should start going to your new server. If in addition you change the MX record for to and remove the two existing MX records, then mail for should also start going to your new server.

You don't need an MX record for

In addition, may I encourage you not to redact the domains in questions like this one? When investigating the DNS, it's often very helpful to know the real domains, and it can sometimes be impossible to solve if the real data are not given - see this question and answer for an example.

share|improve this answer
Thanks for the reply. It appears if i send a message from gmail to the virtual domain it ends up in the mailbox on the server...which doesn't make a lot of sense unless dns has propogated and now all is ok. If i try to configure a mail account from thunderbird it claims it doesnt find the configuration although i do get messages in dovecot log pop3-login: Info: Aborted login (no auth attempts): rip=, lip=, secured –  Ed Phillis Mar 19 '13 at 12:37
OK, so what, exactly, is your question? –  MadHatter Mar 19 '13 at 15:06

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.