Why RHEL7 system is failing in renaming the interfaces with error "systemd-udevd: error changing net interface name ethX to ethY: File exists" ?
Issue
- In RHEL 7 system NIC naming has been changed to
ethXstyle by addingnet.ifnames=0andbiosdevname=0to grub file. After doing that and rebooting the system when system boots up,MACaddress mapping toNICnames are aseth0 - 8c:dc:d4:b7:xx:xxandeth1 - 8c:dc:d4:33:yy:yy - Now the requiremet is NIC port whose
MACis8c:dc:d4:b7:xx:xxshould be named aseth1and the NIC port whoseMACis8c:dc:d4:33:yy:yyshould be named aseth0. - So to achieve that have tried adding
HWADDRaccordingly in the respectiveifcfg-ethNfiles and then after reboot interfaces are coming up in the same way as that as that of original mapping. - In logs can see below error at the time when
udevtried renaming the interfaces:
Apr 20 05:32:38 HOSTNAME systemd-udevd: error changing net interface name eth0 to eth1: File exists
Apr 20 05:32:38 HOSTNAME systemd-udevd: error changing net interface name eth1 to eth0: File exists
Environment
- Red Hat Enterprise Linux 7.1
- udevd
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
