If reconnecting to the network (or dhcp restart) wipes out your DNS settings from resolv.conf then, here is a way to retain your DNS server entries in resolv.conf
sudo vim /etc/NetworkManager/system-connections/Auto\ eth0
# below [ipv4]
dns=x.x.x.x;y.y.y.y;...;
Add the DNS server entries below ipv4 block. The Auto eth0 interface can vary based on your local network settings.
No comments:
Post a Comment