Home>Article>Operation and Maintenance> How to modify dns in centos7
Edit the /etc/NetworkManager/NetworkManager.conf file
[root@localhost ~]# vim /etc/NetworkManager/NetworkManager.conf
Add dns=none at the end of the file
[main] #plugins=ifcfg-rh,ibft dns=none
Restart the service
[root@localhost ~]# systemctl restart NetworkManager.service
Edit the /etc/resolv.conf file
[root@localhost ~]# vim /etc/resolv.conf
Modify as follows:
# Generated by NetworkManager nameserver 114.114.114.114 nameserver 8.8.8.8
Recommended tutorial:centos tutorial
The above is the detailed content of How to modify dns in centos7. For more information, please follow other related articles on the PHP Chinese website!