This is an old revision of the document!
# hpacucli ctrl all show config # hpacucli ctrl slot=0 ld all show status
# hpacucli ctrl all show config detail
# hpacucli ctrl all diag file=/tmp/test /tmp/test is output file for result
Drive0: # smartctl -a -d cciss,0 /dev/cciss/c0d0 Drive1: # smartctl -a -d cciss,1 /dev/cciss/c0d0
The HPSA driver was introduced with RHEL6 to the RHEL family.
Drive0: # smartctl -a -d cciss,0 /dev/sg0 Drive1: # smartctl -a -d cciss,1 /dev/sg0
Ref: man smartctl
# lsscsi --long [3:0:0:0] storage HP P410i 5.14 - state=running queue_depth=1020 scsi_level=6 type=12 device_blocked=0 timeout=0 [3:0:0:1] disk HP LOGICAL VOLUME 5.14 /dev/sda state=running queue_depth=1020 scsi_level=6 type=0 device_blocked=0 timeout=30 Alternatively # dmesg | grep "^scsi " scsi 3:0:0:0: RAID HP P410i 5.14 PQ: 0 ANSI: 5 scsi 3:0:0:1: Direct-Access HP LOGICAL VOLUME 5.14 PQ: 0 ANSI: 5
Requires installation of sg3_utils RPM.
# sg_map /dev/sg0 /dev/sg1 /dev/sda /dev/sg2 /dev/sdb /dev/sg3 /dev/sdc /dev/sg4 /dev/sdd /dev/sg5 /dev/sde /dev/sg6 /dev/sdf /dev/sg7 /dev/sdg /dev/sg8 /dev/sdh /dev/sg9 /dev/sdi
Reference: man sg_map
Alternatively:
# lsscsi -g [3:0:0:0] storage HP P410i 5.14 - /dev/sg0 [3:0:0:1] disk HP LOGICAL VOLUME 5.14 /dev/sda /dev/sg1
LSI raid controller
First list the Logical Drives (LD's)
# /opt/MegaRAID/MegaCli/MegaCli64 -ldinfo -Lall -aall Adapter 0 -- Virtual Drive Information: Virtual Drive: 0 (Target Id: 0) Name : RAID Level : Primary-1, Secondary-0, RAID Level Qualifier-0 Size : 837.258 GB Mirror Data : 837.258 GB State : Optimal Strip Size : 128 KB Number Of Drives : 2 Span Depth : 1 Default Cache Policy: WriteBack, ReadAdaptive, Direct, No Write Cache if Bad BBU Current Cache Policy: WriteBack, ReadAdaptive, Direct, No Write Cache if Bad BBU Default Access Policy: Read/Write Current Access Policy: Read/Write Disk Cache Policy : Disabled Encryption Type : None PI type: Proprietary type
Is VD Cached: No
Virtual Drive: 1 (Target Id: 1) Name : RAID Level : Primary-1, Secondary-0, RAID Level Qualifier-0 Size : 1.634 TB Mirror Data : 1.634 TB State : Optimal Strip Size : 128 KB Number Of Drives per span:2 Span Depth : 2 Default Cache Policy: WriteBack, ReadAdaptive, Direct, No Write Cache if Bad BBU Current Cache Policy: WriteBack, ReadAdaptive, Direct, No Write Cache if Bad BBU Default Access Policy: Read/Write Current Access Policy: Read/Write Disk Cache Policy : Disabled Encryption Type : None PI type: No PI
So the target ID is 0 for VD 0 and the Target ID is 1 for VD 1
Find target ID to Disk Device translation
#lsscsi [0:0:19:0] enclosu IBM-ESXS SAS EXP BP 6126 - [0:0:36:0] enclosu IBM-ESXS SAS EXP BP 6126 - [0:2:0:0] disk IBM ServeRAID M5110 3.19 /dev/sda [0:2:1:0] disk IBM ServeRAID M5110 3.19 /dev/sdb [0:2:2:0] disk IBM ServeRAID M5110 3.19 /dev/sdc [0:2:3:0] disk IBM ServeRAID M5110 3.19 /dev/sdd [0:2:4:0] disk IBM ServeRAID M5110 3.19 /dev/sde [0:2:5:0] disk IBM ServeRAID M5110 3.19 /dev/sdf [1:0:0:0] cd/dvd IBM SATA DEVICE 81Y3664 IBA1 /dev/sr0
So Target ID 0 = 0:2:0:0 (the target ID is the digit after 2:) equals sda So Target ID 1 = 0:2:1:0 (the target ID is the digit after 2:) equals sdb
lsscsi command can be found in lsscsi.x86_64 package