I'm having an issue with a fresh install of Pihole on my Ubuntu 24.04.1 server with Docker. This was previously working until I wiped and reinstalled my server. At this point I am confused about if the system service should be enabled or disabled. If I disable it, the resolv.conf gets deleted along with the symlink. I also found this post suggesting to change the symlink. I have no experience in that so I am coming here before I do anything. If I enable it, the nameserver will also be replaced with 127.0.0.53 instead of 127.0.0.1 (which I believe is the correct call but need help verifying).
This all started because of this message:
Failed to deploy a stack: compose up operation failed: Error response from daemon: driver failed programming external connectivity on endpoint pihole (d6f27aaa4e5144ace4f49d0d7df7a4528c9521e26ba53fe57882d0e2a3c4ffb8): failed to bind host port for 0.0.0.0:53:172.18.0.2:53/tcp: address already in use
That is when my questions come into play about disabling systemd to free up port 53 for PiHole.
I use OpenWRT on my router, here is where I have the Pihole (Ubunutu server) defined:
All my adlists say "Adlist with ID was inaccessible during last gravity run." when I check the Pihole diagnosis log. The lists are all accessible and valid.
If I run a gravity update, I get the following two errors for each list:
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
When I try to create a debug log, I get this:
* The debug log can be uploaded to tricorder.pi-hole.net for sharing with developers only.
[i] Debug script running in automated mode
* Using curl for transmission.
* curl failed, contact Pi-hole support for assistance.
* Error message: curl: (6) Could not resolve host: tricorder.pi-hole.net
[✗] There was an error uploading your debug log.
* Please try again or contact the Pi-hole team for assistance.
* A local copy of the debug log can be found at: /var/log/pihole/pihole_debug.log
Docker-compose:
version: "3"
services:
pihole:
container_name: pihole
image: pihole/pihole:2024.07.0
ports:
- 53:53/tcp
- 53:53/udp
- 67:67/udp
- 80:80/tcp
environment:
TZ: America/New_York
WEBPASSWORD:
volumes:
- /home/tom/dockervolumes/pihole/etc:/etc/pihole
- /home/tom/dockervolumes/pihole/dnsmasq.d:/etc/dnsmasq.d
cap_add:
- NET_ADMIN
restart: unless-stopped
Nslookup:
tom@ubuntu-server:~$ nslookup github.com
Server: 127.0.0.53
Address: 127.0.0.53#53
Non-authoritative answer:
Name: github.com
Address: 140.82.113.4
tom@ubuntu-server:~$ nslookup github.com 192.168.200.151
;; communications error to 192.168.200.151#53: connection refused
;; communications error to 192.168.200.151#53: connection refused
;; communications error to 192.168.200.151#53: connection refused
;; no servers could be reached
tom@ubuntu-server:~$
Edit: I was able to pull this log as well:
[i] Target: https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: using previously cached list
[✓] Parsed 127471 exact domains and 0 ABP-style domains (ignored 1 non-domain entries)
Sample of non-domain entries:
- "0.0.0.0"
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/pro.plus.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/tif.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/dyndns.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/hoster.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/spam-tlds-adblock.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/native.amazon.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/native.apple.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Target: https://raw.githubusercontent.com/hagezi/dns-blocklists/main/adblock/native.samsung.txt
[i] Status: Pending...
[✗] Status: Connection Refused
[✗] List download failed: no cached list available
[i] Building tree...
[✓] Building tree
[i] Swapping databases...
[✓] Swapping databases
[✓] The old database remains available
[i] Number of gravity domains: 127471 (127471 unique domains)
[i] Number of exact blacklisted domains: 7
[i] Number of regex blacklist filters: 1
[i] Number of exact whitelisted domains: 208
[i] Number of regex whitelist filters: 3
[i] Cleaning up stray matter...
[✓] Cleaning up stray matter
[✓] FTL is listening on port 53
[✓] UDP (IPv4)
[✓] TCP (IPv4)
[✓] UDP (IPv6)
[✓] TCP (IPv6)
[✓] Pi-hole blocking is enabled
fatal: unable to access 'https://github.com/pi-hole/pi-hole/': Could not resolve host: github.com
fatal: unable to access 'https://github.com/pi-hole/web/': Could not resolve host: github.com
fatal: unable to access 'https://github.com/pi-hole/FTL/': Could not resolve host: github.com
Pi-hole version is v5.18.3 (Latest: N/A)
web version is v5.21 (Latest: N/A)
FTL version is v5.25.2 (Latest: N/A)
Container tag is: 2024.07.0
Stopping pihole-FTL
Terminated
Stopping pihole-FTL
Terminated
Stopping pihole-FTL
Terminated
Stopping pihole-FTL
Terminated
Stopping pihole-FTL
Terminated
s6-rc: info: service legacy-services: stopping
s6-rc: info: service legacy-services successfully stopped
s6-rc: info: service _postFTL: stopping
s6-rc: info: service _postFTL successfully stopped
s6-rc: info: service lighttpd: stopping
Stopping lighttpd
s6-rc: info: service lighttpd successfully stopped
s6-rc: info: service pihole-FTL: stopping
Stopping pihole-FTL
Terminated
s6-rc: info: service pihole-FTL successfully stopped
s6-rc: info: service _startup: stopping
s6-rc: info: service _startup successfully stopped
s6-rc: info: service _uid-gid-changer: stopping
s6-rc: info: service _uid-gid-changer successfully stopped
s6-rc: info: service cron: stopping
Stopping cron
s6-rc: info: service cron successfully stopped
s6-rc: info: service legacy-cont-init: stopping
s6-rc: info: service legacy-cont-init successfully stopped
s6-rc: info: service fix-attrs: stopping
s6-rc: info: service fix-attrs successfully stopped
s6-rc: info: service s6rc-oneshot-runner: stopping
s6-rc: info: service s6rc-oneshot-runner successfully stopped