Thursday, June 2, 2016

Find a disk serial number on a VMware vSphere ESXi HP Proliant host

I had an issue on a hard drive on my HP Proliant.

You must have installed your ESXi with the special HP distribution (available on VMware website)

STEP 1
  • On your vSphere client, log in your server (directly the ESXi host, not the vSphere appliance).
  • Click on your host, configuration, go to security profile
  • Select the SSH service, Options, Start.
    You can find other ways to enable SSH here, or using search engines.
  • Don't forget to disable SSH after your operation.
STEP 2

To find informations and SN about the disks, we will use hpssacli.
You can find further informations about this command here and here.

  • Log in your ESXi host using putty
    • Username : root
    • Password: your current root password
  •  cd /opt/hp/hpssacli/bin/
  • In order to show controler informations
    ./hpssacli ctrl all show detail
    Smart Array P420i in Slot 0 (Embedded)
       Bus Interface: PCI
       Slot: 0
       Serial Number: 001438027FEFE60
       Cache Serial Number: PBKUA0BRH5K3HN
       RAID 6 (ADG) Status: Enabled
       Controller Status: OK
       Hardware Revision: B
       Firmware Version: 4.68
       Rebuild Priority: Medium
       Expand Priority: Medium
       Surface Scan Delay: 15 secs
       Surface Scan Mode: Idle
       Queue Depth: Automatic
       Monitor and Performance Delay: 60  min
       Elevator Sort: Enabled
       Degraded Performance Optimization: Disabled
       Inconsistency Repair Policy: Disabled
       Wait for Cache Room: Disabled
       Surface Analysis Inconsistency Notification: Disabled
       Post Prompt Timeout: 0 secs
       Cache Board Present: True
       Cache Status: OK
       Cache Ratio: 25% Read / 75% Write
       Drive Write Cache: Disabled
       Total Cache Size: 512 MB
       Total Cache Memory Available: 304 MB
       No-Battery Write Cache: Disabled
       Cache Backup Power Source: Capacitors
       Battery/Capacitor Count: 1
       Battery/Capacitor Status: OK
       SATA NCQ Supported: True
       Spare Activation Mode: Activate on physical drive failure (default)
       Controller Temperature (C): 64
       Number of Ports: 2 Internal only
       Encryption Supported: False
       Driver Name: HP HPSA
       Driver Version: 5.5.0
       Driver Supports HP SSD Smart Path: False
  • To find defective disk (use the right slot, 2nd line on the last command)
    ./hpssacli ctrl slot=0 pd all show status
       physicaldrive 1I:1:1 (port 1I:box 1:bay 1, 600 GB): OK
       physicaldrive 1I:1:2 (port 1I:box 1:bay 2, 600 GB): Failed
       physicaldrive 1I:1:3 (port 1I:box 1:bay 3, 600 GB): OK
       physicaldrive 1I:1:4 (port 1I:box 1:bay 4, 600 GB): OK
       physicaldrive 2I:1:5 (port 2I:box 1:bay 5, 600 GB): OK
       physicaldrive 2I:1:6 (port 2I:box 1:bay 6, 600 GB): OK
  • To get more informations on all disk, including the serial number
    ./hpssacli ctrl slot=0 pd all show detail
    Smart Array P420i in Slot 0 (Embedded)

       array A

          physicaldrive 1I:1:1
             Port: 1I
             Box: 1
             Bay: 1
             Status: OK
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Current Temperature (C): 38
             Maximum Temperature (C): 49
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: OK
             Carrier Application Version: 11
             Carrier Bootloader Version: 6

          physicaldrive 1I:1:2
             Port: 1I
             Box: 1
             Bay: 2
             Status: Failed
             Last Failure Reason: Mark bad failed
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Maximum Temperature (C): 53
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: Not Applicable

          physicaldrive 1I:1:3
             Port: 1I
             Box: 1
             Bay: 3
             Status: OK
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Current Temperature (C): 42
             Maximum Temperature (C): 53
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: OK
             Carrier Application Version: 11
             Carrier Bootloader Version: 6

          physicaldrive 1I:1:4
             Port: 1I
             Box: 1
             Bay: 4
             Status: OK
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Current Temperature (C): 43
             Maximum Temperature (C): 52
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: OK
             Carrier Application Version: 11
             Carrier Bootloader Version: 6

          physicaldrive 2I:1:5
             Port: 2I
             Box: 1
             Bay: 5
             Status: OK
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Current Temperature (C): 43
             Maximum Temperature (C): 52
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: OK
             Carrier Application Version: 11
             Carrier Bootloader Version: 6

          physicaldrive 2I:1:6
             Port: 2I
             Box: 1
             Bay: 6
             Status: OK
             Drive Type: Data Drive
             Interface Type: SAS
             Size: 600 GB
             Native Block Size: 512
             Rotational Speed: 10500
             Firmware Revision: HPD3
             Serial Number: S0M1L5M9000XXXX
             Model: HP      EG0600FCVBK
             Current Temperature (C): 39
             Maximum Temperature (C): 47
             PHY Count: 2
             PHY Transfer Rate: 6.0Gbps, Unknown
             Drive Authentication Status: OK
             Carrier Application Version: 11
             Carrier Bootloader Version: 6
    Once you've changed the disk, you can check the rebuild status using this command:
  • ./hpssacli ctrl slot=0 ld 1 show
    Smart Array P420i in Slot 0 (Embedded)

       array A

          Logical Drive: 1
             Size: 2.7 TB
             Fault Tolerance: 5
             Heads: 255
             Sectors Per Track: 32
             Cylinders: 65535
             Strip Size: 256 KB
             Full Stripe Size: 1280 KB
             Status: Recovering, 29% complete
             Caching:  Enabled
             Parity Initialization Status: Initialization Completed
             Unique Identifier: 600508B1001CF21E96713374CEBAD21D
             Logical Drive Label: A23BA9B5001438027FEFE6027CA
             Drive Type: Data
             LD Acceleration Method: Controller Cache


    Other commands in the documentations mentioned below.

    Comments welcome!