Retrieve the network card eth0, every time the virtual machine is cloned, the network card mac address is updated, and centos automatically adds an eth network card
rm -f /etc/udev/rules.d/70-persistent-net.rules
reboot
Close the service NetworkManager
chkconfig NetworkManager off
service NetworkManager stop
vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0 #network card device name
ONBOOT=yes #whether to activate at startup yes|no
BOOTPROTO=static #protocol type dhcp bootp none
IPADDR=192.168.134.136 #network IP address
NETMASK =255.255.255.0 #Network subnet address
GATEWAY= #Gateway address
BROADCAST=192.168.134.255 #Broadcast address
TYPE=Ethernet #Network card type is Ethernet
Start the network service
chkconfig network on
service network start
https://jingyan.baidu.com/article/335530da93ac2c19cb41c3b3.html