SUSE-Enceladus / azure-li-services

Azure Large Instance Services
GNU General Public License v3.0
7 stars 0 forks source link

[VLI] Predictable interface names are lost after upgrading OS #243

Closed jaiawasthi closed 4 years ago

jaiawasthi commented 4 years ago

Hi Marcus,

For All our VLI images we have persistent names enabled,

2: enP1p1s0f0: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 9000 qdisc mq master bond0 state UP group default qlen 1000 link/ether 00:e0:ed:90:c6:be brd ff:ff:ff:ff:ff:ff 3: enp7s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000 link/ether 08:00:69:17:c7:73 brd ff:ff:ff:ff:ff:ff 4: enP1p1s0f1: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 9000 qdisc mq master bond0 state UP group default qlen 1000 link/ether 00:e0:ed:90:c6:be brd ff:ff:ff:ff:ff:ff 5: enP2p1s0f0: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 9000 qdisc mq master bond1 state UP group default qlen 1000 link/ether 00:e0:ed:90:57:4d brd ff:ff:ff:ff:ff:ff 6: enP2p1s0f1: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 9000 qdisc mq master bond1 state UP group default qlen 1000

But we are seeing that on an OS upgrade all these names are getting lost and these are named as ens2370f0. This should not be the case and the interface names should always be created with the same name. I was going through some commands and we do apply iD_NET_NAME_PATH on the interfaces but where the rules are getting generated, i couldn't get that. We also have net.ifnames=1 set in the boot parameters.

azsollabdsm35:~ # udevadm test-builtin net_id /sys/class/net/enp7s0/ calling: test-builtin === trie on-disk === tool version: 228 file size: 6753794 bytes header size 80 bytes strings 1734970 bytes nodes 5018744 bytes Load module index Found container virtualization none timestamp of '/usr/lib/systemd/network' changed Configuration file /usr/lib/systemd/network/99-default.link is marked world-writable. Please remove world writability permission bits. Proceeding anyway. Parsed configuration file /usr/lib/systemd/network/99-default.link Created link configuration context. ID_NET_NAME_MAC=enx08006917c773 ID_OUI_FROM_DATABASE=SILICON GRAPHICS INC. ID_NET_NAME_PATH=enp7s0 Unload module index Unloaded link configuration context.

Will it be more feasible to just add a 70-persistent-net.rules file to the udev rules ? Should it not be automatically populated by the udev-rule generator ?