I do need some clarifications for resolv.conf handling on ubuntu 18.04.02 My host is configure to use the old interfaces files. But the interface itself is configured to use dhcp auto enp2s0 iface enp2s0 inet dhcp

dns searchlist is provided via dhcp an shown inside the lease as well.

Now there seems two additonal resolv.conf beside the /etc/resolv.conf or at least link bases.

for systemd resolvconf is written to use the /var/run/systemd/resolve/resolv.conf and create a symbolic link for this file as /etc/resolv.conf

but service resolvconf status says a warning that /run/resolvconf/resolv.conf should be the linkbase for /etc/resolv.conf

and by the way my hosts are not resolved anyway....

so what should be the master file ?


In Ubuntu 18.04 and later, the usual arrangement is:

ls -al /etc/resolv.conf
/etc/resolv.conf -> ../run/systemd/resolve/stub-resolv.conf

If yours is not the same, I suggest that you do:

sudo rm -f /etc/resolv.conf
ln -s /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.