DHCP (and sometimes DNS) server stopped working

Expected Behavior:

The DHCP server should issue IP addresses.

Actual Behavior:

The DHCP server isn't issuing IP addresses.

Background:

My Pi-hole DHCP has been working as expected for several days. However, I've been experiencing issues resolving my local domain names. (I use the fake TLD .mss for all of my local domains.) Recently, when testing I had pihole -t running while I made a request to one of my local domains. I noticed that the DNS A query resolved correctly, but the AAAA query got sent up to upstream DNS, which produced an NXDOMAIN response. The browser, prioritizing IPv6, decided it couldn't resolve the domain.

As a first stab at solving the problem, I decided to try to disable IPv6, so I disabled the upstream IPv6 DNS servers. And that's where the problem suddenly got a whole lot worse. Suddenly nothing would resolve. So I rebooted my Raspberry Pi 3B+, the host machine.

The Situation:

Pi-hole no longer issues IPv4 addresses. Since I disabled IPv6 on my desktop, I'm unable to connect to anything unless I manually configure my IPv4 settings. On my phone, I have IPv6, but since Android doesn't allow manual configuration, there's no way to access websites that don't have IPv6 available. In addition, Pi-hole normally doesn't resolve queries anymore, although sometimes it does. I haven't really tried to troubleshoot this yet, so I can't make any definitive statements about DNS resolution. I'm currently using 1.1.1.1 directly on this machine, though, so I can reliably look for answers.

The problem might have happened earlier than I thought it did, because a) I didn't necessarily need DHCP all the time and b) if I happened to only be using IPv6-enabled resources, I might not have noticed that I didn't actually have an IPv4 address until I disabled IPv6.

As it is statically connected, I've had no connectivity problems on my Raspberry Pi.

I have no idea how this set of problems could have developed, seemingly on their own.

Debug Token:

https://tricorder.pi-hole.net/ye4emf9nzb

Hi
It looks like you have configured your pi-hole so wrong, that it will be difficult to correct this.
I know this, I have searched for hours to resolve similar problems. :wink:
Now, I don't waste time.

Uninstall the pi-hole with
sudo pihole uninstall
and re-install it with
curl -sSL https://install.pi-hole.net | bash

BTW it is possible in Android to change manuall IP and DNS, look on How to make Android use the DNS server of your choice

Best regards
Christopher

OK, I've reinstalled. My new config is here: https://tricorder.pi-hole.net/uif31jv9j6

Now my issue is that my local names don't seem to be working right. For example, if I try to connect to a local network name by its configured name, the Pi-hole logs show this:

23:16:30 dnsmasq[10351]: query[A] pi-dns.mss from 192.168.1.100
23:16:30 dnsmasq[10351]: /etc/pihole/lan.list pi-dns.mss is 192.168.1.254
23:16:30 dnsmasq[10351]: query[AAAA] pi-dns.mss from 192.168.1.100
23:16:30 dnsmasq[10351]: forwarded pi-dns.mss to 1.0.0.1
23:16:30 dnsmasq[10351]: reply pi-dns.mss is NODATA-IPv6

It resolves correctly for IPv4 but not IPv6. Yet my devices are unable to connect until I give them the IP address to connect to.

I had sometimes also problems resolving in my network, but not the same as you.
What helped was:

  • Give to all devices fixed IP-Adresses (IPV4) and disable all DHCP-servers.

Or when that wasn't possible:

  • Disable the DHCP on the router and enable the DHCP from the pi-hole.

Perhaps this can help you too.

Best regards
Christopher

I've done that already, but to no avail. However, the nature of the problem seems to be different now, so this thread is obsolete. For better or worse, I'm now experiencing consistent failure, which I'll address in a different thread.

Your log entries show that IPv4 and IPv6 address resolution is working and delivering consistent, plausible results for your setup.

For IPv4, pi-dns.mss is successfully resolved using a local file lan.list. Most likely, you have created this file yourself, associating IPv4 addresses with hostnames therein.

For IPv6, the request is forwarded to your upstream DNS server.
As external DNS servers are always completely unaware of your local internal hostnames, they will likely report it as unknown (as it happened in your case), or they may report back a rather longish generic hostname derived from a device's IPv6 address like ip26006258bf44a900302f6e5410f35eaa.isp-ip.com (as it sometimes happens when using your ISP provided DNS servers).
Without further measures, you will thus never see a network locally assigned hostname for an IPv6 address unless your Pi-hole's upstream DNS server is your local router (or some other DNS capable machine on your local network).

Some possible measures include:

edit your personally created `lan.list`

You could add your local IPv6 addresses to your lan.list, just like you did with your IPv4 addresses.
This will work smoothly with link local addresses (starting with fe80:) and local ULA addresses (starting with fd<hex><hex>, e.g. fd00:), as these are fairly static.

However, your global IPv6 addresses will dynamically change over time, so it wouldn't be advisable to put them into a static file. You would quickly get tired of updating your lan.list everytime your ISP assigned you with a new global prefix or your device issued a new privacy extension address.


use your router as DHCP server

If your router associates hostnames by MAC rather than IP address, your best option might be to keep running your router as DHCP server (and switch off Pi-hole's DHCP function altogether).


try using Pi-hole for DHCP and your router for DHCPv6 respectively

You could also try a mixed setup (e.g. Pi-hole for DHCP and your router for DHCPv6) with or without conditional forwarding, but whether this actually works will depend (among others) on your router's model and your willingness to follow a trial and error approach.


This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.