Commit fc80556a authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Modernize.

parent 610bfaad
...@@ -55,9 +55,13 @@ sub Install($$$) ...@@ -55,9 +55,13 @@ sub Install($$$)
PhaseFail("Could not look up XEN-STD osid") PhaseFail("Could not look up XEN-STD osid")
if (!defined($osinfo)); if (!defined($osinfo));
my $nextosinfo = OSinfo->LookupByName($XENIMAGE); my $parentosinfo = OSinfo->LookupByName($XENIMAGE);
PhaseFail("Could not look up $XENIMAGE osid") PhaseFail("Could not look up $XENIMAGE osid")
if (!defined($nextosinfo)); if (!defined($parentosinfo));
my $nextosinfo = OSinfo->LookupByName($images[0]);
PhaseFail("Could not look up " . $images[0] . " osid")
if (!defined($parentosinfo));
my $diskload_osinfo = OSinfo->LookupByName("FRISBEE-MFS-PCVM"); my $diskload_osinfo = OSinfo->LookupByName("FRISBEE-MFS-PCVM");
PhaseFail("Could not look up FRISBEE-MFS-PCVM osid") PhaseFail("Could not look up FRISBEE-MFS-PCVM osid")
...@@ -74,9 +78,9 @@ sub Install($$$) ...@@ -74,9 +78,9 @@ sub Install($$$)
Phase "xenosid", "Updating the XEN-STD osid", sub { Phase "xenosid", "Updating the XEN-STD osid", sub {
$osinfo->SetNextOS($nextosinfo) == 0 $osinfo->SetNextOS($nextosinfo) == 0
or PhaseFail("Could not set the nextosid for XEN-STD"); or PhaseFail("Could not set the nextosid for XEN-STD");
$osinfo->SetParentOS($nextosinfo) == 0 $osinfo->SetParentOS($parentosinfo) == 0
or PhaseFail("Could not set the parent osid for XEN-STD"); or PhaseFail("Could not set the parent osid for XEN-STD");
$osinfo->SetRunsOnParent($nextosinfo) == 0 $osinfo->SetRunsOnParent($parentosinfo) == 0
or PhaseFail("Could not add os_submap entry for XEN-STD"); or PhaseFail("Could not add os_submap entry for XEN-STD");
}; };
...@@ -100,9 +104,9 @@ sub Install($$$) ...@@ -100,9 +104,9 @@ sub Install($$$)
$image->SetRunsOnNodeType("pcvm") == 0 $image->SetRunsOnNodeType("pcvm") == 0
or PhaseFail("Could not set $imagename to run on pcvm"); or PhaseFail("Could not set $imagename to run on pcvm");
# This must be first. # This must be first.
$osinfo->SetParentOS($nextosinfo) == 0 $osinfo->SetParentOS($parentosinfo) == 0
or PhaseFail("Could not set $imagename parent os"); or PhaseFail("Could not set $imagename parent os");
$osinfo->SetRunsOnParent($nextosinfo) == 0 $osinfo->SetRunsOnParent($parentsinfo) == 0
or PhaseFail("Could not set $imagename to run on parent"); or PhaseFail("Could not set $imagename to run on parent");
}; };
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment