机器ip -> 192.168.107.103
网关ip -> 192.168.107.1
虚拟网卡 -> eth0
vi /etc/resolv.conf
添加
nameserver 192.168.107.1
nameserver 8.8.8.8
nameserver 223.5.5.5
vi /etc/sysconfig/network-scripts/ifcfg-eth0
添加
GATEWAY=192.168.107.1
DNS1=192.168.107.1
DNS2=8.8.8.8
DNS3=223.5.5.5
设置网关
route add default gw 192.168.107.1
重启网络
service network restart
vi /etc/sysconfig/network-scripts/ifcfg-eth0
添加
ARPCHECK=no
重启网络
service network restart