Adding blockdev_prefix to hypervisor options
authorMaciej Bliziński <blizinski@google.com>
Fri, 26 Nov 2010 17:40:07 +0000 (17:40 +0000)
committerIustin Pop <iustin@google.com>
Sat, 27 Nov 2010 16:11:12 +0000 (17:11 +0100)
commit525011bcf19ac6efb5921b14e4a0841832efff27
tree4ee06d3949eea00b385451700b3fad29b5cd1157
parentcb6a02965cd77d73a75be682973956c871d1bf1a
Adding blockdev_prefix to hypervisor options

Allows to install Red Hat based systems, for example Oracle Linux.
Tested with OEL.

The hypervisor by default offers a device named 'sda'.  If the SCSI
module is already loaded, the disk device can't be created due to naming
conflict, and the disk is not available.  A workaround is to modify the
initrd by removing the scsi driver from it.  This helps, but doesn't
allow to install the OS.

Red Hat's installer, anaconda, runs parted, which tries to execute a
check against /dev/sda and fails.  This makes anaconda think that the
disk is faulty, and not available.  The best way to work around this, is
to declare 'xvda' as the xen disk device.  Red Hat version of parted
package contains a patch which makes parted skip the SCSI test if device
name starts with 'xvd'.

This patch allows to pass -H xen-pvm:blockdev_prefix="xvd" and
successfully run the Red Hat installer.

Signed-off-by: Maciej Bliziński <blizinski@google.com>
[iustin@google.com: added the new parameter to XenHvm PARAMS]
Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
lib/constants.py
lib/hypervisor/hv_xen.py
man/gnt-instance.rst