Hello there I have a local server (virtual machine) configured using "The Perfect Server" tutorial (Debian 9), and I'm trying to set up a name service for my local network following this tutorial. I'm able to reach the server if I enter the DNS entry in the client /etc/hosts file, but if i run the "host localdns.tld [Local DNS IP address]" command, I get the following output: Code: Host localdns.tld not found: 3(NXDOMAIN) My records are identical and i'm still unable to reach it by without entering a record in the client's /etc/hosts file. Is there something missing from the tutorial?
Likely something missing from your zone file (eg. A record for the zone), or the there was an erorr so the zone didn't load. What's in the zone file on the server? (/etc/bind/pri.localdns.tld)
Okay, Checked the records again and I had forgotten the period at the end of the data section of the NS record. The host command produces the expected result. Now there's the issue of being unable to ping the domain if I remove it from the client /etc/hosts file. I thought adding the local server to the Nameservers field in Server Config might be the problem, but that didn't work either. Why would it behave this way?
And I figured it out. It turns out my network manager was simply appending the my local DNS to /etc/resolv.conf and so my linux client was still using the automatically configured DNS server (internet router). Had to set networkmanager to 'Automatic (DHCP) addresses only'. Hope this helps someone else facing similar issues.