I created a VMware Workstation VM with OpenSUSE 11.2. When I copy the VM to a new location the network configuration disappears. If I go into the networking control panel and save, the interface names are changed. Originally had 2 nics as “eth0” and “eth1”, copy the vm, configure network and the interfaces are now “eth2” and “eth3”. How do I get back to my original configuration?
Go into YaST and rename the interfaces from the Networking configuration.
Alternatively edit /etc/udev/rules.d/70-persistent-net.rules and delete the entries for eth0 and eth1 and change eth2 and eth3 to 0 and 1 respectively.
Another alternative, remove that file as root, unload all driver modules for your NICs and run “udevadm trigger” (again as root) or reboot the VM.
AFAIK, even with editing you will not get passed reloading the modules to update the device names.
The fact that they are running as eth2 and eth3 means that the modules are loaded already. So it’s just cosmetic that the names are not what you like, there is no effect on the operation of the OS, unless you had some firewall rules or DHCP server specifying particular interfaces. After editing the next reboot will assign “nice” names to the interfaces.
This is not just cosmetic because the NetApp ONTap Simulator has NICs that are mapped to these devices. When the names change the mappings are no longer valid which requires reconfiguring the ONTap Simulator. That is extremely painful when delivering a demonstration environment to individuals who are not NAS savvy. (I just realized I didn’t provide the details as to what is runnig inside the VM.)
After doing some testing, what I found to work was to tell VMWare Workstation that I “Moved” the VM rather than copying it. By doing this the Network interfaces were not modified at all and distributing the VMs to a broader audience allows the solution to work!
The udev rules are keyed to the MAC address of the "NIC"s so keeping them the same, which I assume is what move does, will retain the same interface names.
I hope your simulators don’t talk to each other on the LAN, otherwise you could have a spot of trouble as they will all have the same MAC address.
You may want to do a clone instead, this way you will get a new mac and uuid.