Skip to content

Commit

Permalink
Fix rdma plugin package
Browse files Browse the repository at this point in the history
Also, use mlnx-iproute2 when available

Signed-off-by: Shay Drory <[email protected]>
  • Loading branch information
shayshyi authored and filanov committed Feb 3, 2025
1 parent a2c2078 commit 07a628a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions sos/report/plugins/rdma.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class Rdma(Plugin, IndependentPlugin):

plugin_name = "rdma"
profiles = ('hardware',)
packages = ('iproute2',)
packages = ('iproute2', 'iproute', 'mlnx-iproute2')

def setup(self):

Expand All @@ -38,7 +38,10 @@ def setup(self):
"srq"
]

self.add_cmd_output([f"rdma {cmd} -d" for cmd in rdma_cmds])
rdma = '/opt/mellanox/iproute2/sbin/rdma'
if not self.path_exists(rdma):
rdma = 'rdma'
self.add_cmd_output([f"{rdma} {cmd} -d" for cmd in rdma_cmds])

self.add_cmd_output([f"rdma resource show {rsc} -d"
self.add_cmd_output([f"{rdma} resource show {rsc} -d"
for rsc in rdma_rsc_obj])

0 comments on commit 07a628a

Please sign in to comment.