Release
3.8.14
Issue
Logging
CommandException: Error running a command. cmd = ['/usr/sbin/smartctl', '--info', '/dev/nvme0n1']. rc = 1. stdout = ['smartctl 6.2 2013-07-26 r3841 [x86_64-linux-4.6.0-1.el7.elrepo.x86_64] (local build)', 'Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org', '', '/dev/nvme0n1: Unable to detect device type', 'Please specify device type with the -d option.', '', 'Use smartctl -h to get a usage summary', '', '']. stderr = [''] [01/Jul/2016 17:51:29] ERROR [storageadmin.views.disk:228] Error running a command. cmd = ['/usr/sbin/smartctl', '--info', '/dev/sde']. rc = 1. stdout = ['smartctl 6.2 2013-07-26 r3841 [x86_64-linux-4.6.0-1.el7.elrepo.x86_64] (local build)', 'Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org', '', '/dev/sde: Unknown USB bridge [0x0781:0x5581 (0x100)]', 'Please specify device type with the -d option.', '', 'Use smartctl -h to get a usage summary', '', '']. stderr = [''] Traceback (most recent call last): File "/opt/rockstor/src/rockstor/storageadmin/views/disk.py", line 226, in _update_disk_state do.name, do.smart_options) File "/opt/rockstor/src/rockstor/system/smart.py", line 311, in available [SMART, '--info'] + get_dev_options(device, custom_options)) File "/opt/rockstor/src/rockstor/system/osi.py", line 98, in run_command raise CommandException(cmd, out, err, rc)
Output of misc tools
lsblk
[root@storageserver ~]# lsblk -P -o NAME,MODEL,SERIAL,SIZE,TRAN,VENDOR,HCTL,TYPE,FSTYPE,LABEL,UUID NAME="sda" MODEL="WDC WD6002FFWX-6" SERIAL="NCGVL7AV" SIZE="5.5T" TRAN="sata" VENDOR="ATA " HCTL="6:0:0:0" TYPE="disk" FSTYPE="btrfs" LABEL="repo_pool" UUID="8bc44902-6437-47cd-b0f4-13c733de3f17" NAME="sdb" MODEL="WDC WD6002FFWX-6" SERIAL="K1G9Z23B" SIZE="5.5T" TRAN="sata" VENDOR="ATA " HCTL="7:0:0:0" TYPE="disk" FSTYPE="btrfs" LABEL="repo_pool" UUID="8bc44902-6437-47cd-b0f4-13c733de3f17" NAME="sdc" MODEL="WDC WD6002FFWX-6" SERIAL="NCGVP81V" SIZE="5.5T" TRAN="sata" VENDOR="ATA " HCTL="8:0:0:0" TYPE="disk" FSTYPE="btrfs" LABEL="media_pool" UUID="3bb70b4d-7456-4ee3-8511-bb14e67dcb2d" NAME="sdd" MODEL="WDC WD6002FFWX-6" SERIAL="K1GA0KYB" SIZE="5.5T" TRAN="sata" VENDOR="ATA " HCTL="9:0:0:0" TYPE="disk" FSTYPE="btrfs" LABEL="media_pool" UUID="3bb70b4d-7456-4ee3-8511-bb14e67dcb2d" NAME="sde" MODEL="Ultra " SERIAL="4C531001440716117184" SIZE="14.3G" TRAN="usb" VENDOR="SanDisk " HCTL="0:0:0:0" TYPE="disk" FSTYPE="" LABEL="" UUID="" NAME="sde1" MODEL="" SERIAL="" SIZE="500M" TRAN="" VENDOR="" HCTL="" TYPE="part" FSTYPE="ext4" LABEL="" UUID="2bfd7134-283f-4873-b9ae-6542fc32888e" NAME="sde2" MODEL="" SERIAL="" SIZE="1.4G" TRAN="" VENDOR="" HCTL="" TYPE="part" FSTYPE="swap" LABEL="" UUID="5fceda40-4d33-475a-a97c-79bc08cad2e7" NAME="sde3" MODEL="" SERIAL="" SIZE="12.4G" TRAN="" VENDOR="" HCTL="" TYPE="part" FSTYPE="btrfs" LABEL="rockstor_storageserver" UUID="5febd275-69b1-4d9f-9a17-2774c096e223" NAME="nvme0n1" MODEL="SAMSUNG MZVPV256HDGL-00000 " SERIAL="" SIZE="238.5G" TRAN="" VENDOR="" HCTL="" TYPE="disk" FSTYPE="" LABEL="" UUID=""
lspci
[root@storageserver ~]# lspci -v -s 07:00.0 07:00.0 Non-Volatile memory controller: Samsung Electronics Co Ltd Device a802 (rev 01) (prog-if 02 [NVM Express]) Subsystem: Samsung Electronics Co Ltd Device a801 Flags: bus master, fast devsel, latency 0, IRQ 19 Memory at de700000 (64-bit, non-prefetchable) [size=16K] I/O ports at c000 [size=256] Capabilities: [40] Power Management version 3 Capabilities: [50] MSI: Enable- Count=1/8 Maskable- 64bit+ Capabilities: [70] Express Endpoint, MSI 00 Capabilities: [b0] MSI-X: Enable+ Count=9 Masked- Capabilities: [100] Advanced Error Reporting Capabilities: [148] Device Serial Number 00-00-00-00-00-00-00-00 Capabilities: [158] Power Budgeting <?> Capabilities: [168] #19 Capabilities: [188] Latency Tolerance Reporting Capabilities: [190] L1 PM Substates Kernel driver in use: nvme
udevadm
(for /dev/sdx i see serials being retrieved)
[root@storageserver ~]# udevadm info --query=property --name nvme0 DEVNAME=/dev/nvme0 DEVPATH=/devices/pci0000:00/0000:00:1c.7/0000:07:00.0/nvme/nvme0 MAJOR=240 MINOR=0 SUBSYSTEM=nvme
[root@storageserver ~]# udevadm info --name nvme0n1 P: /devices/pci0000:00/0000:00:1c.7/0000:07:00.0/nvme/nvme0/nvme0n1 N: nvme0n1 E: DEVNAME=/dev/nvme0n1 E: DEVPATH=/devices/pci0000:00/0000:00:1c.7/0000:07:00.0/nvme/nvme0/nvme0n1 E: DEVTYPE=disk E: MAJOR=259 E: MINOR=0 E: SUBSYSTEM=block E: TAGS=:systemd: E: USEC_INITIALIZED=748316
Workaround?
Checking with tools from package nvme-cli was a success:
[root@storageserver ~]# nvme list Node SN Model Version Namespace Usage Format FW Rev /dev/nvme0n1 S1XWNYAH502774 SAMSUNG MZVPV256HDGL-00000 1.1 1 0.00 B / 256.06 GB 512 B + 0 B BXW7300Q
[root@storageserver ~]# nvme id-ctrl /dev/nvme0n1 NVME Identify Controller: vid : 0x144d ssvid : 0x144d sn : S1XWNYAH502774 mn : SAMSUNG MZVPV256HDGL-00000 fr : BXW7300Q rab : 2 ieee : 002538 cmic : 0 mdts : 5 cntlid : 1 ver : 0 rtd3r : 0 rtd3e : 0 oaes : 0 oacs : 0x7 acl : 7 aerl : 3 frmw : 0x6 lpa : 0x1 elpe : 63 npss : 4 avscc : 0x1 apsta : 0x1 wctemp : 0 cctemp : 0 mtfa : 0 hmpre : 0 hmmin : 0 tnvmcap : 0 unvmcap : 0 rpmbs : 0 sqes : 0x66 cqes : 0x44 nn : 1 oncs : 0x1f fuses : 0 fna : 0 vwc : 0x1 awun : 255 awupf : 0 nvscc : 1 acwu : 0 sgls : 0 ps 0 : mp:9.00W operational enlat:5 exlat:5 rrt:0 rrl:0 rwt:0 rwl:0 idle_power:- active_power:- ps 1 : mp:4.60W operational enlat:30 exlat:30 rrt:1 rrl:1 rwt:1 rwl:1 idle_power:- active_power:- ps 2 : mp:3.80W operational enlat:100 exlat:100 rrt:2 rrl:2 rwt:2 rwl:2 idle_power:- active_power:- ps 3 : mp:0.0700W non-operational enlat:500 exlat:5000 rrt:3 rrl:3 rwt:3 rwl:3 idle_power:- active_power:- ps 4 : mp:0.0050W non-operational enlat:2000 exlat:22000 rrt:4 rrl:4 rwt:4 rwl:4 idle_power:- active_power:-
Conclusion
So⊠extracting the S/N for devices managed by nvme driver by means of nvme tools?