After linux modify the DNS, restart

After linux modify the DNS, restart

 

[root@test logs]# vi  /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
TYPE=Ethernet
UUID=25f9c322-4990-4b46-bb4c-00f15fc82502
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
HWADDR=00:50:56:94:5F:3F
IPADDR=172.16.10.28
PREFIX=24
GATEWAY=172.16.10.1
DNS1=114.114.114.114
DEFROUTE = yes
IPV4_FAILURE_FATAL=yes
IPV6INIT=no
NAME="System eth0"
-- restart the network card
service network restart

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326462186&siteId=291194637