Saturday, March 24, 2012

"Device eth0 does not seem to be present" on cloned CentOS VM

After cloning the a CentOS 6 Virtual Machine from a VMware VM Template. On powering, I encountered the error "Device eth0 does not seem to be present".

Basically, in a nutshell, the OS remembers the old NIC of the template and new NIC provided after the clone are assigns as though they were new NICs. To solve the problem, remove the "SUBSYSTEM" entry that contains the old entry and change the eth1 to eth0 accordingly.

# vim /etc/udev/rules.d/70-persistent-net.rules

# PCI device 0x15ad:0x07b0 (vmxnet3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", 
ATTR{address}=="00:50:56:ae:00:1a", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x15ad:0x07b0 (vmxnet3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", 
ATTR{address}=="00:50:56:ae:00:1b", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

# PCI device 0x15ad:0x07b0 (vmxnet3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", 
ATTR{address}=="00:50:56:ae:00:1b", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

Remember to modify the /etc/sysconfig/network-scripts/ifcfg-eth0 to reflect the correct changes.

Once you are done, reload the udev configuration. See Updating the udev configuration on CentOS

There is a very good and complete information written on this whole issue.
Cloned Red Hat/CentOS/Scientific Linux Virtual Machines and “Device eth0 does not seem to be present” Message

1 comment:

Unknown said...

If you're dealing with this, you may find this interesting reading also: http://comments.gmane.org/gmane.linux.hotplug.devel/16483