Solve the problem that the NIC cannot be used after the complete clone of centos is created
1. log on to the cloned Virtual Machine
2. Confirm the gateway address
Command: more/etc/resolv. conf
; Generated by/sbin/dhclient-script
Search localdomain
Nameserver 192.168.246.2 # gateway address
3. modify the configuration file: 70-persistent-net.rules
Command: vi/etc/udev/rules. d/70-persistent-net.rules
Use # To comment out the eth0 Configuration
Change the last eth1 to eth0 and remember the address in ATTR {address} = "00: 0C: 29: 83: 37: 96 ".
After modification, save and release
4. Modify Nic configuration information
Command: vi/etc/sysconfig/network-scripts/ifcfg-eth0
Edit configuration file
DEVICE = eth0
HWADDR = 00: 0C: 29: 83: 37: 96 # ATTR {address }={ 00: 0C: 29: 83: 37: 96}
TYPE = Ethernet
UUID = 7b3debca-6efe-49a1-9d84-4642b8ed883e
ONBOOT = yes
NM_CONTROLLED = yes
BOOTPROTO = static
HOSTNAME = caixen2
BROADCOST = 192.168.246.255
NETWORK = 192.168.246.0
IPADDR = 192.168.246.132
NETMASK = 255.255.255.0
GATEWAY = 192.168.246.2 # nameserver 192.168.246.2
Save and exit
5. Command: reboot is restarted and configuration is complete.