Hello, I’m asking for help. I’ve been trying to solve my Pi-Hole problem with AI for several days now, and I seem to be giving up. Everything seems to be working fine, but Pi-Hole keeps throwing an error: Connection error (172.20.0.2#53): TCP connection failed while receiving payload length from upstream (Connection prematurely closed by remote server).
I have a network based on Omada OC200 with a TP-Link ER605 V2 router with IP address 192.168.0.1 and IP address 192.168.0.9 entered as the DNS server. I have a server with truenas community version 25.04.2.6 with IP address 192.168.0.3:880 and physical LAN interface eno1 and one eno1 bridge named br0 and the DNS server set to IP 192.168.0.9. On truenas I installed Nginx proxy manager plus version 1.0 at IP address 192.168.0.3:30360. On Truenas I installed the dockge application at 192.168.0.3:31014. In docgke I started Pi-Hole V6 at 192.168.0.9 and DNS server 172.20.0.2#53 and with Unbound entering the following code:
If you are doing recursive must have pihole talk to itself first over port 5335. Pihole cannot use 53 since it is already in use for regular dns traffic. Set recursive 127.0.0.1#5335 first, then all other DNS resolvers.
After changing to 5335, it’s exactly the same. I’ve already checked this, but this shouldn’t be an issue for me because I use PiHole and Unbound in separate dockge containers and have different IP pools.
Is pihole resolving urls? Pihole does get errors when resolving insecure connections sometimes. If you can browse and resolve dns, it should be fine. I wouldn’t worry too much about error messages from time to time.
PiHole is working fine. There’s no problem with DNS, just this error message. I also just recently stopped working on Pi-Hole and started configuring Nginx Proxy Manager, and I see it’s not working. I suspect I need to enter an IP address and port number somewhere in Pi-Hole so that, in addition to unbound, PiHole also sends DNS queries to Nginx. I’d also like to ask about Pi-Hole’s RAM usage. Mine is around 90%, supposedly I don’t have a loop, and I don’t know what’s going on. Is this information about the RAM usage of the entire TrueNAS, with ZFS taking up most of the memory, or do I actually have a loop?
You will need to create a bridge for vms & containers to talk to each other in TrueNAS. Depending on your firewall, your may need to open port 53 to allow traffic across subnets or within the subnet.
AI gave me the following response to the TrueNAS Shell command:
ip link add macvlan-shim link br0 type macvlan mode bridge
ip addr add 192.168.0.10/32 dev macvlan-shim
ip link set macvlan-shim up
ip route add 192.168.0.9 dev macvlan-shim
Is this a good solution?
I still need to change unbound.conf: