Page MenuHomeVyOS Platform

Basic Drive Diagnostic Tools
Closed, ResolvedPublicFEATURE REQUEST

Description

VyOS appears to be able to pull basic SCSI data, which is great, but I think it needs more. Commonly we run systems with SSDs or NVMe drives, and being able to use smartctl and nvme is important in checking for signs of failure such as pending sectors and SMART errors. I would like to propose that a basic operational mode command is added to show the information for both.
For the output of nvme list

trae@cr01a-vyos:~$ show hardware nvme
Node             SN                   Model                                    Namespace Usage                      Format           FW Rev  
---------------- -------------------- ---------------------------------------- --------- -------------------------- ---------------- --------
/dev/nvme0n1     SNREMOVED            Samsung SSD 980 PRO 2TB                  1           1.87  TB /   2.00  TB    512   B +  0 B   2B2QGXA7
/dev/nvme1n1     SNREMOVED            Samsung SSD 980 PRO 2TB                  1           1.87  TB /   2.00  TB    512   B +  0 B   2B2QGXA7

and for the output of smartctl -a /dev/<device>

trae@cr01a-vyos:~$ show hardware smart <device>
smartctl 7.1 2020-04-05 r5049 [x86_64-linux-4.18.0-240.22.1.el8_3.x86_64] (local build)
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Number:                       Samsung SSD 980 PRO 2TB
Serial Number:                      REMOVED
Firmware Version:                   2B2QGXA7
PCI Vendor/Subsystem ID:            0x144d
IEEE OUI Identifier:                0x002538
Total NVM Capacity:                 2,000,398,934,016 [2.00 TB]
Unallocated NVM Capacity:           0
......removed for brevity......
Error Information (NVMe Log 0x01, max 64 entries)
No Errors Logged

Details

Difficulty level
Easy (less than an hour)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Improvement (missing useful functionality)

Event Timeline

c-po changed the task status from Open to In progress.May 23 2021, 7:43 AM
c-po triaged this task as Wishlist priority.
c-po added a project: VyOS 1.3 Equuleus.
c-po changed Difficulty level from Unknown (require assessment) to Easy (less than an hour).
cpo@cr01-vyos:~$ show hardware storage
Possible completions:
  nvme          Show NVMe device information
  scsi          Show SCSI device information
  smart         Show S.M.A.R.T. device information
cpo@cr01-vyos:~$ show hardware storage nvme
Node             SN                   Model                                    Namespace Usage                      Format           FW Rev
---------------- -------------------- ---------------------------------------- --------- -------------------------- ---------------- --------
/dev/nvme0n1     S437Nxxxxxxxxx       SAMSUNG MZQLB960HAJR-00007               1          25.17  GB / 960.20  GB    512   B +  0 B   EDA5202Q
/dev/nvme1n1     S437Nxxxxxxxxx       SAMSUNG MZQLB960HAJR-00007               1          38.36  GB / 960.20  GB    512   B +  0 B   EDA5202Q
cpo@cr01-vyos:~$ show hardware storage smart
Possible completions:
  nvme0n1       Show S.M.A.R.T. device information
  nvme1n1
cpo@cr01-vyos:~$ show hardware storage smart nvme0n1
smartctl 6.6 2017-11-05 r4594 [x86_64-linux-5.4.113-amd64-vyos] (local build)
Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Number:                       SAMSUNG MZQLB960HAJR-00007
Serial Number:                      S437Nxxxxxxxxx
...
c-po moved this task from Need Triage to Finished on the VyOS 1.3 Equuleus board.
c-po moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.
SrividyaA set Issue type to Improvement (missing useful functionality).Aug 31 2021, 5:59 PM