All new accounts created on Gitlab now require administrator approval. If you invite any collaborators, please let Flux staff know so they can approve the accounts.

Commit b64b6349 authored by Leigh B. Stoller's avatar Leigh B. Stoller

Change the ipfw pipe numbers to per-physnode counters instead of a

global counter (with the increment I was using, the rule number
could easily go past the max (65535) number (and why is the max a
short anyway)) with very large experiments.
parent 9f6fbfb1
...@@ -1255,8 +1255,6 @@ while (my ($vname,$vnode) = $virt_agents->fetchrow_array()) { ...@@ -1255,8 +1255,6 @@ while (my ($vname,$vnode) = $virt_agents->fetchrow_array()) {
" vname='$vname' and vnode='$vnode'"); " vname='$vname' and vnode='$vnode'");
} }
my $pipeid = 100;
foreach $delayid (keys(%nodedelays)) { foreach $delayid (keys(%nodedelays)) {
# So r* indicates int1->int0 and others are int0->int1 # So r* indicates int1->int0 and others are int0->int1
my ($pnode,$int0,$int1,$vname, my ($pnode,$int0,$int1,$vname,
...@@ -1264,9 +1262,8 @@ foreach $delayid (keys(%nodedelays)) { ...@@ -1264,9 +1262,8 @@ foreach $delayid (keys(%nodedelays)) {
$member1,$rdelay,$rbandwidth,$rlossrate) = @{$nodedelays{$delayid}}; $member1,$rdelay,$rbandwidth,$rlossrate) = @{$nodedelays{$delayid}};
# ipfw pipe number so we can control it remotely. # ipfw pipe number so we can control it remotely.
my $pipe0 = $pipeid; my $pipe0 = physnodenextpipe($pnode);
my $pipe1 = $pipeid + 10; my $pipe1 = physnodenextpipe($pnode);
$pipeid += 100;
my ($vnode0) = split(":", $member0); my ($vnode0) = split(":", $member0);
my ($vnode1) = split(":", $member1); my ($vnode1) = split(":", $member1);
...@@ -1409,9 +1406,8 @@ foreach $delayid (keys(%linkdelays)) { ...@@ -1409,9 +1406,8 @@ foreach $delayid (keys(%linkdelays)) {
$rdelay,$rbandwidth,$rlossrate,$islan) = @{$linkdelays{$delayid}}; $rdelay,$rbandwidth,$rlossrate,$islan) = @{$linkdelays{$delayid}};
# ipfw pipe numbers so we can control it remotely. # ipfw pipe numbers so we can control it remotely.
my $pipe = $pipeid; my $pipe = physnodenextpipe($pnode);
my $rpipe = $pipeid + 10; my $rpipe = physnodenextpipe($pnode);
$pipeid += 100;
my $ip = $ips{$member}; my $ip = $ips{$member};
my ($vnode) = split(":", $member); my ($vnode) = split(":", $member);
...@@ -3252,6 +3248,7 @@ sub LoadPhysNode($) ...@@ -3252,6 +3248,7 @@ sub LoadPhysNode($)
# Pnodes start in "reboot" state. # Pnodes start in "reboot" state.
# #
$rowref->{"__reuse"} = "reboot"; $rowref->{"__reuse"} = "reboot";
$rowref->{"__pipeno"} = "100";
} }
return $phys_nodes{$pnode}; return $phys_nodes{$pnode};
} }
...@@ -3311,6 +3308,7 @@ sub physnodesetvnode($$) { return $phys_nodes{$_[0]}->{"__vname"} = $_[1]; } ...@@ -3311,6 +3308,7 @@ sub physnodesetvnode($$) { return $phys_nodes{$_[0]}->{"__vname"} = $_[1]; }
sub physnodevnode($$) { return $phys_nodes{$_[0]}->{"__vname"}; } sub physnodevnode($$) { return $phys_nodes{$_[0]}->{"__vname"}; }
sub physnodereuse($) { return $phys_nodes{$_[0]}->{"__reuse"}; } sub physnodereuse($) { return $phys_nodes{$_[0]}->{"__reuse"}; }
sub physnodesetreuse($$) { return $phys_nodes{$_[0]}->{"__reuse"} = $_[1]; } sub physnodesetreuse($$) { return $phys_nodes{$_[0]}->{"__reuse"} = $_[1]; }
sub physnodenextpipe($) { return $phys_nodes{$_[0]}->{"__pipeno"} += 10; }
# #
# Load current resources. We pull in the phys node entries now. # Load current resources. We pull in the phys node entries now.
......
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