Run a Local DNS Server for internal lan on TrueNAS 13?

Geoff

Dabbler
Joined
Jul 11, 2013
Messages
25
You really should read more carefully, this was already brought up pretty explicitly in this very thread. And it isn't like iX are making any secret of this:

In the thread, yes. Prior to this, I had no idea. I've not touched TrueFree/NAS in years, last time I went through their site, FreeNAS was still live. I did an update through the web interface under Updates a few days back, just changed the stream. That got me to 12.x, then changed to 13 same way. This is the first time I've needed to ask questions since then.

I gave the exact commands to do this up-thread.

Thank you. I've found it. Unfortunately, I got sidetracked with DNSMASQ, decided to bail on it as too hard. Just did (pkg install adguardhome) Managed to install it as a service, can't seem to start it that way. I'll figure it out.
Once again, this has already been discussed up-thread.
Ok, I'm not seeing this, or perhaps not comprehending. I saw a reference to 'DNS Host Overrides' - whatever that is - no detail on configuring a local domain - at least not in ADGuardHome. It mentions this:
"Private reverse DNS servers
The DNS servers that AdGuard Home uses for local PTR queries. These servers are used to resolve PTR requests for addresses in private IP ranges, for example "192.168.12.34", using reverse DNS. If not set, AdGuard Home uses the addresses of the default DNS resolvers of your OS except for the addresses of AdGuard Home itself."

If I comprehend this, it seems to expect a DNS somewhere that handles the local 'inside' domain. It doesn't do it itself.
So, I don't have it enabled as obviously there's no 'DNS server for local PTR queries'.

However, under "Use private reverse DNS resolvers" it says "Perform Reverse DNS lookups for locally served addresses using these upstream servers. (this is not enabled so there are no 'upstream servers' listed for this, as explained above. But, it also says "If disabled, adguard responds with NXDOMAIN to all such PTR requests except for clients known from DHCP, /etc/hosts and so on."

Seems to imply anything in HOSTS will be used to resolve local (and probably other) systems.

Accordingly, I have (after pkg install nano to get a somewhat useable editor) edited the HOSTS file in /etc and listed all my local machines and single host names (not FQDN).

Seems to work. At least so far.

PS C:\Windows\system32> nslookup
Default Server: ADGUARDJAIL
Address: 192.168.11.251

> router
Server: ADGUARDJAIL
Address: 192.168.11.251

Non-authoritative answer:
Name: router
Address: 192.168.11.1

Non-authoritative answer:
Name: freenas
Address: 192.168.11.250

> brotherprinter
Server: ADGUARDJAIL
Address: 192.168.11.251

Non-authoritative answer:
Name: brotherprinter
Address: 192.168.11.215

> mainswitch
Server: ADGUARDJAIL
Address: 192.168.11.251

Non-authoritative answer:
Name: mainswitch
Address: 192.168.11.39

> hplaser
Server: ADGUARDJAIL
Address: 192.168.11.251

Non-authoritative answer:
Name: hplaser
Address: 192.168.11.169

Interestingly, if I try and use this on Edge, I get a 'Server IP address not found'. Not sure why. Yet.

Also works in my really ancient Netlab 1.4 (which still mosly works in Win10 DNS on that resolves fine, so not sure what Edge's problem is (Other than being Edge realistically), but might be expecting an FQDN, I'll tinker.

Thank you for your knowledge and patience. It's (mostly) working and the adblocking is very much a bonus.

Regards

Geoff
ETWebs
 

Geoff

Dabbler
Joined
Jul 11, 2013
Messages
25
Gentlemen,

Thank you for your kind assistance and your patience.

ADGuardHome is running happily in a jail and working fine.

All it needed to get the internal LAN to be usable with hostnames was to edit the HOSTS file in the jail.
Made one false start and didn't use a FQDN then hostname in the format.
hostname.mydomain hostname
This upset browsers as Adguard returned an NXDOMAIN. Direct NSLookups worked.
Edited to include the FQDN and append the hostname as above and it works there too now.
Now just need to reorg the DHCP server on the router to assign IP addresses in some semblance of order.

Thanks again for all your knowledge and help. And patience (especially patience)

Regards

Geoff
ETWebs
 
Top