Add a new element hpdsa

This element enables creation of Ubuntu deploy ramdisk and
user images which could be used to deploy the HP Proliant
Servers with Dynamic Smart Array Controllers. Without this driver
the disk with the Dynamic Smart Array Controller is
not visible to the ramdisk.

Closes bug: #1492803

Change-Id: Ibb3b298cd379cd7333279484df6ae30e9d7f6aaa
This commit is contained in:
Nisha Agarwal 2015-09-06 23:38:16 -07:00 committed by Gregory Haynes
parent a95b96f57f
commit 4509e6f826
6 changed files with 77 additions and 0 deletions

16
elements/hpdsa/README.rst Normal file
View File

@ -0,0 +1,16 @@
=====
hpdsa
=====
This is the hpdsa element.
This element enables the 'hpdsa' driver to be included in
the ramdisk when invoked during ramdisk/image creation.
This driver is required for deploying the HP Proliant Servers
Gen9 with Dynamic Smart Array Controllers.
Note: This element supports only Ubuntu image/ramdisk to be
updated with the hpdsa driver. It installs hp certificate
from https://downloads.linux.hp.com/SDR/hpPublicKey2048_key1.pub.
Since HP has released this currently only for trusty,
It has been restricted to work only for trusty.

View File

@ -0,0 +1,5 @@
build-essential:
curl:
phase: pre-install.d
linux-headers-generic:
hpdsa-dkms:

View File

@ -0,0 +1,14 @@
#!/bin/bash
if [ "${DIB_DEBUG_TRACE:-0}" -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
# Blacklist the ahci driver for hpdsa to recognize the disks.
# It can also be done with element "modprobe-blacklist" which
# would add the ahci driver to /etc/modprobe.d/blacklist.conf.
# To be on safer side, blacklist the driver ahci without the
# element "modprobe-blacklist" also.
echo "blacklist ahci" >> /etc/modprobe.d/install-hpdsa.conf
echo "hpdsa" >> /etc/modules

View File

@ -0,0 +1,11 @@
#!/bin/bash
if [ "${DIB_DEBUG_TRACE:-0}" -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
# This is required for HPDSA driver to be included in the
# ramdisk of the image.
update-initramfs -u

View File

@ -0,0 +1,14 @@
#!/bin/bash
if [ "${DIB_DEBUG_TRACE:-0}" -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
# Add hpdsa repository
echo 'deb https://downloads.linux.hp.com/SDR/repo/ubuntu-hpdsa' $DIB_RELEASE ' main' \
>> /etc/apt/sources.list.d/ubuntu-hpdsa.list
# Add the key
curl https://downloads.linux.hp.com/SDR/hpPublicKey2048_key1.pub | apt-key add -

View File

@ -0,0 +1,17 @@
#!/bin/bash
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
if [ 'ubuntu' != $DISTRO_NAME ] ; then
echo "Only ubuntu is supported for hpdsa driver. The DISTRO is set to $DISTRO_NAME"
exit 1
fi
if [ 'trusty' != $DIB_RELEASE ] ; then
echo "Only trusty is supported for hpdsa driver. The DIB_RELEASE is set to $DIB_RELEASE"
exit 1
fi