HPE ssacli on TrueNAS SCALE

My TrueNAS SCALE setup is on a HPE ML350 Gen9 with a SmartHBA H240ar (which is IT mode) and I needed to clear existing drive configuration with drives that were used in other HPE servers which prevented the drives from coming online on my server. The drives were being “masked” by the HBA thus I had to leverage HPE OEM tools to clear the configuration before moving forward.


truenas kernel: hpsa 0000:03:00.0: scsi 0:0:19:0: masked Direct-Access HPE EG001200JWJNQ PHYS DRV SSDSmartPathCap- En- Exp=0
truenas kernel: hpsa 0000:03:00.0: scsi 0:0:21:0: masked Direct-Access HPE EG001200JWJNQ PHYS DRV SSDSmartPathCap- En- Exp=0
truenas kernel: hpsa 0000:03:00.0: scsi 0:0:22:0: masked Direct-Access HPE EG001200JWJNQ PHYS DRV SSDSmartPathCap- En- Exp=0

HPE has a variety of tools and nearly all of the them are built for Linux as well. With the being said, I didn’t have another box other than my TrueNAS box to install these packages to clear the drive configurations. After research and a little detective work, I was able to use ssacli binaries on TrueNAS without installing any packages.

I first investigated what Debian version that TrueNAS was running.

root@truenas:~# cat /etc/debian_version
11.5

After knowing it’s Debian 11 and a quick cross-check it turns out to be codename “bullseye”. I headed over to the HPE Linux repository and started browsing through directories to find the Debian apt package for “bullseye”. On the front page (HPE Software Delivery Repository) at the bottom, I found the version I needed for “bullseye”. I was now looking for version 12.40. I found the bullseye catalog here: https://downloads.linux.hpe.com/SDR/repo/mcp/Debian/dists/bullseye/12.40/non-free/binary-amd64/Packages

I opened up the catalog file which led me to the file which I needed to download. After reading the dependencies, it simply requires libc6 which is fundamental in any Debian system for many default and included packages.

Package: ssacli
Architecture: amd64
Version: 5.30-6.0
Priority: optional
Section: admin
Source: ssacli
Maintainer: Lin[email protected]
Depends: libc6 (>= 2.7)
Filename: pool/non-free/ssacli-5.30-6.0_amd64.deb
Size: 11474308
MD5sum: d0602fdb66490e64a788b6f999a7d5f1
SHA1: e1c56f233097597c67f90565eadafbe7f9089a3e
SHA256: 7be23f004bc3c502aefd3b3ea2fe3fe8f1a12e0c42569d6645e72b711f22b0e9
SHA512: 7d8f82cd8c85cb309b0e7c6d0cd952603552f8109dec6cf825ab8ba6cb745fc1de7cb48462baa74af912494b98caad9736b10905d6e55ab0e6ab39974392dbe9
Description: Command Line Smart Storage Administration Utility
 Command Line Smart Storage Administration Utility is the disk
 array configuration program for Array Controllers.
Build-Depends: debhelper (>> 5)
Standards-Version: 3.7.2.2

Now that I found the file name for Debian “bullseye” I downloaded the respective .deb file – https://downloads.linux.hpe.com/SDR/repo/mcp/Debian/pool/non-free/ssacli-5.30-6.0_amd64.deb

Once I downloaded that to my desktop, I used 7-Zip to extract the contents of the deb package and it’s inside tar file to my desktop. At that point, I used FileZilla to move what I just extracted to /root/ssacli on my TrueNAS SCALE installation.

I cracked open PuTTy to make the ssacli executable by issuing a

chmod +x ssacli

After that, I ran it with success

./ssacli

I got the information I needed and cleared the drive configuration! (ctrl slot=0 pd all show detail). For a good list of ssacli command references go check out https://wiki.phoenixlzx.com/page/ssacli/ and https://be-virtual.net/hpe-storage-controller-management-ssacli

 physicaldrive 1I:1:5
         Masked from HBA: The drive contains controller configuration data and has been disabled in order to protect the configuration data. Please run the "modify clearconfigdata" command on the drive to re-enable it.
         Port: 1I
         Box: 1
         Bay: 5
         Status: OK
         Drive Type: HBA Mode Drive
         Interface Type: SAS
         Size: 1.2 TB
         Drive exposed to OS: False
         Logical/Physical Block Size: 512/512
         Rotational Speed: 10500
         Firmware Revision: HPD4
         Serial Number: xxxxxxx
         WWID: 5000C500xxxxxxxx
         Model: HPE     EG001200JWJNQ
         Current Temperature (C): 24
         Maximum Temperature (C): 41
         PHY Count: 2
         PHY Transfer Rate: 12.0Gbps, Unknown
         PHY Physical Link Rate: Unknown, Unknown
         PHY Maximum Link Rate: Unknown, Unknown
         Drive Authentication Status: OK
         Carrier Application Version: 11
         Carrier Bootloader Version: 6
         Sanitize Erase Supported: True
         Sanitize Estimated Max Erase Time: 1 hour(s), 55 minute(s)
         Unrestricted Sanitize Supported: True
         Shingled Magnetic Recording Support: None

After I confirmed it was masked through ssacli. I cleared it by issuing the following command:

controller slot=0 physicaldrive 1I:1:5 modify clearconfigdata

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.