Chapter 10. Using prefixdevname for naming of Ethernet network interfaces
This documentation describes how to set the prefixes for consistent naming ot Ethernet network interfaces in case that you do not want to use the default naming scheme of such interfaces.
However, Red Hat recommends to use the default naming scheme, which is the same as in Red Hat Enterprise Linux 7.
For more details about this scheme, see Consistent Network Device Naming.
10.1. Introduction to prefixdevname
prefixdevname tool is a udev helper utility that enables you to define your own prefix used for naming of the Ethernet network interfaces.
10.2. Setting prefixdevname
The setting of the prefix with
prefixdevname is done during system installation.
To set and activate the required prefix for your Ethernet network interfaces, use the following procedure.
Add the following string on the kernel command line:
Red Hat does not support the use of
prefixdevname on already deployed systems.
After the prefix was once set, and the operating system was rebooted, the prefix is effective every time when a new network interface appears. The new device is assigned a name in the form of
<PREFIX><INDEX>. For example, if your selected prefix is
net, and the interfaces with
net1 prefixes already exist on the system, the new interface is named
prefixdevname utility then generates the new
.link file in the
/etc/systemd/network directory that applies the name to the interface with the MAC address that just appeared. The configuration is persistent across reboots.
10.3. Limitations of prefixdevname
There are certain limitations for prefixes of Ethernet network interfaces.
The prefix that you choose must meet the following requirements:
- Be ASCII string
- Be alphanumeric string
- Be shorter than 16 characters
The prefix cannot conflict with any other well-known prefix used for network interface naming on Linux. Specifically, you cannot use these prefixes: