-1

Is it possible to have an authoritative dns server that I host on my server that has a dynamic IP?

I use a dynamic dns client to update my IP with namecheap but want to have a DNS server I control as well. Is it possible for my subdomain ns1.sub.example.com to be on my server?

I would use the dynamic dns client to update ns1.sub.example.com

Update: Looks like it works. Dynamic DNS updates A record for main.example.com NS points to subdomain and the name is the A record main.example.com all queries are being forwarded to my dns server.

uid500
  • 1
  • 2

1 Answers1

0

An authoritative nameserver must have a fixed IP address, as this address needs to be known by the authoritative nameservers for the higher level domains. For example, if your domain is example.com., then the nameservers for com. need to know what the nameservers are for your domain. This is done through your domain registrar, who forwards the updated information to the DNS servers which need to know it. If for some reason your IP address changed, you would need to update this at your domain registrar and your DNS server would be inaccessible until that update took place.

For the case of a subdomain, e.g. sub.example.com., you have to update the NS records for that name in the zone example.com. yourself. Typically dynamic DNS clients only update address records, not NS records, though maybe you could hack something up. But the nameserver for example.com. still has to be available as described above.

All this is a very long way to say, don't host DNS at home. It will not be reliable.

Michael Hampton
  • 244,070
  • 43
  • 506
  • 972
  • Thanks for the info! It is more of just curiosity, as I don't have anything I need to resolve. It is more just to learn how to do it. – uid500 Aug 02 '20 at 14:40