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

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have one of my domains on the 2nd level domain, registered with 123-Reg, a British DNs provider, and I get various services on that domain from Google Apps, by the note US company.

I would like to use a sub domain for services provided by another provider, specifically I would like to get PEC services from an Italian provider. PEC is an italian standard to digitally sign and certify emails, and basically I would like to use a pec.[mydomain] 4th level domain (you may read RFC 6109 for further details about PEC, but I reckon that's not really necessary to answer my questions below, from my understanding on the DNS side it should really work as an usual mail server) for such PEC services.

From my understanding so far, I need to set up a MX record to point to the PEC provider (usually something like mx.pec.[provider].it.).

Currently my DNS settings look like this:

@   A       [x.y.w.z]
calendar    CNAME
mail    CNAME

Am I right to think I should add at the very least a MX record as:

pec MX  10  MX.PEC.[provider].IT.

Also, I am right to think I'll have to add an A record, or a CNAME (whatever the Italian provider will ask me really, although I hope a CNAME will be enough), for pec as well?

Update 1

Just an update: I did purchase the PEC service from an Italian provider for a 4th level domain (on the .uk TLD, not the .it), they did let me apply for pec.[mydomain], and then they did sell me a mail box on that domain (something like me@pec.[mydomain] They haven't yet sent me any special configuration info or request (I reckon I'll have to wait for the end of the process, they are currently "certifying" my domain, whatever they mean with certification in this context). I have decided to speed up things from my side, so I have already updated my domain DNS (serendipitously the provider I chose actually had their required mx record somewhere in the contract), so that my domain is already answering to mx lookups:

Default Server:  [mydnsserver]
Address:  x.y.w.z

> set q=mx
> [mydomain]
Server:  [mydnsserver]
Address:  x.y.w.z

Non-authoritative answer:
[mydomain]     MX preference = 5, mail exchanger =
[mydomain]     MX preference = 10, mail exchanger =
[mydomain]     MX preference = 10, mail exchanger =
[mydomain]     MX preference = 5, mail exchanger =
[mydomain]     MX preference = 10, mail exchanger =
[mydomain]     MX preference = 1, mail exchanger =
[mydomain]     MX preference = 10, mail exchanger = internet address =   internet address =   internet address = internet address =   internet address =      internet address =   internet address =
> pec.[mydomain]
Server:  [mydnsserver]
Address:  x.y.w.z

Non-authoritative answer:
pec.[mydomain] MX preference = 10, mail exchanger = mx.pec.[provider].it

mx.pec.[provider].it internet address = i.j.k.l

Update 2

At the moment, the answer is still a delivery failure (the reason is given in Italian, it stands for "The message was refused by the system. The address of the receiver is unknown, or it is not enabled to the reception of non certified mail"):

Delivery to the following recipient failed permanently:


Technical details of permanent failure:
Google tried to deliver your message, but it was rejected by the recipient domain. We recommend contacting the other email provider for further information about the cause of this error. The error that the other server returned was: 554 554 <me@[mydomain]>: Messaggio rifiutato dal sistema. Indirizzo destinatario sconosciuto o non abilitato alla ricezione di posta non certificata. (state 14).

But I reckon at the moment I have just to wait.

Update 3

I got the PEC mailbox settings from the provider, and everything works fine, the message were not delivered because by default PEC providers do not accept mails from non PEC mailbox, I had to fiddle with the settings to allow those in, and even after they are received in a funny way (they are marked as an "anomaly"), but all this is PEC specific, it does look like from a DNS point of view that all is required is just a MX record.

share|improve this question
up vote 3 down vote accepted

If you need mail for to be delivered, then yes, your DNS record is correct. You only need an A or CNAME record if the hostname is used for non-mail delivery purposes (e.g. a website at run by the PEC provider). You should really just get the exact requirements from the provider before updating your DNS setup though.

share|improve this answer
Thanks Mick, it was easier than I thought, but I hope this may be helpful if some other one will need to set up a DNS entry to support PEC services on non .it. domains. By chance, years ago I used to work for a guy from Durban, a nice chap, he taught me quite a lot about SQL, curry and mangoes :) – aledeniz Jun 22 '12 at 10:24

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.