Setting up Registrar email service with Digital Ocean DNS

August 20, 2014 6k views


I am using a mail service from my registrar Gandi where is my domain in order to have an email like !
I am using Digital Ocean DNS so Gandi tell me to put in a zone file this :

pop 10800 IN CNAME
webmail 10800 IN CNAME
smtp 10800 IN CNAME
imap 10800 IN CNAME
@ 10800 IN MX 10
@ 10800 IN MX 50

I add this to my in etc/bind directory (Debian) and also add to DNS control panel from Digital ocean.

Seems have somme errors when testing with this command : named-checkconf -z

zone loading from master file /etc/bind/ failed: CNAME and other data
zone not loaded due to errors.

or with nslookup :

** server can’t find NXDOMAIN

What i am doing wrong ? Thanks for your help.

  • Hi,

    Could you please indicate how you managed to setup the DNS from the control panel ? I’m having exactly the same issue and trying to save them in the zone file, but I can’t understand how to generate these instructions with an “IN” from the control panel.

    Thank you

  • Did you ever figure this out?

4 Answers

Are you using DigitalOcean’s DNS servers or are you using bind to create your own nameservers on a DigitalOcean droplet? In Gandi’s control panel, did you change your nameservers?

It looks like maybe you’ve worked this out already? I’m seeing the CNAME working correctly:

# dig

; <<>> DiG 9.9.5-3-Ubuntu <<>>
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 21329
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1

; EDNS: version: 0, flags:; udp: 512
;       IN  A

;; ANSWER SECTION:    1799    IN  CNAME  18543   IN  A

;; Query time: 195 msec
;; WHEN: Wed Aug 20 16:26:18 EDT 2014
;; MSG SIZE  rcvd: 99

I am using Digital Ocean DNS on Gandi name server. It ’s ok.
Working ?? Hum, will check that.

Many thanks Andrew. Coming back to you.

Ok, i can receive email at last on the email … So it’s works.
Seems to only have to set gandi’s CNAME and MX on Digital Ocean DNS panel and not on this zone file on bind. Still have errors (same) on it.

What do you think ?

  • Well if it’s working, then you’re fine! =) Bind is for setting up your own DNS nameservers. Most likely, you don’t need to do that.

Zone file undo like before.
Only DNS on Digital Ocean set.

Everything work fine.

Thank you :)

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!