After migrating the original Ubuntu virtual machine files to another machine.
Ifconfig Show only one LO network card, the Internet to find some articles, mostly modified/etc/network/interfaces
The original content is
# #######################################################
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see Interfaces (5).
# The Loopback network interface
Auto Lo
Iface Lo inet Loopback
# The Primary network interface
Auto Eth0
Iface eth0 inet DHCP
# #######################################################
Change eth0 to static IP
# #######################################################
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see Interfaces (5).
# The Loopback network interface
Auto Lo
Iface Lo inet Loopback
# The Primary network interface
Auto Eth0
Iface eth0 inet Static
Address 192.168.60.218
Gateway 192.168.60.1
Netmask 255.255.255.0
# #######################################################
Reboot after execution of Ifconfig, still only shows Lo, cannot find eth0
Inadvertently executed ifconfig-a, showing Eth1,eth2 and lo.
Then modify the/etc/network/interfaces, change the original eth0 to eth1
# #######################################################
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see Interfaces (5).
# The Loopback network interface
Auto Lo
Iface Lo inet Loopback
# The Primary network interface
Auto Eth1
Iface eth1 inet Static
Address 192.168.60.218
Gateway 192.168.60.1
Netmask 255.255.255.0
# #######################################################
After reboot, Ifconfig finally show eth1, the familiar network is back again. Here is a simple record to avoid encountering again next time.
Eth0 disappearing due to VMware virtual machine migration