Skip to content

Conversation

MahnoorAsghar
Copy link

Use ethtool ioctl to get permanent MAC address in ironic-python-agent so that in case of bonded interfaces, the correct interface MAC addresses are reported
Backporting upstream fix into 4.17

kajinamit and others added 3 commits October 1, 2025 15:17
The netifaces library was abandoned and archived. Replace it by psutil
which is already part of the requirements.

Closes-Bug: #2071596
Change-Id: Ibca206ec2af1374199d0c0cfad897dded1298733
(cherry picked from commit 42ea1db)
It's useful to have pci bus address/driver collected, the operator can
use the information to configure portgroup in a consistent way.

Change-Id: I432bca881ad881bae6d5e67c9b6fb52fe55b4e1e
(cherry picked from commit 96bf1ef)
Fetching the permanent MAC address of the interface instead of the
default one allows to get the right one in case it got changed during
setup (likely with a bonding setup).

In order to fetch the permanent MAC address of a given interface, one
can either use Netlink (either rtnetlink or ethtool), or use ethtool
ioctl.

The use of ioctl feels simpler and requires no additional dependency.
The implementation falls back to older behavior should an error occur.

Closes-Bug: #2103450
Change-Id: I54151990e396ddcf775128ca24d3db08e45c256d
Signed-off-by: Nicolas Belouin <[email protected]>
(cherry picked from commit 48422a5)
@openshift-ci-robot openshift-ci-robot added jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Oct 1, 2025
@openshift-ci-robot
Copy link

@MahnoorAsghar: This pull request references Jira Issue OCPBUGS-62490, which is invalid:

  • expected dependent Jira Issue OCPBUGS-62441 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST instead
  • expected dependent Jira Issue OCPBUGS-62441 to target a version in 4.18.0, 4.18.z, but it targets "4.19.z" instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

Use ethtool ioctl to get permanent MAC address in ironic-python-agent so that in case of bonded interfaces, the correct interface MAC addresses are reported
Backporting upstream fix into 4.17

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 openshift-eng/jira-lifecycle-plugin repository.

@MahnoorAsghar
Copy link
Author

/jira refresh

@openshift-ci-robot
Copy link

@MahnoorAsghar: This pull request references Jira Issue OCPBUGS-62490, which is invalid:

  • expected dependent Jira Issue OCPBUGS-62456 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/jira refresh

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot requested review from elfosardo and rhjanders October 1, 2025 13:32
Copy link

openshift-ci bot commented Oct 1, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: MahnoorAsghar
Once this PR has been reviewed and has the lgtm label, please assign rhjanders for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

openshift-ci bot commented Oct 1, 2025

@MahnoorAsghar: all tests passed!

Full PR test history. Your PR dashboard.

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-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants