From 2e44365dad5f8dd6a495070d36c590319a421c28 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 23 May 2021 10:35:20 +0200 Subject: op-mode: storage: T3572: add S.M.A.R.T. status support vyos@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 vyos@vyos:~$ show hardware storage smart nvme0n1 === START OF INFORMATION SECTION === Model Number: SAMSUNG MZQLB960HAJR-00007 Serial Number: S437Nxxxxxxxxx ... --- debian/control | 2 ++ op-mode-definitions/show-hardware.xml.in | 34 ++++++++++++++++++++++++++------ 2 files changed, 30 insertions(+), 6 deletions(-) diff --git a/debian/control b/debian/control index 5d58f1a96..8ce2862c7 100644 --- a/debian/control +++ b/debian/control @@ -78,6 +78,7 @@ Depends: nginx-light, ntp, ntpdate, + nvme-cli, ocserv, openssh-server, openssl, @@ -113,6 +114,7 @@ Depends: qrencode, radvd, salt-minion, + smartmontools, snmp, snmpd, squid, diff --git a/op-mode-definitions/show-hardware.xml.in b/op-mode-definitions/show-hardware.xml.in index 0df2e4404..20fdd753d 100644 --- a/op-mode-definitions/show-hardware.xml.in +++ b/op-mode-definitions/show-hardware.xml.in @@ -53,18 +53,40 @@ - + - Show SCSI device information + Show system storage information - lsscsi - + + + Show NVMe device information + + sudo nvme list + + - Show detailed SCSI device information + Show SCSI device information - lsscsi -vvv + lsscsi + + + + Show detailed SCSI device information + + lsscsi -vvv + + + + + Show S.M.A.R.T. device information + + + + + sudo smartctl -a "/dev/$5" | sed 1,3d + -- cgit v1.2.3