Sunday, 8 March 2015

How to install CentOS 7 on HP ProLiant BL460c G1/G5

1. Introduction

HP ProLiant BL460c G1/G5 is a very stable and reliable server platform widely employed by the dedicated servers providers. It has built-in HP Smart Array Controller that can be used under Linux by means of HP Smart Array CCISS driver. It provides the kernel modules cciss.ko. Unfortunately Red Hat Inc. discontinued the support for HP Smart Array CCISS driver and since then Red Hat Enterprise Linux 7 (RHEL 7) and CentOS 7 does not include cciss.ko in their kernel packages. Therefore the distribution installer Anaconda cannot recognize the SAS controller during the installation and cannot use the disks attached to it.

One possible way to overcome that problem is to adopt the kmod-cciss RPM package provided by the ELRepo repository. That package provides the module cciss.ko which is missing in the kernel modules tree, but it is not very trivial to place it into the initrd image and rebuild the installer disk. An easier and safer way is to use the original installer (without modifications), and instruct Anaconda to read the module from so called "driver disk", during the pre-installation process. The instructions given bellow cover only that kind of installation. Their execution requires a physical access to the server or access to iLO with virtual media support. The BIOS of the machine must allow the use of USB floopy and USB DVD as boot devices.

If you don't have a physical access to the server or it is a dedicated server owned by some hosting operator, it is mandatory to have an access to iLO. Some of the hosting companies you can find on the Internet does not give you an access to iLO. It is better to avoid such companies. Note that iLO has an important role in the administration of HP server systems!

2. Building the driver disk

To build a driver disk containing the cciss.ko module from the package kmod-cciss the following routine must be executed (on a system running CentOS or RHEL):

$ export CURR=`pwd`
$ export SQUASH_ROOT=${CURR}/squashfs-root
$ export VER=3.6.26-1
$ export RPM_PKG=kmod-cciss-${VER}.el7.elrepo.x86_64.rpm
$ mkdir -p ${SQUASH_ROOT}/rpms/x86_64/
$ echo "HP Smart Array CCISS driver ver. 3.6.26" > ${SQUASH_ROOT}/rhdd3
$ wget --directory-prefix=${SQUASH_ROOT}/rpms/x86_64/ http://elrepo.reloumirrors.net/elrepo/el7/x86_64/RPMS/${RPM_PKG}
$ createrepo --basedir ${SQUASH_ROOT}/rpms/x86_64/ .
$ touch ${SQUASH_ROOT}/.rundepmod
$ cd ${SQUASH_ROOT}
$ rpm2cpio ${SQUASH_ROOT}/rpms/x86_64/${RPM_PKG} | cpio -imVd ./lib/*
$ cd ${CURR}
$ mksquashfs ${SQUASH_ROOT} ${CURR}/kmod-cciss-${VER}-driver-disk.img
$ rm -fr ${SQUASH_ROOT}

Thus created file kmod-cciss-3.6.26-1-driver-disk.img contains the driver disk image. To list its content use the command line:

$ unsquashfs -ls kmod-cciss-3.6.26-1-driver-disk.img

3. Preparing the installation media

The installation process requires to have locally as files both driver disk and the latest CentOS 7 installer.

3.1. Connecting the virtual media applet provided by iLO (default installation media)

If iLO Virtual Media is accessible both installer and driver disk files should be selected and connected as virtual devices in the window of the applet:

To attach the driver disk as a virtual floppy go to "Virtual Floppy/USBkey" section of the applet window. Click there on "Local Image File" radio button, press "Browse" and then use the emerged file manager window to select the driver disk file. Finally, click on "Connect".

Almost the same sequence of operations need to be performed in "Virtual CD/DVD-ROM" section of the applet window in order to attach the CemtOS 7 installer iso file as virtual DVD.

3.2. Connecting physical media devices (requires physical access to the server)

It is not a common practice to have the server supplied or equipped with floppy and CD/DVD device. So if the virtual media provided by iLO is not accessible at the time USB Key and USB DVD device need to be pugged into the machine USB ports. Also the BIOS settings need to be adjusted to make possible booting from a USB DVD device.

The driver disk need to be transferred to a USB Key by using dd tool:

$ dd if=kmod-cciss-3.6.26-1-driver-disk.img of=/dev/sdb

(if the USB Key device is presented into the local system as /dev/sdb) and the CentOS 7 installer should be burned to a DVD blank.

4. Starting the installation

Reboot the machine. In the first screen shown by the installer:

press Tab. Then supply the installer with loading parameters:

Lets explain them:

inst.repo=http://mirror.cs.vt.edu/pub/CentOS/7/os/x86_64

This is the URL of the repository containing the CentOS 7 package collection. It is better to use a repository instead of transfering the packages from the local install media (the iso file) through iLO.

dd

It tells Anaconda to use driver disk. The driver disk need to be attached as USB Floppy.

inst.vnc

It tells Anaconda to redirect the video ouput to a VNC session. That redirection takes plase when the installer switches to the interactive mode (where the user can chose the parameters of the installation: language, the disk partitioning, packages, e.t.c.).

inst.vncpassword=tralala

The password for accessing the VNC session.

resolution=1366x768

The video resolution for the VNC session.

ip=124.124.126.242 netmask=255.255.255.248 gateway=124.124.126.242 nameserver=8.8.8.8

The IP address, netmask, gateway, and nameserver. Anaconda needs them for accessing the respository (see "inst.repo" above) and to provide a network access to the VNC session.

After pressing "Enter" the Anacoda is starting the installation process and soon it will ask for selecting the driver disk:

The driver disk (the USB Floppy) has a type "squashfs". To mark it for a further use do enter "2" and press "Enter". Then Anaconda will display the list of the drivers provided by the disk:

Enter the driver number (in the illustration the number is 1 since only one driver is provided) and then press "Enter".

Now the driver is selected and the should be loaded. Enter "c" and press "Enter" for loading the driver. The process of loading will be displayed:

Enter "c" and press "Enter" to continue. After that Anaconda will connect to the repository and download the installer components. When finish it will start the VNC session and display a message:

Finally a VNC viewer should be started and connected to the address and session number displayed before by Anaconda.

After pressing the "Connect" button a box for entering the VNC password will appear. If the password is entered correctly the VNC viewer will access the graphical installer window of Anaconda:

Now the installation could be run. After finishing the installation do not forget to disconnect the virtual of physical media before restarting the server.

5 comments:

  1. Thank you so much. This saved my day :-)

    ReplyDelete
  2. Thanks. Your instructions help me re-use older some servers.

    ReplyDelete
  3. hi, so which means, I need to have 1 usb containing "driver disk" and 1 dvd with Centos 7 installer included?

    ReplyDelete
    Replies
    1. If you follow Section 3.1 (as shown in the screen shot) both DVD and USB drives are emulated, which means you should point to the CentOS 7 installation ISO and driver disk IMG file, instead of burning DVD and writing down the IMG file on USB pen. In this case you emulate the DVD and USB devices. This is the most convenient waw.

      If you don't have access to the iLO console, as explained in Section 3.2, you have to burn one DVD with the minimal CentOS 7 iso, and write down the IMG file of the driver disk on USB stick.

      Delete
  4. Vesselin, Thank you! This is a GREAT help. I have 3 DL-580 G5 computers. The first workes exactly as you described. The second was a problem. I finally discovered that I could boot to CentOS 7 and add only "dd" for the driver disk and the install would complete.

    ReplyDelete