1

Say I want to point my domain blah.example.com from a server located at IP addres 1.2.3.4, to a different server located at IP address 5.6.7.8. This requires a DNS change.

Why is it that when I log into my GoDaddy cPanel account, and make a DNS change to one of my nameservers, that it can take for up to 24 hours for DNS to "propagate" around the world and be 100% in effect, but if I use a service like DynamicDNS or CloudFlare, the change occurs instantly?

Mara
  • 139
  • 1
  • 11

2 Answers2

5

Because it actually isn't an instant change with DynamicDNS or CloudFlare. No matter what service you use, there is a time starting at the time you make the change lasting until the cached records expire on all the other DNS servers in the world. This time is governed by the TTL, which for some services (like DynamicDNS) is kept low to allow for frequent changes, and in others is kept high to allow for more efficient caching.

John
  • 8,920
  • 1
  • 28
  • 34
  • Although the above is correct, you must also remember that the TTL countdown only starts when the records are changed on all of the domain's nameservers. You will often see delays of a few minutes to a few hours on lower quality hosting services (e.g. godaddy) between changing a setting in the web interface and it appearing on all nameservers. – phil-lavin Dec 10 '13 at 19:06
  • I second that. I've updated a zone file on GoDaddy and queried the nameserver directly over an hour later and still gotten old information. – saltface Dec 10 '13 at 20:41
1

To be clear when you "change DNS" there are two different things I think of:

1) Changing name servers - The name servers should be changed instantly at the registry. DNS cache may come into play. Lets say you are using the name server 1.2.3.4. You visit your website ticketmonster.com. Your DNS server will have cached the results from the root name servers that tell it where to find the DNS records for your domain. You then change the name servers on your domain and visit it again. Assuming you hit the website before the DNS cache expires you will still be hitting the old website.

If you didn't visit the website before changing the name servers (and you are not using a public name server which has cached it because someone else visited it) then you will most likely see the change within a second or two.

There are other exceptions (clusters may not cache the entry as you may hit a different DNS server each time) but that is a basic overview.

2) Changing DNS records on existing name servers - Lets say you are adding/removing an A record. There can be a couple of reasons for a delay. You may run into the caching issue like above. If there are multiple name servers that do zone transfers to replicate the zone you may need to wait until that is done (the TTL's in the zone file can be lowered to make this quicker). If there is some other form of replication involved there may be a delay with that.

There are other cases depending on exactly how the DNS is setup but those are the common reasons I can think of off the top of my head.

Changing the TTLs may help if you require the changes to be made faster but beware some caching name servers ignore them and set what ever they want.

shthead
  • 365
  • 1
  • 4