VMware

This Question is Possibly Answered

1 "correct" answer available (10 pts) 2 "helpful" answers available (6 pts)
1 2 Previous Next 24 Replies Last post: Jun 7, 2009 10:34 PM by ronalddevos   Go to original post

Re: lost eth0 when using a copied ubuntu-server vm

15. Apr 11, 2007 11:39 AM in response to: einjen
Click to view metrolinux's profile Lurker 1 posts since
Apr 11, 2007
For Ubuntu (6.06LTS) it's:

sudo cp /etc/udev/rules.d/25-iftab.rules /etc/udev/rules.d/25-iftab.old

sudo rm /etc/udev/rules.d/25-iftab.rules


Did the same trick. Thanks for helping point me in the right direction, Rainer !
Click to view axl's profile Lurker 1 posts since
Sep 14, 2006
If you delete this file, it will be rebuilt during
the next system startup and your problem should go
away.

rainer,

thank you very much; i ran into this problem several times (newer debian sarge and etch) and this solution works pretty well!

cu
axl

Re: lost eth0 when using a copied ubuntu-server vm

17. Jun 19, 2007 3:59 PM in response to: adamsi
Click to view cwheeler33's profile Lurker 1 posts since
Jun 19, 2007
I had the same problem with Gentoo
The Debian solution was very close to what I needed. Here is what I had to do.

Edited the following file
#vi /etc/udev/rules.d/70-persistent-net.rules
changed the MAC address to that listed in the .vmx file.

If you delete the file instead, it will recreate the file and add the new MAC address but will assign it to eth1 after the reboot. You will then need to go into the file and change it to eth0 and then reboot again.

Re: lost eth0 when using a copied ubuntu-server vm

18. Aug 3, 2007 3:22 AM in response to: adamsi
Click to view mieslep's profile Lurker 2 posts since
Dec 27, 2006
Just had a similar problem with RedHat Enterprise Linux 4 (RHEL4). These files don't exist, but I was able to determine that "/etc/init.d/network restart" solved my problem. My recollection from Ubuntu is that the method should work there too.

Re: lost eth0 when using a copied ubuntu-server vm

19. Aug 9, 2007 9:15 AM in response to: mieslep
Click to view gjstory's profile Lurker 1 posts since
Aug 9, 2007
I ran into this today as well. ifconfig -a did not show eth0. I did some things based on earlier posts before I got to the removal suggestion of the /etc/udev/rules.d/25-iftab.rules file. I originally made changes to iftab and interfaces to reflect eth1 instead of eth0. That did work like a charm until I ran apt-get upgrade. I lost eth1. ifconfig -a showed eth0 had returned. I restored the backup of iftab and interfaces so eth0 was back. I also rename /etc/udev/rules.d/25-iftab.rules to /etc/udev/rules.d/25-iftab.rules.old. A reboot later and all is well. Thanks to everyone for their suggestions.

Re: lost eth0 when using a copied ubuntu-server vm

20. Aug 23, 2007 3:12 AM in response to: adamsi
Click to view burke3gd's profile Lurker 1 posts since
Aug 23, 2007
I ran into this problem on Debian Etch. If the vm only has one interface you can disable udev's interface cache by renaming the following rules:

/etc/udev/rules.d/z25_persistent-net.rules --> /etc/udev/rules.d/z25_persistent-net.rules.disabled
/etc/udev/rules.d/z45_persistent-net-generator.rules --> /etc/udev/rules.d/z45_persistent-net-generator.rules.disabled

The upside of this solution is that, as long as the vm only has one interface, it will always be named eth0, even if the mac address changes.

The downside is that you will probably have to use manually configured mac addresses if you want any reliability with multiple interfaces. But this is true in the case of the other suggested remedies also.

Re: lost eth0 when using a copied ubuntu-server vm

21. Aug 6, 2008 11:54 AM in response to: burke3gd
Click to view Lance Rushing's profile Lurker 4 posts since
Aug 6, 2008

For Ubuntu 8.04 I got eth0 work by doing the following:

sudo rm /etc/udev/rules.d/70-persistent-net.rules
sudo reboot
Also I went back and removed the 70-persistent-net.rules from my gold source used for cloning.
Click to view harunsahiner's profile Novice 20 posts since
Jun 2, 2008
hi Lance;


Your solution also applies to ubuntu 8.10 server edition .


thank you.

Click to view oreostogo's profile Lurker 1 posts since
Jun 4, 2009
Thanks lilboy716, 2 years later and this still seems to be a problem when copying a VMWare.

This is what I had to do on Ubuntu:
sudo rm /etc/udev/rules.d/70-persistent-net.rules

Thanks!
Click to view ronalddevos's profile Lurker 1 posts since
Jun 7, 2009

Same problem after a conversion of an Ubuntu server.

Your script DID fix it! Thanks!

VMware Developer

SDKs, APIs, Videos, Learn and much more in the Developer community.

Learn More

Developer Sample Code

Increase your developer productivity with VMware API sample code.

Learn More

VMworld Sessions & Labs

Online access to the latest VMworld Sessions & Labs and online services.

Learn more

Purchase PSO Credits Online

Purchase credits to redeem training and consulting services online.

Buy Now

Community Hardware Software

View reported configurations or report your own.

Learn More

VMware vSphere

Come witness the next giant leap in virtualization.

Register Today

Communities