The cloned virtual machine cannot connect to the Internet

Exception information:

The cloned virtual machine cannot be connected to the Internet
Error: No suitable device found: no device found for connection "System eth0"

Abnormal:

Cloning a virtual machine causes the UUID, MAC address and IP address of the two virtual machines to be the same, so the cloned machine cannot access the Internet.

Solution:

After reading some blog solutions, I feel a bit cumbersome. The following is the method I simplified and verified by myself:

1. Turn off the virtual machine, right click on the virtual machine ===>Settings ===>Click on Network Adapters ===>Advanced ===>Generate

Take note of the current MAC address.

2 、 vi /etc/udev/rules.d/70-persistent-net.rules

This file may have multiple configurations, delete other configurations,
leave only the configuration that is consistent with the MAC recorded in the first step, and modify: NAME="eth0"

3. vi /etc/sysconfig/network-scripts/ifcfg-eth0
Change the value of HWADDR to the recorded MAC.
It is recommended to change the ip together to avoid conflicts when two virtual machines are started at the same time.

4、reboot

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324656433&siteId=291194637