forked from Sysdeploy/idlers-agent
Get nvme devices inside /sys/block/ instead of /dev
This commit is contained in:
parent
2c19f2eefc
commit
75744e0010
2
agent.py
2
agent.py
|
@ -157,7 +157,7 @@ class ServerData:
|
||||||
return devices
|
return devices
|
||||||
|
|
||||||
# Get the list of nvme devices starting with 'nvme'
|
# Get the list of nvme devices starting with 'nvme'
|
||||||
nvme_devices = [device for device in os.listdir('/dev') if device.startswith('nvme')]
|
nvme_devices = [device for device in os.listdir('/sys/block') if device.startswith('nvme')]
|
||||||
|
|
||||||
for device in nvme_devices:
|
for device in nvme_devices:
|
||||||
device_path = '/dev/' + device
|
device_path = '/dev/' + device
|
||||||
|
|
Loading…
Reference in New Issue
Block a user