标签:blog http ar os sp on art log bs
/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=none
BROADCAST=192.168.1.255
HWADDR=00:0c:29:17:69:2c
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPADDR=192.168.1.9
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
ONBOOT=yes
TYPE=Ethernet
重点:
IPADDR=192.168.1.9
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
除IPADDR外后两项跟宿主机一样,IPADDR的最后一位要大于0小于255,并且不于宿主机相同(如果你的局域网还有其它机子,也不要跟他们的IP冲突)
然后再编辑/etc/resolv.conf,
search localdomain
nameserver 202.101.172.35
nameserver 为dns服务器
最后重启网络服务
service network restart
ping 163.com
一切ok
转自:http://blog.csdn.net/jianglei421/article/details/6362946
标签:blog http ar os sp on art log bs
原文地址:http://www.cnblogs.com/chasewade/p/4155521.html