Page 1 of 1

changing DNS-servers

Posted: Wed Jul 25, 2018 12:10 pm
by bartgrefte
Somewhere in the past, I configured Raspbian to use Google's DNS servers.
Since those are quite slow when it comes to picking up DNS updates, I want to switch DNS servers.

The problem is, I can't remember where I set it to use Google's DNS servers. The only file I found with Googles DNS servers in it is the automatically generated /etc/resolv.conf, but not /etc/network/interfaces, nor /etc/dhcp/dhclient.conf contain Googles DNS servers and my router isn't sending those either.
edit: And /etc/dhcpcd.conf contains my router's IP as DNS server, not Google.

Am I missing something? :?

Re: changing DNS-servers

Posted: Wed Jul 25, 2018 1:08 pm
by SurferTim
This page might help you find your setting.
https://wiki.debian.org/NetworkConfigur ... ameservers

Re: changing DNS-servers

Posted: Wed Jul 25, 2018 1:09 pm
by topguy
*deleted*

Re: changing DNS-servers

Posted: Wed Jul 25, 2018 4:12 pm
by epoch1970
Look in /etc/rc.local or for some custom script you might have added somewhere.
Or maybe you followed one of the brightest advices of all times and made /etc/resolv.conf immutable. lsattr and chattr would be of help in this case.

Re: changing DNS-servers

Posted: Thu Jul 26, 2018 11:01 am
by bartgrefte
SurferTim wrote:
Wed Jul 25, 2018 1:08 pm
This page might help you find your setting.
https://wiki.debian.org/NetworkConfigur ... ameservers
Network Manager wasn't the cause either, already checked the other files mentioned. Thanks for the reading material though ;) (That new bookmark will probably come in handy from time to time)
epoch1970 wrote:
Wed Jul 25, 2018 4:12 pm
Look in /etc/rc.local or for some custom script you might have added somewhere.
Or maybe you followed one of the brightest advices of all times and made /etc/resolv.conf immutable. lsattr and chattr would be of help in this case.
There's nothing in rc.local, as for /etc/resolv.conf:
lsattr
----i---------e---- ./resolv.conf
I think you nailed it :)

Yesterday I thought I'd found the culprit though, I thought maybe PiHole was overwriting that file and since I configured it to use Google... So I reconfigured PiHole to use OpenDNS, /etc/resolv.conf didn't change, not even after a reboot. Changing DNS-servers in PiHole did solve the problem of delayed DNS updates though, OpenDNS picks those up quite a bit faster than Google :)
(For comparison, OpenDNS needs a couple of seconds, Google about an hour or so.)