summaryrefslogtreecommitdiffstats
path: root/nova
diff options
context:
space:
mode:
authorChuck Short <chuck.short@canonical.com>2012-11-20 18:20:11 -0600
committerChuck Short <chuck.short@canonical.com>2012-11-22 07:56:21 -0600
commit3d60c4fb6f182baf61f55d293cdca49ae9e4ea85 (patch)
tree4bd6143d399b117f4e6e64436c16ea820d43f774 /nova
parent4ff9b97723537ce6ca1ec55e2bb6987975899b5e (diff)
downloadnova-3d60c4fb6f182baf61f55d293cdca49ae9e4ea85.tar.gz
nova-3d60c4fb6f182baf61f55d293cdca49ae9e4ea85.tar.xz
nova-3d60c4fb6f182baf61f55d293cdca49ae9e4ea85.zip
Don't hard code the xen hvmloader path.
Both Ubuntu and Debian place the hvmloader in a different path which depends on the version is installed. The reason why this done is so you can different versions of Xen installed. As a result change the hvmloader to a configurable option for libvirt called xen_hvmloader_path. Change-Id: Ic407d14f56a2518de4cd4ab8872ac2055d20adcd Signed-off-by: Chuck Short <chuck.short@canonical.com>
Diffstat (limited to 'nova')
-rw-r--r--nova/virt/libvirt/driver.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/nova/virt/libvirt/driver.py b/nova/virt/libvirt/driver.py
index 14e8a75d2..88c136c21 100644
--- a/nova/virt/libvirt/driver.py
+++ b/nova/virt/libvirt/driver.py
@@ -180,6 +180,9 @@ libvirt_opts = [
default='$instances_path/snapshots',
help='Location where libvirt driver will store snapshots '
'before uploading them to image service'),
+ cfg.StrOpt('xen_hvmloader_path',
+ default='/usr/lib/xen/boot/hvmloader',
+ help='Location where the Xen hvmloader is kept'),
]
CONF = cfg.CONF
@@ -1721,7 +1724,7 @@ class LibvirtDriver(driver.ComputeDriver):
guest.os_type = vm_mode.HVM
if CONF.libvirt_type == "xen" and guest.os_type == vm_mode.HVM:
- guest.os_loader = '/usr/lib/xen/boot/hvmloader'
+ guest.os_loader = CONF.xen_hvmloader_path
if CONF.libvirt_type == "lxc":
guest.os_type = vm_mode.EXE