Hello everyone,

first time ever posting on lemmy, feels good 😉

I have a question regarding DHCP in my local network.

My current setup is as follows:

  • DHCP provided by router (Fritz!Box 7490)
  • DNS provided by pi-hole hosted on a raspberry pi
  • DHCP pushes the IP of the raspberry via DHCP to all clients

My problem is: When the raspberry pi (running pi hole) is down for any reason, none of my devices has internet access anymore. This is due to the fact that the Fritz!Box router (aka DHCP server) has no option to push a secondary DNS as a fallback to its clients.

One option would be to buy another router which has the option to push a secondary DNS, which I would prefer to avoid, since otherwise I am happy with the Fritz!Box.

So I am looking for alternative configurations with my existing hardware. I could for example use pi holes DHCP. Or I could use the DHCP server package of a synology NAS which is also part of my local network. Or is there another option, maybe using some DHCP service on the raspberry pi or in a docker container or something like that? Does anyone have experience with one of these setups and can tell me if it is possible to provide the clients with two (prioritized) DNS options? What would you recommend? Thanks!

goatsarah
link
fedilink
11Y

@k86k If you set a secondary DNS server, your clients will just use it to get ads, negating the effect of your pihole.

The correct thing to do is to stop the pihole from going down. What’s making this happen? Mine only goes down for reboots and power cuts.

OP already said that their current DHCP solution (the router) can’t push multiple DNS servers. Having a good secondary can be really helpful for things like power blips, maintenance windows, and cats pulling power cables. There are a few solutions that also do ad blocking that can make good secondaries

I don’t think anyone is arguing against dual DNS servers. The distinction being made is that a second DNS server is not a fallback. Most newbies think “secondary” means it will only be used when the primary is unavailable. That’s not true. A client is just as likely to use a secondary DNS as a primary. If only one DNS uses pihole, then the secondary will serve ads because it’s just calling the upstream DNS resolver.

Personally, I accomplished what OP is talking about with two rPis. First serves DCHP from 192.168.1.10 to .100, second serves .101 to .250. I send the two piholes as primary and secondary DNS. I also use Unbound as the upstream, but that is just personal preference.

Create a post

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!

  • 1 user online
  • 136 users / day
  • 427 users / week
  • 1.16K users / month
  • 3.85K users / 6 months
  • 1 subscriber
  • 3.68K Posts
  • 74.2K Comments
  • Modlog