Because the cloned virtual machine only modifies the virtual machine name and other information, and does not modify any information in the virtual hard disk, the MAC address of the cloned Nic does not match the mac address recorded in the operating system, as a result, eth0 cannot be started. The operating system records the addition of a new Nic. The new nic name is eth1, and the mac address is the new mac address assigned by vmware. Solution: 1. modify/etc/udev/rules.
Because the cloned virtual machine only modifies the virtual machine name and other information, and does not modify any information in the virtual hard disk, the MAC address of the cloned Nic does not match the mac address recorded in the operating system, as a result, eth0 cannot be started. The operating system records the addition of a new Nic. The new nic name is eth1, and the mac address is the new mac address assigned by vmware.
Solution:
1. modify the/etc/udev/rules. d/70-persistent-net.rules file.
Delete eth0 information. Modify the name of the second eth1 Nic to eth0.
# Vim/etc/udev/rules. d/70-persistent-net.rules
2, modify/etc/sysconfig/network-scripts/ifcfg-eth0 configuration file, MAC address corresponds to the above
# Vim/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE = eth0 HWADDR = 00: 0c: 29: ed: 52: a3 // The MAC corresponds to the preceding NM_CONTROLLED = yes ONBOOT = yes TYPE = Ethernet BOOTPROTO = none // change to static IP address acquisition IPV6INIT = no USERCTL = no IPADDR = 192.168.212.100 // nic ip address NETMASK = 255.255.255.0 // subnet mask GATEWAY = 192.168.212.1 // GATEWAY DNS1 = 202.106.0.20 // DNS resolution address |
3. restart the system to take effect.
4. View IP configuration information
# Ifconfig eth0
Eth0 Linkencap: Ethernet HWaddr00: 0C: 29: ED: 52: A3 Inet addr: 192.168.212.100 Bcast: 192.168.212.255 Mask: 255.255.255.0 Inet6addr: fe80: 20c: 29ff: feed: 52a3/64 Scope: Link |