临时

编辑 /etc/resolv.conf

1
nameserver 114.114.114.114

永久

编辑 /etc/dhcp/dhclient.conf

1
2
//取消注释
prepend domain-name-servers 127.0.0.1;