"No such device eth0" error in Ubuntu After cloning Vmware

Source: Internet
Author: User

Ubuntu "No such device eth0" error after cloning Vmware
Environment: VMWare 6.5, UBUNTU 8.10 Server

After creating a VMware Virtual Machine for Ubuntu locally, copy, create a new clone image, start, the NIC is invalid, and an error "eth0: Error while getting interface flags: no such device" is displayed ".

Cause

The MAC address of the NIC of the newly cloned virtual machine image has been changed. Open the. vmx file of the VM. The ethernet0.generatedaddress entry records the MAC address of the VM.

View All adapter Information

Ifconfig-A found that in addition to the original eth0, Ubuntu has named the new Nic eth1.
Ubuntu saves the nic mac address and device name configuration file in

The network configuration of the/etc/udev/rules. d/70-persistent-net.rules Nic is saved in

/Etc/Network/interfaces this configuration file only contains the original eth0 configuration information.

 
Solution 1
Move/Delete the Rules file. (Not verified)
After the restart, UBUNTU will create a new rules file.
Identify the new Nic as eth0 and use the network configuration of the original eth0.
If the network configuration is to automatically obtain the IP address, no additional modifications are required.

Sudo mV/etc/udev/rules. d/70-persistent-net.rules
/Etc/udev/rules. d/70-persistent-net.rules.old solution 2

Modify the Rules file. (Not verified)

The original content of sudo Pico/etc/udev/rules. d/70-persistent-net.rules is as follows:

# PCI device 0x1022: 0x2000 (pcnet32)
Subsystem = "Net", Action = "add", drivers = "? *",
ATTR {address }= "00: 0C: 29: 50: XX", ATTR {type }= "1", name = "eth0"

# PCI device 0x1022: 0x2000 (pcnet32)
Subsystem = "Net", Action = "add", drivers = "? *",
ATTR {address} = "00: 0C: 29: 36: XX", ATTR {type} = "1", name = "eth1" delete eth1 configuration, replace the MAC address of eth0 with the MAC address of eth1.

# PCI device 0x1022: 0x2000 (pcnet32)
Subsystem = "Net", Action = "add", drivers = "? *",
ATTR {address} = "00: 0C: 29: 36: XX", ATTR {type} = "1 ", after name = "eth0" is restarted, UBUNTU identifies the new Nic as eth0, which follows the network configuration of the original eth0.
If the network configuration is to automatically obtain the IP address, no additional modifications are required.

Solution 3

Modify the interfaces file. (Verified)

Sudo Pico/etc/Network/interfaces replace all eth0 with eth1.
If it is a static address, modify the corresponding settings at the same time.

Source: http://humblepg.com/chs/2008/11/ubuntu-no-such-device-eth0-after-vmware-cloning.html

 

This article from the csdn blog, reproduced please indicate the source: http://blog.csdn.net/dctfjy/archive/2009/06/01/4233284.aspx

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.