Configuring DNS server on router Dlink dir-820L

Expected Behaviour:

Router is not having DHCP clients use Pi-hole as the DNS server. I've been playing with the router in order to set up this up but apparently this router is no straight forward.

Actual Behaviour:

The router does not have a DNS Setting on the DHCP. I've looked on routers documentation and apparently I need to set up a virtual server and i can't find further information of how to do this. Am I doing this wrong or should I find a new method

Debug Token:

_https://tricorder.pi-hole.net/txyia2izup

Your problem seems to be related to your specific router.
As such, it'd probably be prudent to also consult your router's documentation and forums for additional advice.

I am not familiar with your router at all, so I wouldn't know whether its virtual servers would be the right way to introduce Pi-hole - but I very much doubt it.

I fear that those settings will open a port for outside access to you home network, i.e. you expose a port to be accessed from any source on the Internet.

I'd like to firmly encourage you to disable this Virtual Server setting until you found definite information on what that feature aims at (even if the port number itself would be wrong for DNS) - lest you risk running an open resolver .

If your router doesn't allow to distribute Pi-hole to each of your clients individually via DHCP, you can try to set Pi-hole as your router's upstream DNS server (losing the ability to associate Pi-hole's Query Log to individual clients), or you can try to disable DHCP on your router and enable Pi-hole as your DHCP server - see also Pi-hole's documentation for Making your network take advantage of Pi-hole.

1 Like

On "D-Link 885L" I used following setup:

Enabled DHCP on Pi-hole (setup with a fitting range/size)
Disabled DHCP on router (Settings -> Network -> Advanced settings)
Changed DNS settings on router (Settings -> Internet -> Advanced settings) :

  • Primaty: [Pi-hole IP] (in my case 192.168.0.252)
  • Secondary: 1.1.1.1 (it must contain something...)

This way You can administer virtually anything via Pi-hole just to keep it simple and easy.

Note:
You may have to force DHCP renewal on devices to adapt the new DNS settings.

1 Like

Thanks for the detailed configuration example for a similar router model.

Just an additional hint for the OP: if you use this configuration, make sure not to put your router as upstream DNS for pihole - you would create an DNS loop.

1 Like

Thanks all for your help I'll try those settings and post the results

I've tested de config and worked flawlessly, just a bit problem. It blocked my girlfriend's office laptop from all internet access, something to do with the DNS but I can't check the network settings since it's a office PC and its all protected.

Thanks for the hint but I'll be searching for a solution for that PC other time.

You could try forcing refresh of changed network settings in the work PC if You can access Command prompt (before connecting to work network):

  • Run ipconfig /release *
  • Run ipconfig /renew *

That should force refresh of network settings for home network.

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