Commit d6082d11 authored by Elijah Grubb's avatar Elijah Grubb

Merge remote-tracking branch 'origin/master' into entrypoint-bug-fix

parents f5a5b0e4 d633f6a2
......@@ -1008,9 +1008,12 @@ sub getDockerNetMemberIds($)
if ($code) {
return undef;
}
if (!ref($content) eq 'HASH') {
if (ref($content) eq 'ARRAY') {
$content = $content->[0];
}
if (ref($content) ne 'HASH') {
return undef;
}
if (!exists($content->{"Containers"})) {
return ();
}
......@@ -1760,7 +1763,7 @@ sub rootPreConfig($)
#
# If we are instead using the devicemapper direct-lvm backend,
# we need both $EXTRAFS and $INFOFS, but we also need a beefy
# thinpool for Docker. In this case, we use max(5GB,3%VG) LV
# thinpool for Docker. In this case, we use min(32GB,15%VG) LV
# for $INFOFS; use min(32GB,15%remainingVG) for the $EXTRAFS;
# then we provision the thin pool with 90% of the remaining
# space (i.e., 0.90*(totalVG - sizeof($EXTRAFS) -
......@@ -1777,11 +1780,11 @@ sub rootPreConfig($)
if (!$USE_DOCKER_LVM) {
# We will only create $EXTRAFS and $INFOFS.
if (0.03 * $remaining < 5) {
$infosize = 0.03 * $remaining;
if (0.15 * $remaining < 32) {
$infosize = 0.15 * $remaining;
}
else {
$infosize = 5;
$infosize = 32;
}
$remaining -= $infosize;
$extrasize = 0.90 * $remaining;
......@@ -1790,11 +1793,11 @@ sub rootPreConfig($)
else {
# We will create $EXTRAFS and $INFOFS, as well as the Docker
# thin pool.
if (0.03 * $remaining < 5) {
$infosize = 0.03 * $remaining;
if (0.15 * $remaining < 32) {
$infosize = 0.15 * $remaining;
}
else {
$infosize = 5;
$infosize = 32;
}
$remaining -= $infosize;
if (0.15 * $remaining < 32) {
......@@ -5594,6 +5597,14 @@ sub CreateRoutingScripts($$)
warn("Could not get router configuration from libsetup!");
return -1;
}
#
# Remove this temp file that getrouterconfig/calcroutes created as
# input for the dijkstra calculator; on a 2k-node topo, it can be
# >80MB.
#
if (-f CONFDIR() . "/linkmap") {
unlink(CONFDIR() . "/linkmap");
}
my $script = CONFDIR()."/routing.sh";
......
Markdown is supported
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