It is common to provide 'glue' records along with NS records, to spare DNS resolvers the bother of looking up the IP address of the DNS server itself.

However, it is not even desirable to provide glue in some situations (eg. example.com NS ns.example.net ... it is not appropriate for a .com nameserver to dish out information about .net domains). In that case, there is a risk that DNS resolvers, lacking the glue information, will take longer to resolve the domain.

But how much longer? Is it worth defining my own A record for ns.example.com to point to the IP address of ns.example.net (a so-called 'white label' or 'vanity' nameserver, such that I can provide glue? Or does it not matter much in practice?. Why not?


1 Answer 1


Glue is needed when the name servers for a given domain e.g. example.com are host names inside that domain, e.g. ns1.example.com. Without that glue it would be impossible to resolve anything inside example.com.

In fact you should try to avoid situations where glue is necessary, as a misconfiguration where the glue is erroneously omitted from the zone will lead to the domain not being resolvable. The extra lookup needed is measurable but in practice not noticeable. It helps if one of the name servers is a well-used one so that chances are it's already in the cache, e.g. belonging to the registry where you've registered your domain; many domain registries offer their name servers for use as secondary name servers.

You should also look out for loops in resolving, e.g. name servers for example.com are in the example.net domain, and name servers for example.net are in the example.com domain. This will not lead to glue automatically created, but can result in neither domain being resolvable (unless one of the name servers has been cached already). I've seen this happen so it's not a theoretical situation :-)

  • OK, that's a good point about when glue is needed. So if I do supply 'vanity' glue ... BEST: the DNS resolver didn't already have the NS in its cache, but it now has that info; WORST: I sent a few extra bytes than I needed to and I run a risk of providing wrong glue at some point and breaking my site. On the other hand, if I don't supply vanity glue: BEST: the resolver already had the NS in its cache and I wasted a few bytes, WORST: the resolver did not have the NS cached and now has to look it up. Apr 22, 2015 at 8:08
  • you should try to avoid situations where glue is necessary. How is that possible?
    – cherouvim
    Nov 16, 2016 at 10:11
  • @cherouvim use at least one nameserver in another domain, so if you're creating example.com you should also have one nameserver e.g. ns2.example.net.
    – wurtel
    Nov 18, 2016 at 15:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.