Predictable Network Interface Names

weerok

Active Member
Jun 2, 2016
10
0
41
54
Hello,

I'm new to PVE, so I may don't know something.

In our installation, we have 2 HP servers with 3 modules of NICs on each:
- 2 NICs onboard
- 3 NICs on 1 PCI-X slot,
- 2 NICs on 1 PCI-E slot.

After first test install, problem arrised with interfaces name inconsistence.
Two exact same servers has diff interface naming, which is very inconvenient and inacceptable in production.

So my question, why PVE doesnt implemented this from the installation ?
https://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames/

My problem was solved after manual editing of grub's cfg (kernel boot behavior), but I lost many hours and was quite surprised.
/etc/default/grub
GRUB_CMDLINE_LINUX="biosdevname=1 net.ifnames=1"
cp /boot/grub/grub.cfg /boot/grub/grub.cfg-orig
grub-mkconfig -o /boot/grub/grub.cfg
# reboot

The result:
root@~# ip -br link show up
lo UNKNOWN 00:00:00:0
ens4f0 UP 00:26:55:e
enp67s4f0 UP 00:18:71:4
enp65s1 UP 00:18:71:4
enp65s2 UP 1c:c1:de:d
enp67s6f1 UP 1c:c1:de:d
 
I'm unfamiliar with those special drivers which name their interfaces like this, but could you please provide the contents of the file

Code:
/etc/udev/rules.d/70-persistent-net.rules
 
There is no such file, and there is no need in it (only if you want to change in your way).
Kernel will supply name from PCI buses

# cat /etc/udev/rules.d/70-persistent-net.rules
cat: /etc/udev/rules.d/70-persistent-net.rules: No such file or directory
#


# udevadm info -e | grep -A 9 ^P.*eth1
P: /devices/pci0000:40/0000:40:11.0/0000:42:02.0/0000:43:04.0/net/eth1
E: COMMENT=PCI device 0x8086:0x1079 (e1000)
E: DEVPATH=/devices/pci0000:40/0000:40:11.0/0000:42:02.0/0000:43:04.0/net/eth1
E: ID_BUS=pci
E: ID_MODEL_FROM_DATABASE=82546GB Gigabit Ethernet Controller
E: ID_MODEL_ID=0x1079
E: ID_NET_DRIVER=e1000
E: ID_NET_NAME_MAC=enx0018714e3fac
E: ID_NET_NAME_PATH=enp67s4f0
E: ID_OUI_FROM_DATABASE=Hewlett-Packard Company

# lspci -s 42:02
42:02.0 PCI bridge: IBM PCI-X to PCI-X Bridge (rev 03)

I think this behavior SHOULD BE enabled by default.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!