Interface names – udev persistent rules

At our DC we have Cisco UCS blades managed using configuration manager with host OS as Ubuntu. We have created different profiles with interfaces + vlan configurations for different zones ( DMZ, INT, EXT etc ). Everything was OK while running OS version precise (12.04) but once we upgrade host OS to trusty ( 14.04) interfaces are no longer coming up.

The simple reason is interfaces on the host after the upgrade named as em0 and em1 but UCS expecting eth0 and eth1.

To resolve:

Add “biosdevname=0” to the kernel boot arguments in /etc/grub.conf

“udev” is also creates persistent rules “/etc/udev/rules.d/70-persistent-net-rules” for the first time to make sure of follow those rules and keep the interfaces naming as present in the file at each boot to make it consistent so we need to delete this file. So for every time boots udev process reads the rules present in /etc/udev/rules.d/ and action accordingly.

Update /etc/network/interfaces with the ones you want to create.

Reboot the system.

Yesterday I’ve cloned one of the Virtual Machine ( Running RHEL 6 ) with two NICs in VSphere. After cloning is done I’ve removed the two NIC’s and added a new NIC then powered on. System is not connecting to network as the interface not coming up.

ifconfig -a showed that interface is recognized as eth2.

Ans: Removed the persistent rules file and reload the udev rule.

Reference: https://community.spiceworks.com/how_to/67673-device-eth0-does-not-seem-to-be-present-after-moving-or-cloning-a-rhel-centos-6-3-virtual-machine-in-vsphere

Advertisements