-
Notifications
You must be signed in to change notification settings - Fork 62
DNS Providers
trinib edited this page Nov 10, 2022
·
9 revisions
DNS provider list : adguard-dns.io/kb/general/dns-providers
Open sudo nano /etc/default/
cloudflared
and uncomment your preferred DNS server(remove # in front of lines).
Or change it from command line:
(IPv4&IPv6 will be activated)
Quad9
sudo sed -i '2s/'#'/''/g' /etc/default/cloudflared
OpenDNS
sudo sed -i '4s/'#'/''/g' /etc/default/cloudflared
Cloudflare
sudo sed -i '6s/'#'/''/g' /etc/default/cloudflared
sudo sed -i '8s/'#'/''/g' /etc/default/cloudflared
AdGuard
sudo sed -i '10s/'#'/''/g' /etc/default/cloudflared
Open sudo nano /etc/unbound/unbound.conf.d/
unbound.conf
and uncomment your preferred DNS server(remove # in front of lines).
Or change it from command line:
(IPv4&IPv6 will be activated)
Quad9
awk '{sub(/[#]forward-addr: 9.9.9.9/,"forward-addr: 9.9.9.9") || sub(/[#]forward-addr: 149.112.112.112[@]853[#]dns.quad9.net/,"forward-addr: 149.112.112.112@853#dns.quad9.net") || sub(/[#]forward-addr: 2620:fe::10/,"forward-addr: 2620:fe::10") || sub(/[#]forward-addr: 2620:fe::fe:10/,"forward-addr: 2620:fe::fe:10")}1' /etc/unbound/unbound.conf.d/unbound.conf > unbound.conf && sudo mv unbound.conf /etc/unbound/unbound.conf.d/
OpenDNS
awk '{sub(/[#]forward-addr: 208.67.222.222/,"forward-addr: 208.67.222.222") || sub(/[#]forward-addr: 208.67.220.220/,"forward-addr: 208.67.220.220") || sub(/[#]forward-addr: 2620:119:35::35/,"forward-addr: 2620:119:35::35") || sub(/[#]forward-addr: 2620:119:53::53/,"forward-addr: 2620:119:53::53")}1' /etc/unbound/unbound.conf.d/unbound.conf > unbound.conf && sudo mv unbound.conf /etc/unbound/unbound.conf.d/
Cloudflare
awk '{sub(/[#]forward-addr: 1.1.1.1/,"forward-addr: 1.1.1.1") || sub(/[#]forward-addr: 1.0.0.1/,"forward-addr: 1.0.0.1") || sub(/[#]forward-addr: 2606:4700:4700::1111/,"forward-addr: 2606:4700:4700::1111") || sub(/[#]forward-addr: 2606:4700:4700::1001/,"forward-addr: 2606:4700:4700::1001")}1' /etc/unbound/unbound.conf.d/unbound.conf > unbound.conf && sudo mv unbound.conf /etc/unbound/unbound.conf.d/
awk '{sub(/[#]forward-addr: 8.8.8.8/,"forward-addr: 8.8.8.8") || sub(/[#]forward-addr: 8.8.4.4/,"forward-addr: 8.8.4.4") || sub(/[#]forward-addr: 2001:4860:4860::8888/,"forward-addr: 2001:4860:4860::8888") || sub(/[#]forward-addr: 2001:4860:4860::8844/,"forward-addr: 2001:4860:4860::8844")}1' /etc/unbound/unbound.conf.d/unbound.conf > unbound.conf && sudo mv unbound.conf /etc/unbound/unbound.conf.d/
AdGuard
awk '{sub(/[#]forward-addr: 94.140.14.14/,"forward-addr: 94.140.14.14") || sub(/[#]forward-addr: 94.140.15.15/,"forward-addr: 94.140.15.15") || sub(/[#]forward-addr: 2a10:50c0::ad1:ff/,"forward-addr: 2a10:50c0::ad1:ff") || sub(/[#]forward-addr: 2a10:50c0::ad2:ff/,"forward-addr: 2a10:50c0::ad2:ff")}1' /etc/unbound/unbound.conf.d/unbound.conf > unbound.conf && sudo mv unbound.conf /etc/unbound/unbound.conf.d/
Open sudo nano /etc/stubby/
stubby.yml
and uncomment your preferred DNS server(remove # in front of lines).
Or change it from command line:
(IPv4&IPv6 will be activated)
Quad9
sudo sed -i '148,151s/'#'/''/g' /etc/stubby/stubby.yml && sudo sed -i '256,259s/'#'/''/g' /etc/stubby/stubby.yml
Cloudflare
sudo sed -i '138,141s/'#'/''/g' /etc/stubby/stubby.yml && sudo sed -i '256,259s/'#'/''/g' /etc/stubby/stubby.yml
Need to set idle_timeout to 9000
sudo sed -i '36s/'1000'/'9000'/g' /etc/stubby/stubby.yml
sudo sed -i '157,160s/'#'/''/g' /etc/stubby/stubby.yml || sudo sed -i '275,278s/'#'/''/g' /etc/stubby/stubby.yml
Adguard
sudo sed -i '162,165s/'#'/''/g' /etc/stubby/stubby.yml && sudo sed -i '280,283s/'#'/''/g' /etc/stubby/stubby.yml