Updated Branches: refs/heads/master 8350a6bd4 -> 56129c30a
Fix a situation where the systemvm-vdi would be created even if the systemvm.iso does not exist. Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/56129c30 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/56129c30 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/56129c30 Branch: refs/heads/master Commit: 56129c30a9d56d3227d156a7c1d3b2122e2591ac Parents: 8cfafbe Author: Hugo Trippaers <[email protected]> Authored: Tue Oct 15 14:02:40 2013 +0200 Committer: Hugo Trippaers <[email protected]> Committed: Tue Oct 15 14:04:34 2013 +0200 ---------------------------------------------------------------------- scripts/vm/hypervisor/xenserver/xcposs/vmops | 3 +++ 1 file changed, 3 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/56129c30/scripts/vm/hypervisor/xenserver/xcposs/vmops ---------------------------------------------------------------------- diff --git a/scripts/vm/hypervisor/xenserver/xcposs/vmops b/scripts/vm/hypervisor/xenserver/xcposs/vmops index c5a9f94..20725e4 100644 --- a/scripts/vm/hypervisor/xenserver/xcposs/vmops +++ b/scripts/vm/hypervisor/xenserver/xcposs/vmops @@ -1389,6 +1389,9 @@ def setDNATRule(session, args): @echo def createISOVHD(session, args): + # Should not create the VDI if the systemvm.iso does not exist + if not os.path.exists('/usr/share/xcp/packages/iso/systemvm.iso'): + return "Failed" #hack for XCP on ubuntu 12.04, as can't attach iso to a vm vdis = session.xenapi.VDI.get_by_name_label("systemvm-vdi"); util.SMlog(vdis)
