1、禁用并停止systemd-resolved的服务:
sudo systemctl disable systemd-resolved.service
sudo systemctl stop systemd-resolved
2、在/etc/NetworkManager/NetworkManager.conf文件的[main]中添加下面一行:
dns=default
3、删除链接:/etc/resolv.conf
rm /etc/resolv.conf
4、重启network-manager
sudo service network-manager restart