Make name server address permanent in /etc/resolv.conf

Posted on January 9, 2021 at 1:35 pm

How to make name server address permanent in /etc/resolv.conf?

If you do not have the package resolvconf installed, then it is easy:

after changing it the way you like, issue the command:

sudo chattr +i /etc/resolv.conf

The command changes the file attributes, making it immutable (the +i option).

To view the attribute status of the file type:

lsattr /etc/resolv.conf

To remove the immutable status just use -i:

chattr -i /etc/resolv.conf


Receive updates via email

Other Posts

Updated Posts