-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
pasta: Fix pasta tests to work on hosts with multiple interfaces #19021
Conversation
/cc @Luap99 @sbrivio-rh |
@dgibson: GitHub didn't allow me to request PR reviews from the following users: sbrivio-rh. Note that only containers members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
At various points the pasta bats tests need to know the name of the interface that pasta will use by default, and the host addresses it will use by default. Currently we use the pre-existing helper functions ether_get_name and ipv[46]_get_addr_global to retreive that. However, those just pick the first non-loopback interface or address, which may not be the one that pasta uses if there are multiple connected host interfaces. Replace those helpers with local ones which examine the routing table to more closely match pasta's internal logic about which interface to select. This allows the tests to run successfully on a host with multiple interfaces. Closes: containers#19007 Signed-off-by: David Gibson <[email protected]>
I don't think the test failures here are related to my patch. |
Hi @dgibson. You can open and log in to https://cirrus-ci.com/task/6441926329630720, then click the "Retry" button, and CI will run again. |
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.
LGTM, @sbrivio-rh PTAL
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dgibson, Luap99 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
LGTM |
/lgtm |
containers#19021 fixed bugs with the pasta networking tests not working on hosts with multiple interfaces. Alas, the patch left in some stale code that generates spurious error messages for the IPv6 case. This is sort of harmless - later code overrides what's done here and the tests can pass anyway. However if a test fails for some other reason it means we get a misleading irrelevant error message. Signed-off-by: David Gibson <[email protected]>
containers#19021 fixed bugs with the pasta networking tests not working on hosts with multiple interfaces. Alas, the patch left in some stale code that generates spurious error messages for the IPv6 case. This is sort of harmless - later code overrides what's done here and the tests can pass anyway. However if a test fails for some other reason it means we get a misleading irrelevant error message. Signed-off-by: David Gibson <[email protected]>
At various points the pasta bats tests need to know the name of the interface that pasta will use by default, and the host addresses it will use by default. Currently we use the pre-existing helper functions ether_get_name and ipv[46]_get_addr_global to retreive that.
However, those just pick the first non-loopback interface or address, which may not be the one that pasta uses if there are multiple connected host interfaces.
Replace those helpers with local ones which examine the routing table to more closely match pasta's internal logic about which interface to select. This allows the tests to run successfully on a host with multiple interfaces.
Closes: #19007
Does this PR introduce a user-facing change?