-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Interface Naming broken in 2345 Stable #36
Comments
Hello, |
When the initramfs gave a persistent name to a network interface, renaming it via Name is not working with the v238 naming scheme even if NamePolicy is unset. Switch to the newest network interface naming scheme to resolve this issue. flatcar/Flatcar#36
When the initramfs gave a persistent name to a network interface, renaming it via Name is not working with the v238 naming scheme even if NamePolicy is unset. Switch to the newest network interface naming scheme to resolve this issue. flatcar/Flatcar#36
Yeah I saw that, but masking 99-default.link didn't help. The docs also seem to indicate that if an earlier lexical file matches (i.e. 20-ens192.link), and that file DOESN'T have a NamePolicy defined, then the NamePolicy is blank. I also tried explicitly setting NamePolicy= in my 20-ens192.link file but it didn't help. I had to dig into the code of systemd. For detail:
Led me to this code in v244:
I didn't trace it back further - it seemed pretty clear to me at that point that if the naming scheme came up as v238, upon further digging I'd probably find that RERENAMES aren't allowed. |
Just for confirmation:
The NamePolicy setup will work with scheme v240 or newer. |
Good, thanks for the details! |
When the initramfs gave a persistent name to a network interface, renaming it via Name is not working with the v238 naming scheme even if NamePolicy is unset. Switch to the newest network interface naming scheme to resolve this issue. flatcar/Flatcar#36
When the initramfs gave a persistent name to a network interface, renaming it via Name is not working with the v238 naming scheme even if NamePolicy is unset. Switch to the newest network interface naming scheme to resolve this issue. flatcar/Flatcar#36
The change will land in the next release but has some other possible side effects where in few cases the persistent name will change slightly. Also a persistent name will be used where there was no one available before. |
Stable 2345.3.1 was just released, so this issue should be fixed. |
When 2345 was installed this morning, all my network renaming rules stopped working.
This is in the release notes, and broke it coreos/bugs#1767
My link file is pretty simple:
[Match]
MacAddress=....
[Link]
Name=srv0
This worked in previous stables releases of coreos and flatcar.
My server was in-place upgraded to flatcar per your documentation.
Upon running
SYSTEMD_LOG_LEVEL=debug udevadm test-builtin net_setup_link /sys/class/net/ens192
It indicates the default naming scheme is v238 - this naming scheme IMPLICITLY has the NamePolicy "keep" behavior applied. The keep option isn't available until v240 - BEFORE v240 it is ALWAYS applied even if you try to clear it. So what happens is in the initrd, eth0 gets renamed to ens192, and then when non-initrd systemd picks it up, it won't rename something that the "userspace" has already renamed. Ever.
I had to add this
set linux_append="net.naming-scheme=latest"
to my /usr/share/oem/grub.cfg to fix it. After boot, the interfaces are renamed properly, and udevadm shows it's using v240.
If there's a more permanent fix to this, or this needs to be documented, or re-changed, or the coreos to flatcar upgrade process needs another step... I don't know. Please investigate.
The text was updated successfully, but these errors were encountered: