-
Notifications
You must be signed in to change notification settings - Fork 33
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
Fix veth device move #368
Fix veth device move #368
Conversation
In particular for veth device pair, when first device from the pair is moved to netns, the peer name is generated from the device name with additional index suffix that is incorrect. For example for the devicepair of {lveth0, peer_lveth0}, when lveth0 is moved to a namespace, the peer is set to peer_lveth00. To fix this, we can pass the peer name directly in the remap_device call. Signed-off-by: Jan Tluka <[email protected]>
Resolves an issue when moving a veth device to a namespace. The device will have _nl_link_update populated with data from generic Device creation (device appears in the namespace). This data may cause issues for certain device operations like setting the link up. To avoid this, clearing the _nl_link_update while remapping the device solves the issue. Fixes LNST-project#367 Signed-off-by: Jan Tluka <[email protected]>
I hit an issue when running SRIOVNetnsTcRecipe:
I will add try/except block to catch this. |
…ribute Signed-off-by: Jan Tluka <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The exception you see for sriov recipe is weird as it should still be a RemoteDevice
and the peer_name
is a normal class property which should always be present.... at worst it should return None
But otherwise this looks good so ack to merge this in case the tests pass for phil.
Description
Resolves an issue when moving a veth device to a namespace. The device will
have _nl_link_update populated with data from generic Device creation (device
appears in the namespace). This data may cause issues for certain device
operations like setting the link up.
To avoid this, clearing the _nl_link_update while remapping the device
solves the issue.
Fixes #367
Tests
Tested with the reproducer from the issue both in container setup and normal setup.
I scheduled test run in RH labs that include a single run of each recipe type, beaker job id J:9261245
Reviews
@olichtne