Unable to configure DNS properly

January 18, 2018 643 views
DNS Ubuntu 16.04

I bought a domain on go daddy, edited the dns records to ns1, ns2 and ns3.digitalocean.com, added a domain to my droplet, added an A record with the parameters '@' and the ip address of my droplet, saved everything. I still can't get the domain to resolve, I installed apache on the droplet and I can access it if I enter the IP address of the droplet. What am I doing wrong here ?

1 comment
  • It sounds like you did everything correctly. Note you need to create DNS for www.yourdomain.com and yourdomain.com. That is www is a subdomain.

    Note that on the main "domains" page, you can click on "more" and download the zone. The zone contains all your DNS information in a manner where you could post it here.

1 Answer
ryanpq MOD February 8, 2018
Accepted Answer

There are two common reasons why issues are encountered at this stage of DNS configuration. As @gc948486cbc56b8 said, it sounds like you've done everything right.

  • If you created your domain in our DNS system with a subdomain like www.domain.com rather than as domain.com A records under it will be creating second level subdomains like sub.www.domain.com rather than regular ones like sub.domain.com

  • When you first register a domain it may take up to 24-48 hours for it to propagate depending on the registrar. When pointing the domain to a new set of nameservers there can be a similar propagation time at first before the domain begins working from everywhere.

You can use the nslookup tool to check that your records are returned correctly from the authoritative server. nslookup offers an interactive mode where you can specify the nameservers to look up an address on so you can see that they are returning the right data.

ryan@workstation:~$ nslookup
> server ns1.digitalocean.com
Default server: ns1.digitalocean.com
Address: 173.245.58.51#53
> digitalocean.com
Server:     ns1.digitalocean.com
Address:    173.245.58.51#53

Name:   digitalocean.com
Address: 198.211.111.227
Name:   digitalocean.com
Address: 198.211.111.226

Have another answer? Share your knowledge.