Sometimes resolv.conf
that is located at /etc/resolv.conf
can be a headache. One way to manage the file is by using resolvconf
package, which is I am.
The Problem
In my case, somehow resolv.conf
appending these values at the end
nameserver 127.0.0.1 search ovh.net
I have set /etc/resolvconf/resolv.conf.d/head
and /etc/resolvconf/resolv.conf.d/tail
according my like but after restarting resolvconf
, those lines keep coming back at the end of the file.
Solution
After a bit of digging, turned out I need to clear out the value inside /run/resolvconf/interface/original.resolvconf
nameserver 127.0.0.1 search ovh.net
You can just simply deleting /run/resolvconf/interface/original.resolvconf
or just delete all content inside the file, or just commenting them by putting # infront of those lines
# nameserver 127.0.0.1 # search ovh.net
Then restart resolvconf
and you are good to go.