Using the PERC 5 with OpenSolaris Build 57

Jonathan Auer <jda@tapodi.net>

Warning: I have not tried this since build 57. This may no longer be necessary.

The document provides instuctions on getting OpenSolaris to work with the Dell PERC 5 RAID controller using the driver written by David Gwynne. I have only tested this procedure under OpenSolaris build 57. I do not see a why this would not work under Solaris 10, but your milage may vary. I'm using this driver on a pair of Dell 2950s and a Dell 1950.

My PERC 5/i has a PCI ID of pci1028,1f03. Different flavors of PERC 5 may have a different PCI ID. If it does, try pci1028,1f01 or pci1028,1f03. You can see which one you have by running prtconf -v

Changes

2007-05-31: Fixed add_drv command to include missing “-c scsi”. Mentiond on Sun's forums.

Building the driver

You will need Subversion and Sun Studio.
$ svn co https://svn.itee.uq.edu.au/repo/mfi
$ gmake
$ mv mfi mfi.64
$ gmake clean
$ cat Makefile | sed s/"-xarch=amd64 -xmodel=kernel"// >> Makefile.32
$ gmake -f Makefile.32
$ mv mfi mfi.32
$ gmake

Adding the driver to the installer

You probably should read the BigAdmin article on adding a device driver to the Solaris installer.

Download and unzip the OpenSolaris Community Edition CD #1. You can probably use the DVD version instead. The following instructions assume that the ISO image is named nv-b57-1.iso and that it is in /home/you/.

# lofiadm -a ~/nv-b57-1.iso /dev/lofi/1
# mount -F hsfs -o ro /dev/lofi/1 /mnt
# cd /mnt; find . -depth -print|cpio -vpdm /home/you/sol-inst
$ /boot/solaris/bin/root_archive unpack /home/you/sol-inst/boot/x86.miniroot /home/you/unpacked
$ cp mfi/mfi.32 unpacked/kernel/drv/mfi
$ mkdir unpacked/kernel/drv/amd64
$ cp mfi/mfi.64 unpacked/kernel/drv/amd64/mfi
$ touch unpacked/kernel/drv/mfi.conf
$ touch unpacked/kernel/drv/amd64/mfi.conf
$ add_drv -b /home/you/unpacked -n -v -m '* 0600 root sys' -i '"pci1028,1f03"' -c scsi mfi
$ /boot/solaris/bin/root_archive pack /home/you/x86.miniroot.mfi /home/you/unpacked
# mv /home/you/sol-inst/boot/x86.miniroot /home/you/sol-inst/boot/x86.miniroot.orig
# cp /home/you/x86.miniroot.mfi /home/you/sol-inst/boot/x86.miniroot
# mkisofs -o mfiiso.iso -b boot/grub/stage2_eltorito \
  -c .catalog -no-emul-boot -boot-load-size 4 \
  -boot-info-table -relaxed-filenames -N -L -l -r -J \
  -d -D -V b47MFI /home/you/sol-inst
Write the resulting image using your preferred CD burning program.

Installing using the driver

Boot the installer as usual. Your PERC-attached disks will appear on the partitioning screen. When asked, select the option to pause before reboot. You need to add the driver to the target drive before the installer reboots, otherwise the new system will not be able to boot.

# cp /kernel/drv/mfi /a/kernel/drv/mfi
# cp /kernel/drv/amd64/mfi /a/kernel/drv/amd64/mfi
# touch /a/kernel/drv/mfi.conf
# touch /a/kernel/drv/amd64/mfi.conf
# add_drv -b /a -n -v -i '"pci1028,1f03"' -c scsi mfi

If the system reboots immediatly after trying to boot, make sure of the following:

/etc/driver_aliases contains:
mfi "pci1028,1f03"
/etc/driver_classes contains:
mfi	scsi
Use the file command to make sure that the /kernel/drv/mfi is the 32 bit driver and /kernel/drv/amd64/mfi is the 64 bit driver.