Advertising Two Pi-hole DNS IP Addresses via DHCP

If you are running a single Pi-hole, but it has two IP addresses, you might want the Pi-hole’s DHCP server to advertise both addresses to clients. This can sometimes help prevent a client from using a hardcoded secondary DNS address, which would bypass the Pi-hole.

This is not something you can do from the GUI. You need to SSH to the Pi-hole and run -

sudo pihole-FTL --config misc.dnsmasq_lines '["dhcp-option=option:dns-server,192.168.1.153,192.168.1.154"]'

This change should restart the Pi-hole FTL, but you can also do it manually -

sudo systemctl restart pihole-FTL

Now, when a client is assigned an IP address by the DHCP server, it will know about both DNS addresses.

comments powered by Disqus

Related