Forums

Home / Forums

You need to log in to create posts and topics. Login · Register

Drive Serial number discrepancy

We've recently had a drive go bad on the ceph cluster and had to go through the process of replacing it. We labeled the outside of each disk caddy with the serial number during the initial install, but could not match what was being displayed in interface to physical disk. Turns out the Serial number in web interface is closer to the WWN of the disk and not the serial number at all. Also the WWN on disk label doesn't match exactly to smartctl or udevadm output so there's some room for improvement here so locating disks is much easier.

Web interface Serial #: 5000c50041abcb33
Actual image of disk:  https://drive.google.com/file/d/17ddTyjDouxrHqfhvONqGtdaORFKXI-uL/view?usp=sharing

Udevadmin/smartctl output:

root@ceph-node2:~# udevadm info --query=all --name=/dev/sdi
P: /devices/pci0000:00/0000:00:03.0/0000:02:00.0/host0/port-0:0/expander-0:0/port-0:0:10/end_device-0:0:10/target0:0:10/0:0:10:0/block/sdi
N: sdi
S: disk/by-id/scsi-35000c50041abcb33
S: disk/by-id/wwn-0x5000c50041abcb33
S: disk/by-path/pci-0000:02:00.0-sas-exp0x500065b36789abff-phy17-lun-0
E: DEVLINKS=/dev/disk/by-path/pci-0000:02:00.0-sas-exp0x500065b36789abff-phy17-lun-0 /dev/disk/by-id/wwn-0x5000c50041abcb33 /dev/disk/by-id/scsi-35000c50041abcb33
E: DEVNAME=/dev/sdi
E: DEVPATH=/devices/pci0000:00/0000:00:03.0/0000:02:00.0/host0/port-0:0/expander-0:0/port-0:0:10/end_device-0:0:10/target0:0:10/0:0:10:0/block/sdi
E: DEVTYPE=disk
E: ID_BUS=scsi
E: ID_MODEL=ST1000NM0001
E: ID_MODEL_ENC=ST1000NM0001\x20\x20\x20\x20
E: ID_PART_TABLE_TYPE=gpt
E: ID_PART_TABLE_UUID=c083fc3c-0654-45c8-9a04-849e3b2ab02f
E: ID_PATH=pci-0000:02:00.0-sas-exp0x500065b36789abff-phy17-lun-0
E: ID_PATH_TAG=pci-0000_02_00_0-sas-exp0x500065b36789abff-phy17-lun-0
E: ID_REVISION=0002
E: ID_SCSI=1
E: ID_SCSI_SERIAL=Z1N1MJ7G0000C2424CKN
E: ID_SERIAL=35000c50041abcb33
E: ID_SERIAL_SHORT=5000c50041abcb33
E: ID_TYPE=disk
E: ID_VENDOR=SEAGATE
E: ID_VENDOR_ENC=SEAGATE\x20
E: ID_WWN=0x5000c50041abcb33
E: ID_WWN_WITH_EXTENSION=0x5000c50041abcb33
E: MAJOR=8
E: MINOR=128
E: SUBSYSTEM=block
E: TAGS=:systemd:
E: USEC_INITIALIZED=614075408728
E: net.ifnames=0

 

root@ceph-node2:~# smartctl -i /dev/sdi
smartctl 6.5 2016-01-24 r4214 [x86_64-linux-4.12.14-08-petasan] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, http://www.smartmontools.org

=== START OF INFORMATION SECTION ===
Vendor: SEAGATE
Product: ST1000NM0001
Revision: 0002
Compliance: SPC-4
User Capacity: 1,000,204,886,016 bytes [1.00 TB]
Logical block size: 512 bytes
Rotation Rate: 7200 rpm
Form Factor: 3.5 inches
Logical Unit id: 0x5000c50041abcb33
Serial number: Z1N1MJ7G0000C2424CKN
Device type: disk
Transport protocol: SAS (SPL-3)
Local Time is: Mon Mar 11 17:00:04 2019 EDT
SMART support is: Available - device has SMART capability.
SMART support is: Enabled
Temperature Warning: Enabled

Thanks a lot for reporting this.

The numbers we show are read from udevadmn E: ID_SERIAL_SHORT=5000c50041abcb33

If i as i understand you,  udevadmn reports 5000c50041abcb33 which is also what the web ui reports..but from the photo you showed this is actually the disk wwn, there is not a lot we can do, this is what the disk is reporting back as ID_SERIAL_SHORT.

Maybe if you are using a controller, it is the controller which swapped the wwn for the serial, or maybe it is the disk that reports this directly. One issue we found is sometimes some disk models do not behave in the same way as others, this was specially true when we added smarctl stats charts, we limited ourselves to just the parameters that are consistent among the different vendors/models, the others parameters seem to be interpreted differently by the different models.

I am also surprised why the last digit of the wwn is 0 on the real label rather than 3 which is being reported.

looking closer at the udevadmn

E: ID_SCSI_SERIAL=Z1N1MJ7G0000C2424CKN
E: ID_SERIAL=35000c50041abcb33
E: ID_SERIAL_SHORT=5000c50041abcb33

It seems the  ID_SCSI_SERIAL   has the correct value over ID_SERIAL and  ID_SERIAL_SHORT  but is this may not hold true for other disk models..maybe.

 

Hello:

we believe we may have found a reason for the discrepancy. please follow the following link to the bottom.

https://serverfault.com/questions/856239/why-is-there-a-shift-between-the-wwn-reported-from-the-controller-and-the-linux

 

as for the HBA card, we are using as follows

02:00.0 Serial Attached SCSI controller: LSI Logic / Symbios Logic SAS2008 PCI-Express Fusion-MPT SAS-2 [Falcon] (rev 02)

just getting back to this one... for those of us that label the front of the bays with the serial numbers from the Hard Drive sticker, it would still be nice if we can have the diskinfo show maybe ALL three of the numbers from the following output.... This would assist allot in replacing and locating disks.

udevadm info --query=all --name=/dev/sdd | grep SERIAL
E: ID_SCSI_SERIAL=S1Z0LFQ80000K5057W0D
E: ID_SERIAL=35000c5007ddf5a17
E: ID_SERIAL_SHORT=5000c5007ddf5a17

Even better, it'd be  pretty handy to have the full output of udevadm info and smartctl -A in a popup or details page. Maybe even a status LED toggle or blink if possible, just to help locate elusive disks.