Multiple upstream DNS servers

When multiple upstream DNS servers are used Pi-hole will query them all.

Is there an option to change this behavior - for example query the second upstream DNS server only if the first is not responding; query the third if the second is not respondin... ?

Add the strict-order option to a new dnsmasq config file:
http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html

1 Like

Thank you!
Exactly what i wanted.

I'm new to Pi-hole. What I did was create a file in /etc/dnsmasq.d called 02-dnsmasq.conf

I added one line:
strict-order

and restarted Pi-hole. Is this what I would need to do?

That's exactly what I did two days ago. It seems to work most of the times. However, your preferred server seems to be listed as #2 in the pihole Settings (upstream Servers) (see here.
I then can see in the dashboard that arround 5 % of the queries use the "fallback" server specified as #1 Server.

However, I am not entirely sure if the "strict-order" options works like I would expect it do to do. I would expect it to try resolve the query first with the main upstream server. If this doesn't work, it automatically chooses the fallback upstream server. Nevertheless, sometimes the DNS seems to be not resolved at all and a manual refresh in the browser is required.

Thanks for the tip. I'll take a look at that.

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