I need some help with DNS, I was using a pihole server on my LAN, and now I’m changing to unbound on my opnsense router/firewall. I have already changed the main DNS server in HA, but my pihole server is still getting DNS traffic from ther HA IP address, I have spent some time checking all apps and just cannot figure out where is configured on HA. Not the end of the world, but this is preventing me decomissioning the pihole, so any pointers will be appreciated
Settings → System → Network if you are on static IP change the highlighted red below to point to the LAN interface of OPNsense. If you are on DHCP (Automatic) in OPNsense under DHCP server make certain DNS is empty.
If you have the time check my OPNsense and Pi-hole guides .
Thanks
I already updated that record with the new IP address
But somewhere the old IP is lurking…
Check your HA config file. Issue is inside HA assuming you are not on static IP. Can u share a screenshot of your HA network settings.
There is nothing wrong there
Just changed to automatic as I have a dhcp reservation:
The DNS entry is the new IP address:
the old IP address is 192.168.1.237, but cannot find it in any of the configuration files I checked
Unless is hidden in docker, but even ha OS shows the same info:
Are you sure its not something else on that .237 IP now?
In HA terminal type the command arp
and share the output with us please.
pihole is still reporting dns queries from hassio:
Name resolution shows the 192.168.1.237:
So it seems there are stil some processes using the old iP
BTW, I did a reboot today of HA, just in case, but id not make much difference
Those domain names of hassio.home are not standard HA. I suggest your HA installation is sound and pi-hole can be retired; only thing is some of your integrations might fail or hopefully adjust to the new DNS server.
And have you rebooted pihole?
If you pi is wired ethernet, detach and attach the cable would also reset all network settings… (not settings but MAC learned etc.)
I could try that, but is that not the same that happens when you reboot the box?
Besides, it has already picked the right address - unless it s lying!
Yes the same, but rebooting is more intrusive
in that case unplugging/ replugging the nic won’t make a difference
if the problem is one of IPs, how a mac list will help?
there is an excerpt with the hassio associated mac addresses:
I think I may have figure it out
I have ran these commands from HA OS:
ha dns options --servers dns://192.168.1.254
ha dns restart
the original configuration was:
the new one is:
Now there are TWO dns entries, I suspect it was using the wrong ( maybe default) one
Now I cannot see any traffic to the old pihole server from HA
I am afraid, this is a workaround not a solution. I suggest you check your DHCP server as the problem lies there. You might have 2 DHCP servers active handing out different DNS servers, in which case your DHCP infrastructure requires attention.
HA will use locals if there are no upstream servers defined, therefore your DHCP server is handing out an out of date DNS server.
I think you are right
I thought I solved the problem, but later I checked pihole, and there were some queries from HA, not as many as before, but some.
I logged into the raspberry underlying OS and checked /etc/resolv.conf and is the new one
Also tried to do some nslookup queries and none were reaching pihole ( not even from ha cli)
So I’m still puzzled as to why is still trying to use the old dns server
btw, now all the traffic seems to be going to github.com:
I wonder if this is related in any way with HACS
Check your Pi-hole has DHCP disabled.