1. 修改 /etc/NetworkManager/NetworkManager.conf 文件,在main部分添加"dns=none"选项:

[main]
plugins=ifcfg-rh
dns=none

2. 修改 /etc/resolv.conf

nameserver 8.8.8.8
nameserver 8.8.4.4
3. NetworkManager重新装载上面修改的配置
systemctl restart NetworkManager.service