this post was submitted on 12 Mar 2025
44 points (97.8% liked)

Selfhosted

44364 readers
1314 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 2 years ago
MODERATORS
 

Currently have nice long docker compose file that hosts my PiHole V6 container (along with a bunch of other containers) however, reason i ask this question is because whenever I go to pull an updated image and recreate the container I experience about 20 minutes of no DNS resolution which to my knowledge is due to the NTP clock being out of sync.

What’s the best way to host a DNS sinkhole/resolver that can mitigate this issue?

Was thinking of utilizing Proxmox & LXC but I suspect I’ll get the same experience.


~~Update: Turns out PiHole doesn’t support two instances, I got both of them on separate devices also set the 2nd DNS server in my routers WAN & LAN DNS settings which did in fact split DNS between both instances however, I lost access to my routers web-ui, my Traefik instance & reverse proxies died and I lost all internet access.~~

~~So, don’t do what I did.~~

Update 2: So everything I said in my first update let’s disregard that, turns out I had my router forcing all DNS to PiHole server 1 which caused my issues mentioned above.

Two servers appears to work!

you are viewing a single comment's thread
view the rest of the comments
[–] Morphit@feddit.uk 1 points 2 days ago (1 children)

Not that it particularly matters for just queries. The problem is that DHCP can only be enabled on one host. If that one fails then devices can't get on to the network themselves. I'd like to know a good way to have a failover DHCP server - my janky cronjob isn't great.

[–] DarkDarkHouse@lemmy.sdf.org 2 points 2 days ago (1 children)

You can just run two DHCP servers. Give them non-overlapping ranges or give them the same MAC to IP mapping.

[–] Morphit@feddit.uk 2 points 2 days ago (1 children)

How do the DNS servers resolve local hostnames then? The pihole DHCP integration adds local hostnames to DNS when they are assigned an address. If there's two DHCP servers handing out leases, presumable only one would be accepted, how then would the DNS servers sync those names?

I think I had my secondary pihole resolve local names from the primary, and leases were copied over on a cronjob in case the secondary DHCP server had to be enabled.

[–] DarkDarkHouse@lemmy.sdf.org 2 points 2 days ago* (last edited 2 days ago)

Use the second option of a static MAC to IP map and add the relevant records to each pihole’s local DNS.