The issue I am facing: localhost [pi.hole] is displayed in dashboard although "IGNORE_LOCALHOST=yes" is in "pihole-FTL.conf".
Details about my system: Pi-Hole v5.15.5 / FTL v5.21 on a Debian System with PHP 8.1 and Apache2
What I have changed since installing Pi-hole: is that important?
I have installed a fresh PiHole on my Debian server. PiHole is not the only thing running on the server. Among other things, I have an Uptime Bot on it. This pings every 60 seconds +-10 websites. All these pings are of course displayed in the PiHole, and because there are so many of them, it blows up the statistics and the graphs.
A few internet searches later I came across a post that told me to add "IGNORE_LOCALHOST=yes" to the "pihole-FTL.conf" file. I did that and restarted the whole server. In the FTL console I see that this wants to hide the ["IGNORE_LOCALHOST: Hide queries from localhost" in /var/log/pihole-FTL.log], but the domains that are called up are still visible in the top domains list. Under Top clients the pi.hole entry has disappeared. In the query log, however, you can still see the calls from the server.
How can I ban localhost aka pi.hole from the entire dashboard? I don't think it matters if the traffic from the server goes through the PiHole. So a DNS change only for the server is theoretically possible.
PS: You can answer in German, but English is of course also possible
That's only the query log - the dashboard would have been helpul, too.
But not seeing any localhost entries, it would seem that IGNORE_LOCALHOST is working.
If you wouldn't want to see pi.hole as well, you could consider Dan's suggestion.
Or you could consider to configure your uptime bot to ping by IP, avoiding the DNS lookup. Of course, that may only be feasible for fairly static IPs, e.g. when using 184.108.40.206 instead of dns9.quad9.net.
Yes, I don't see localhost either. But the PiHole is on the same server, so I thought localhost and Pihole were the same.
I don't have a problem with localhost, it's not shown to me, but pi.hole is shown, and so are all the pings.
I thought "IGNORE_LOCALHOST" works for localhost AND pi.hole because it comes from the same server.
And I researched. A DNS change on the part of the uptime robot is not possible, unfortunately.
I had the same problem. It was soved by installing the resolvconf package. Since I am on Debian I can not test, but may help this tip:
open (or create) as sudo: /etc/dhcp/dhclient.conf
add: prepend domain-name-servers 127.0.0.1;
I followed these steps and it also worked: pi.hole was no longer displayed in pihole. However, it created another problem.
When I activated it, pihole no longer shows me the hostnames in the dashboard but only the local ips.
For example, in the dashboard under Top Clients it then says
"192.168.178.14" instead of "Workstation-PC".
Do you understand what I mean?
If I then reverse the steps above, the IPs remain in Pihole but the counter continues to count with the host name. The one for the IP stops.
This may be a small thing, but it's important to me. I don't want to always have to look in the router dashboard to see which device I'm inspecting and would like to see the counter by the host name.
So in short: The solution found above is not a solution, but maybe the way to get there?
And no, unfortunately, the Uptime Bot cannot be configured to avoid the DNS search. Unfortunately, I have not yet found a way to change the DNS server for this explicit application.
I doubt that would properly address your issue.
For once, 127.0.0.1 would point straight to your local DNS resolver - likely, your Pi-hole.
And prepend would suggest that 127.0.0.1 is being added to the list of DNS servers that your system's network management tool is aware of, i.e. it may send DNS requests to any of those servers.
This would have been a coincidence.
Pi-hole's DNS operation is independent from the DNS configuration of its hosts.
To verify, run a reverse lookup for an IP address of a known host through your Pi-hole, e.g. dig -x <ipaddress-of-host> @<ipaddress-of-Pi-hole>.
If you stopped/started your Pi-hole in the process, it may take a bit until Pi-hole figures the hostnames, depending on your Pi-hole's configuration.
No, I'm not stupid. I changed the IP to 220.127.116.11, the Cloudflare DNS server. Otherwise the whole thing wouldn't make any sense. And because the entry was automatically saved in the "/etc/dhcp/dhclient.conf" above the local dns server entry by these steps, they were also adopted.
I entered it, but it didn't give me a hostname. Although I am using the PiHole as DNS.
Ok, that would probably mean openresolv or resolvconf isnt installed and the network manager writes DNS info into resolv.conf in some other way or even directly.
It would help if you post the version of your OS so we might be able to figure out how networking is configured?