-
-
Notifications
You must be signed in to change notification settings - Fork 248
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
No longer able to rename interface after update to any version later than 0.7.6: "could not setup alt ifnames" #1178
Comments
Strange enough I can not reproduce it on the master branch, but obviously there is some issue. If you have a VM (an image or a deployed instance) to reproduce and you could give a chance to debug there — I would be very grateful. |
It's reproducible for me with the stock Debian images (e.g.
With
Which leads me back to I originally stumbled upon this on a Debian host with the "traditional" |
Thanks a lot! Investigating |
Reproduced, thanks! This week the issue will be fixed. |
Before 0.7.7 NDB simply ignored altnames, thus the latest working version for you is 0.7.6. But with 0.7.7 NDB started to track altnames too. Renaming some types of interfaces on some kernels causes the old name to become an altname, and NDB rejects it, expecting no altnames change. Dummy interfaces don't cause this issue, so CI didn't catch it.
|
Awesome. Thanks a bunch! |
Control `alt_ifname_list` after rename. Ignore the old interface name in `alt_ifname_list`. Bug-Url: #1178
Control `alt_ifname_list` after rename. Ignore the old interface name in `alt_ifname_list`. Bug-Url: #1178
Control `alt_ifname_list` after rename. Ignore the old interface name in `alt_ifname_list`. Bug-Url: #1178
Control `alt_ifname_list` after rename. Ignore the old interface name in `alt_ifname_list`. Bug-Url: #1178
Control `alt_ifname_list` after rename. Ignore the old interface name in `alt_ifname_list`. Bug-Url: #1178
Pls try if this will work: #1180 (It works for me, but I could miss something) |
Works for my use cases. Thanks! ❤️ I don't know if it's intended, but changing the name and then reverting to the original doesn't work since the original name becomes an altname on the interface, i.e. running
followed by
results in
I have no need for this but maybe this should be mentioned in the documentation somewhere? |
It's not intended, it's how the kernel works in this case. Let me add a workaround for that. |
If the new name is in altnames, remove it from there first. Bug-Url: #1178
If the new name is in altnames, remove it from there first. Bug-Url: #1178
Ok, now I believe it should work better in any direction, including rollbacks. I don't like too much the way I had to do it, since the commit logic becomes too fuzzy, but it should work for now. May I ask you to check? Thanks a lot for the help! |
Merged to the master branch in order not to block the next PR. |
No worries, thanks a bunch for fixing this! Really appreciated. ❤️ |
After updating pyroute2 to any version newer that 0.7.6 I'm no longer able to run the following snippet ("Hello world" example from https://docs.pyroute2.org/general.html#ndb-high-level-rtnl-api):
After downgrading pyroute2 to version 0.7.6 renaming the interface works again as expected:
OS is Debian 12.5. Interface is unconfigured, i.e.
/etc/network/interfaces
does not contain anything about the device. Neither NetworkManager nor systemd-networkd is installed.I've checked a all versions between 0.7.6 and 0.7.12 as well, all with the same result (i.e.
Exception: could not setup alt ifnames
).The text was updated successfully, but these errors were encountered: