26

When I typically update DNS ("A" records) I will allow for an extended period of time for the changes to propagate throughout the root nameservers.

Do I need to make this same allowance for updates and changes to CNAME records?

Jaryd Malbin
  • 405
  • 1
  • 4
  • 6
  • possible duplicate of [How long does it take for an A record to propagate?](http://serverfault.com/questions/125371/how-long-does-it-take-for-an-a-record-to-propagate) – Michael Hampton Aug 08 '12 at 05:57
  • @MichaelHampton - true, if we change `an A record` to `DNS records` in the title of that question. Neither question is specifically about A records. [update] I have submitted that edit. – Henk Langeveld Aug 08 '12 at 07:21

2 Answers2

33

No you don't because DNS records don't propagate. What you do need to allow for is for any cached records to expire, based on the TTL of the record in question.

If this is a new record, no caching can have occurred so the new record should be available and should resolve immediately.

Additionally, the root servers (first level; .) don't host DNS zones or records for any third level domain names. The root servers know which name servers are responsible for the gTLD zones (second level; .com, .edu, etc.), which in turn know which name servers are responsible for your zone (third level; yourcompany), which in turn hold a copy of your zone file. No other DNS server holds a copy of your zone file or DNS records other than your name servers.


  1. .

  2. COM

  3. YOURCOMPANY

joeqwerty
  • 108,377
  • 6
  • 80
  • 171
3

[Edit - It appears I misread the question]

There are two ways in which your zone data 'propagates'. And the root servers are not (directly) involved. They allow other computers to find your servers, and hence your zone data. But it's other systems that check the root and tld servers before they get down to yours.

Here's how your data does propagate.

First, you push that data to your authoritative servers, and some of those may use (incremental) zone transfer to update each other. This may take up to the REFRESH time of the zone to complete.

Second, each record in your zone, and that includes anything, including A and CNAME records, may be cached anywhere between your authoritative servers and any clients.

How long that data is cached should depend on the record's individual TTL (time to live). Theoretically, it should not take longer than the sum of the zone refresh and the record's ttl for a cached entry to time out. However, there's a lot of different software out there. Google for dns ttl bugs - last count I did was around 850k.

But you can have CNAME records for www.example.com point to something like www-server.dynamic.example.com, and set the TTL and refresh times for stuff inside dynamic.example.com to much lower values than the parent. This allows operators to quickly redirect traffic to other infrastructure when the need arises.

Henk Langeveld
  • 1,294
  • 10
  • 25
  • 2
    Setting a faster TTL only helps in situations where the DNS cache servers are not overriding or ignoring the TTLs set in the zone files, which is unfortunately more common than one would think. – tacotuesday Aug 07 '12 at 23:23
  • 2
    And becoming more common all the time. Plus, many systems will only obey the TTL if it's greater than some predefined period, so the shorter you make the TTL the more likely it will be ignored. – John Gardeniers Aug 08 '12 at 06:49