Thursday, December 17, 2009

hpacucli Create Hot Spare

I have a ProLiant DL360 G5 running Red Hat 4.1.2-14.

This server has a Smart Array 6400 with 13 300GB SCSI disks allocated in two arrays and 1 disk unallocated.

This server also has a Smart Array P400i with 4 disks allocated in 2 arrays and 1 disk unallocated.

My goal is to add the unallocated disk as a spare to both arrays on each controller. This server does not have a GUI so I must use the HP Array Configuration Utility CLI called "hpacucli".

To run the HP Array Configuration Utility CLI simply type "hpacucli" in the shell.

Next lets look at all our arrays using the following command:

ctrl all show config



We can see that Smart Array 6400 is in Slot 2 and Smart Array P400i is in Slot 0. We can also see the unassigned disks are physicaldrive 1:8 and physicaldrive 2I:1:5.

To assign the drives as hot spares run the following commands:

ctrl slot=2 array all add spares=1:8



ctrl slot=0 array all add spares=2I:1:5



We specify "array all" as we want to make the disk available to all disks on the controller. We could go "array A" if we wanted to make the spare available to just onje array... I don't know why you would though!

Now if we run the "ctrl all show config" command again we see it's added it in as a spare:



If you want more information about performing other tasks using hpacucli the following link is the best documentation I could find:

http://people.freebsd.org/~jcagle/hpacucli-readme

5 comments:

  1. Thanks for this. It was exactly what I needed to add a hot spare to a RAID 1 mirror on my DL380 G5 w/ Debian Lenny box.

    Stu

    ReplyDelete
  2. This command also can be implemented on Smart Array P800 card

    ReplyDelete
  3. 3 1/2 year old info, still relevent. thanks clint.

    jim

    ReplyDelete
  4. Hi there, once it's added as a hot spare does that mean that it will automatically replace a failed or failing disk ?
    or is there some other step that needs to be taken to swop in the hot spare disk ?

    cheers G

    ReplyDelete