How to make resolvconf append nameservers to the list instead of prepending them?

6,453

Solution 1

Resolvconf prioritizes nameserver addresses according to interface type. The priority can be changed by updating either the /etc/interface-order file or /etc/resolvconf.conf. For example, to make sure nameservers for eno1 have a higher priority, add this line to /etc/resolvconf.conf:

interface_order="lo* eno*"

Solution 2

You can use the resolv.conf.head and resolv.conf.tail files to add lines before and after the content generated by resolvconf

Solution 3

use name_servers_append instead of name_servers

Share:
6,453

Related videos on Youtube

Eugene Yarmash
Author by

Eugene Yarmash

Updated on September 18, 2022

Comments

  • Eugene Yarmash
    Eugene Yarmash over 1 year

    I'm trying to configure OpenVPN to update DNS-servers as described here. That seems to work, but resolvconf prepends nameservers (and also search domains) to the list of existing nameservers. How can I make it append stuff to the end (i.e. give lower priority to these settings)?

    • Admin
      Admin over 9 years
      Word of caution: the last search domain setting is the only one that's used. Therefore it has the highest priority.