1

用于创建页面 0x83 SCSI id 的算法是什么

# scsi_id --whitelisted --page=0x83  --device=/dev/sdjj
3600a0980443175414a3f4443364d5638
#

即在对应的软链接 /dev/disk/by-id/scsi-3600a0980443175414a3f4443364d5638 中使用磁盘类型、供应商、型号、序列号等,如

# scsi_id -g -x /dev/sdjj
ID_SCSI=1
ID_VENDOR=NETAPP
ID_VENDOR_ENC=NETAPP\x20\x20
ID_MODEL=LUN_C-Mode
ID_MODEL_ENC=LUN\x20C-Mode\x20\x20\x20\x20\x20\x20
ID_REVISION=8200
ID_TYPE=disk
ID_SERIAL_RAW="3600a0980443175414a3f4443364d5638"
ID_SERIAL=3600a0980443175414a3f4443364d5638
ID_SERIAL_SHORT=600a0980443175414a3f4443364d5638
ID_WWN=0x600a098044317541
ID_WWN_VENDOR_EXTENSION=0x4a3f4443364d5638
ID_WWN_WITH_EXTENSION=0x600a0980443175414a3f4443364d5638
ID_SCSI_SERIAL=D1uAJ?DC6MV8
#
# scsi_id --whitelisted --page=0x80  --device=/dev/sdjj
SNETAPP  LUN C-Mode     D1uAJ?DC6MV8
#

我记得几个月前在网上的某个地方看到了一个伪代码,但再也找不到了:(谢谢!

4

1 回答 1

0

看起来是这样的:

3600a098044316475463f444336434c6e serial (page 0x83 inquiry)
         44316475463f444336434c6e scsi serial (base64.b16encode('D1duF?DC6CLn').lower())
 600a098044316475 WWN
  00a098 OUI (NetApp)
3 scsi disk
于 2014-03-02T20:54:24.323 回答