Expected Behaviour:
Requests to local domains should get resolved as set in the dashboard
Actual Behaviour:
According to query logs, they get forwarded to the upstream dns server. I can only get the dns.hostRecord setting to work. Local CNAME records work fine, only A is the problem. It was working fine until I did a routine reboot. Same result with a fresh install of pihole.
Debug Token:
https://tricorder.pi-hole.net/4HA2MnRl/
There are a few irregularities in your debug log, but let's focus on your local A records first.
Please provide an example of a failed dig or nslookup of a local name, along with the corresponding log lines.
I have no idea why but it suddenly started working today, after 5 days.
(For people that find this on Google, here is my workaround I used:
Custom dnsmasq config in /etc/dnsmasq.d/ with host-record entries.)
Now I have a second issue, which is a bit simmilar. Since my pihole is on a macvlan network in docker, my docker host can't reach it directly. So I setup my Fritzbox to use pihole and my docker host to use the Fritzbox. The queries go through pihole but I get an error on the enddevice. Could you help me with that as well or should I make a new post?
nslookup output on my windows pc with pihole directly and through the fritzbox:
C:\Users\Peasplayer>nslookup test.internal fritz.box
Server: fritz.box
Address: 192.168.178.1
*** Keine internal type for both IPv4 and IPv6 Addresses (A+AAAA)-Einträge für test.internal verfügbar.
C:\Users\Peasplayer>nslookup test.internal
Server: pi.hole
Address: 192.168.178.4
Name: test.internal
Address: 192.168.178.3
Output in pihole.log:
2026-08-18 11:32:48.080 query[A] test.internal from 192.168.178.1
2026-08-18 11:32:48.091 /etc/pihole/hosts/custom.list test.internal is 192.168.178.3
2026-08-18 11:32:48.092 query[AAAA] test.internal from 192.168.178.1
2026-08-18 11:32:48.095 config test.internal is NODATA-IPv6
2026-08-18 11:33:36.391 query[A] test.internal.fritz.box from 192.168.178.61
2026-08-18 11:33:36.391 forwarded test.internal.fritz.box to 9.9.9.9
2026-08-18 11:33:36.394 reply test.internal.fritz.box is NXDOMAIN
2026-08-18 11:33:36.394 query[AAAA] test.internal.fritz.box from 192.168.178.61
2026-08-18 11:33:36.424 cached test.internal.fritz.box is NXDOMAIN
2026-08-18 11:33:36.427 query[A] test.internal from 192.168.178.61
2026-08-18 11:33:36.427 /etc/pihole/hosts/custom.list test.internal is 192.168.178.3
2026-08-18 11:33:36.429 query[AAAA] test.internal from 192.168.178.61
2026-08-18 11:33:36.430 config test.internal is NODATA-IPv6
The response is the same, but there are two more requests when I directly use pihole with .fritz.box added to the end, which get forwarded to upstream.
Any idea why they produce different results?
Because test.internal and test.internal.fritz.box are different domains.
It is common that nslookup would issue additional DNS requests, expanding a given domain by the local search domain.
In your case, clients will use .fritz.box, as your router is propagating that as a local domain.
However, your debug log showed that you instead use .internal with your hostnames, while having configured a .pihole.lan domain as dns.domain.name.
You should consider to go along with your router and use fritz.box exclusively as your local domain.
Your debug log has expired by now, but this was one of the irregularities I mentioned.