Please follow the below template, it will help us to help you!
Expected Behaviour:
Would like to be able to resolve both my pi-hole and my router by name
Actual Behaviour:
unknown host errors
Debug Token:
zk8c3io6h5
I tried adding the name of the router, maximillian, to /etc/hosts (with just the short name) but pinging either maximillian, or the pseudo-fqdn, yields an unknown host. I note that /etc/hosts has an entry for the pi-hole, but it only resolves to the 127.0.0.1 address, which might be fine for on-machine, but not off.
I thought that the pi-hole software read in /etc/hosts on startup to gather in other names. So if that's not it, what is the approved mechanism, and if it is that, what did I do wrong?
Pi-Hole is setup as DHCP, and is handing out home.tastewar.com as the local domain. I've tried maximillian.local as well, though, with no success. Yes, the pi-hole has been rebooted numerous times since that edit. So, if that is the normal/supported mechanism, there must be something I've missed.
The query log shows those incoming queries, and an NXDOMAIN result.
So, as part of getting local name resolution working in general, avahi was disabled to avoid any possible confusion. And local name resolution is generally working. It's just these last two cases, where the servers in question have static configurations and don't communicate with DHCP.
I have gotten the router's name to resolve by fixing my /etc/hosts entry. It had been:
But I'd be concerned about breaking anything that relies on the original entry. Any guidance on this one?? Unless I'm missing something, it seems that without a resolvable name, everyone using pihole must be typing its IP address into the address bar to get to the Web UI. Or manually edit the hosts file on all nodes in the network they might want to get to the pihole interface from, and that seems unlikely.
I have a local.list file in /etc/pihole, which I really don't believe I ever touched manually, and it has two entries:
10.10.10.186 pihole
10.10.10.186 pi.hole
From a Mac on my lan, I can ping pi.hole, but not pihole (unknown host).
So I'm left wondering where those came from and why one works and the other does not. Anyway, I removed the loopback entry for pihole, and added a good entry, and now it seems to work OK. Thanks for the help.