Friday, July 2, 2010

Installation of HP Array Configuration Utility CLI for Linux on Ubuntu 10.04 Lucid Lynx

HP Array Configuration Utility CLI for Linux (hpacucli) is a useful tool that allows you to manage your HP RAID controller from command line (via ssh, that is). It can also be used to monitor the state of the disk subsystem with tools like Nagios or Zabbix. The following controllers are supported:

  • Smart Array 5312 Controller
  • Smart Array 5302 Controller
  • Smart Array 5304 Controller
  • Smart Array 532 Controller
  • Smart Array 5i Controller
  • Smart Array 641 Controller
  • Smart Array 642 Controller
  • Smart Array 6400 Controller
  • Smart Array 6400 EM Controller
  • Smart Array 6i Controller
  • Smart Array P600 Controller
  • Smart Array P400 Controller
  • Smart Array P400i Controller
  • Smart Array E200 Controller
  • Smart Array E200i Controller
  • Smart Array P800 Controller
  • Smart Array E500 Controller
  • Smart Array P700m Contoller
  • Smart Array P410i Controller
  • Smart Array P411 Controller
  • Smart Array P212 Controller
  • Smart Array P712m Contoller
  • Smart Array B110i SATA RAID
  • Smart Array P812 Controller
  • MSA500 Controller
  • MSA500 G2 Controller
  • MSA1000 Controller
  • MSA1500 CS Controller
  • MSA20 Controller

The tool is supplied on HP Support Pack CDs, but you can download a newer version from the HP site. To install hpacucli, visit this page and download hpacucli-8.50-6.0.noarch.rpm. Now, copy it to the server you'll install it on. Next, we'll unpack the RPM file. You can do it using, for example, rpm2cpio, rpm2tgz, etc. In Ubuntu, there's a utility called alien, that can do the same:

alien --to-tgz hpacucli-8.50-6.0.noarch.rpm

alien will report some errors and warnings, but don't worry. You will now get a new file, called hpacucli-8.50.tgz.

tar -xzf hpacucli-8.50.tgz

Move the unpacked files to corresponding locations:

sudo mv opt/compaq /opt/
sudo mv usr/sbin/* /usr/sbin/
Now, if you run a i386 kernel, you can run hpacucli, which is a 32-bit program. However, if your Ubuntu is a 64-bit system, you will have to allow execution of 32-bit binaries. One of the ways to do so is to install ia32-libs package. After the installation you can run hpacucli.

hpacucli gives you a prompt where you can enter commands or you can give the commands from the shell command line, like:

$ sudo hpacucli help

or

$ sudo hpacucli ctrl all show config

Smart Array P212 in Slot 1                (sn: PACCP9SYJ067  )

   array A (SAS, Unused Space: 0 MB)


      logicaldrive 1 (419.2 GB, RAID 1, OK)

      physicaldrive 1I:1:1 (port 1I:box 1:bay 1, SAS, 450 GB, OK)
      physicaldrive 1I:1:2 (port 1I:box 1:bay 2, SAS, 450 GB, OK)

   Expander 250 (WWID: 50014380065D7410, Port: 1I, Box: 1)

   Enclosure SEP (Vendor ID HP, Model DL18xG6BP) 248 (WWID: 50014380065D7423, Port: 1I, Box: 1)

   SEP (Vendor ID PMCSIERA, Model  SRC 8x6G) 249 (WWID: 50014380069159CF)

A similar command will give you even more information on the state of your RAID:

$ sudo hpacucli ctrl all show config detail

Now you can use this plugin to monitor the state of the array in Nagios. Besides, the information from hpacucli helped me to identify the causes of the significantly degraded performance of one of my servers (the battery of the write-cache was dead).

13 comments:

  1. Nice post, thanks.
    I did:
    alien -t hpacucli-8.50-6.0.noarch.rpm
    alien -d hpacucli-8.50.tgz
    dpkg -i hpacucli_8.50-2_all.deb

    ReplyDelete
  2. Yes, it should work. I was a bit afraid of getting broken dependencies and chose to install manually. Thanks for the idea.

    ReplyDelete
  3. wget http://debian.skyrock.net/pool/main/h/hpacucli/hpacucli_8.50-6.0.2-2_amd64.deb

    # dpkg --install hpacucli_8.50-6.0.2-2_amd64.deb

    ReplyDelete
  4. Aha! Thanks, aaresh. Next time I'll try this package.

    ReplyDelete
  5. HP's Debian repository:
    http://downloads.linux.hp.com/SDR/psp/pool/non-free/

    ReplyDelete
  6. If you have some trouble (.hpacucli not found) you could do this:
    sudo apt-get install ia32-libs

    ReplyDelete
  7. Do you know about HP repository?

    http://downloads.linux.hp.com/sdr/downloads/ProLiantSupportPack/

    ReplyDelete
  8. Thanks. You can also use repos as write here - http://sysadmin.te.ua/linux/hpraid-monitoring.html
    echo 'deb http://hwraid.le-vert.net/ubuntu precise main' > /etc/apt/sources.list.d/raid.list
    This repo has almost all raid monitoring utils for all type of raids! Regards.

    ReplyDelete
  9. Excellent work... Thanks for posting it..!

    123 HP Wireless

    ReplyDelete
  10. Wonderful blog & good post.Its really helpful for me, awaiting for more new post. Keep Blogging!
    123 HP Envy 7645 Install

    ReplyDelete
  11. Great thoughts you got there, believe I may possibly try just some of it throughout my daily life.


    hp envy 7640 troubleshooting

    ReplyDelete