Skip to content

Commit

Permalink
[nvidia] Capture more nvidia commands
Browse files Browse the repository at this point in the history
Capture commands related to nvidia container toolkit.

Related: RHEL-58172

Signed-off-by: Jose Castillo <[email protected]>
  • Loading branch information
jcastill committed Sep 12, 2024
1 parent a946343 commit 5ca4480
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion sos/report/plugins/nvidia.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class Nvidia(Plugin, IndependentPlugin):

short_desc = 'Nvidia GPU information'
plugin_name = 'nvidia'
commands = ('nvidia-smi',)
commands = ('nvidia-smi', 'nvidia-ctk',)

def setup(self):
subcmds = [
Expand All @@ -30,8 +30,17 @@ def setup(self):
'nvlink -e'
]

ctk_subcmds = [
'cdi list',
'--version',
]

self.add_copy_spec("/etc/cdi/nvidia.yaml")
self.add_service_status("nvidia-persistenced")
self.add_service_status("nvidia-fabricmanager")
self.add_service_status("nvidia-toolkit-firstboot")
self.add_cmd_output([f"nvidia-smi {cmd}" for cmd in subcmds])
self.add_cmd_output([f"nvidia-ctk {cmd}" for cmd in ctk_subcmds])

query = ('gpu_name,gpu_bus_id,vbios_version,temperature.gpu,'
'utilization.gpu,memory.total,memory.free,memory.used,'
Expand Down

0 comments on commit 5ca4480

Please sign in to comment.