实验环境,我们经常需要用vmware的克隆功能来克隆新的centos系统,虚拟新的主机。但是克隆出来的主机与源主机拥有相同的物理网卡,相同的网卡mac地址等信息,这就导致克隆出来的主机不能上网。解决办法:1.删除/etc/sysconfig/network-scripts/ifcfg-eth0 下的HWADDR和UUID信息。[root@www named]# vim /etc/sysconfig/network-scripts/ifcfg-eth0 DEVICE=eth0HWADDR=00:0c:29:e3:f4:cf        //删除此行TYPE=EthernetUUID=b8678f1c-339c-4bef-a2cd-5f0bf69448dc   //删除此行ONBOOT=yesNM_CONTROLLED=yesBOOTPROTO=noneUSERCTL=noIPV6INIT=noIPADDR=192.168.0.105NETMASK=255.255.255.0GATEWAY=192.168.0.1                                                                                                                                                                                                                                             ~                                                                                                                                   "/etc/sysconfig/network-scripts/ifcfg-eth0" 12L, 223C    1,1           All 2.清空/etc/udev/rules.d/70-persistent-net.rules 文件[root@www named]#> /etc/udev/rules.d/70-persistent-net.rules 3.更改vmware网卡模式,改为桥接3.重启系统4.执行service network restart重启网络服务5.再次更改vmware网卡模式为nat模式6.执行service network restart重启网络服务