Commit 53a11517 authored by Shashi Guruprasad's avatar Shashi Guruprasad

Merge all files except ipassign (done in a separate commit)

from commvirtsig-branch into main trunk

Two testsuite tests fail: tbcmd and vtypes . Need to fix.
parent 67e2c8c5
......@@ -22,6 +22,7 @@ use vars qw(@ISA @EXPORT);
@ISA = "Exporter";
@EXPORT =
qw ( NODERELOADING_PID NODERELOADING_EID NODEDEAD_PID NODEDEAD_EID
OLDRESERVED_PID OLDRESERVED_EID
NODEBOOTSTATUS_OKAY NODEBOOTSTATUS_FAILED NODEBOOTSTATUS_UNKNOWN
NODESTARTSTATUS_NOSTATUS PROJMEMBERTRUST_NONE PROJMEMBERTRUST_USER
PROJMEMBERTRUST_ROOT PROJMEMBERTRUST_GROUPROOT
......@@ -142,10 +143,10 @@ use vars qw(@ISA @EXPORT);
TBAdmin TBProjAccessCheck TBNodeAccessCheck TBOSIDAccessCheck
TBImageIDAccessCheck TBExptAccessCheck ExpLeader MarkNodeDown
SetNodeBootStatus OSFeatureSupported IsShelved NodeidToExp
SetNodeBootStatus OSFeatureSupported IsShelved NodeidToExp NodeidToExpOldReserved
UserDBInfo DBQuery DBQueryFatal DBQueryWarn DBWarn DBFatal
DBQuoteSpecial UNIX2DBUID ExpState SetExpState ProjLeader
ExpNodes DBDateTime DefaultImageID GroupLeader TBGroupUnixInfo
ExpNodes ExpNodesOldReserved DBDateTime DefaultImageID GroupLeader TBGroupUnixInfo
TBValidNodeLogType TBValidNodeName TBSetNodeLogEntry
TBSetSchedReload MapNodeOSID TBLockExp TBUnLockExp TBSetExpSwapTime
TBUnixGroupList TBOSID TBOSMaxConcurrent TBOSCountInstances
......@@ -294,6 +295,8 @@ sub PLABMOND_PID() { $TBOPSPID; }
sub PLABMOND_EID() { "plab-monitor"; }
sub PLABHOLDING_PID() { $TBOPSPID; }
sub PLABHOLDING_EID() { "plabnodes"; }
sub OLDRESERVED_PID() { $TBOPSPID; }
sub OLDRESERVED_EID() { "oldreserved"; }
sub PROJROOT() { $PROJROOT; }
sub GROUPROOT() { $GROUPROOT; }
sub USERROOT() { $USERROOT; }
......@@ -1444,6 +1447,53 @@ sub TBGetCancelFlag($$$)
return 1;
}
#
# Return a list of all the nodes in an experiment
# that were moved to OLDRESERVED_PID/OLDRESERVED_EID
# holding reservation
#
# usage: ExpNodesOldReserved(char *pid, char *eid)
# returns the list if a valid pid/eid.
# returns 0 if an invalid pid/eid or if an error.
#
sub ExpNodesOldReserved($$)
{
my($pid, $eid) = @_;
my(@row);
my(@nodes);
my $oldreserved_pid = OLDRESERVED_PID;
my $oldreserved_eid = OLDRESERVED_EID;
my $query_result =
DBQueryWarn("select r.node_id from reserved as r ".
"left join nodes as n on n.node_id=r.node_id ".
"left join node_types as nt on nt.type=n.type ".
"where (r.pid='$oldreserved_pid' and r.old_pid='$pid') ".
"and (r.pid='$oldreserved_eid' and r.old_eid='$eid') ");
if (! $query_result or
$query_result->numrows == 0) {
return ();
}
while (@row = $query_result->fetchrow_array()) {
my $node = $row[0];
#
# Taint check. I do not understand this sillyness, but if I
# taint check these node names, I avoid warnings throughout.
#
if ($node =~ /^([-\w]+)$/) {
$node = $1;
push(@nodes, $node);
}
else {
print "*** $0: WARNING: Bad node name: $node.\n";
}
}
return @nodes;
}
#
# Return a list of all the nodes in an experiment.
#
......@@ -1627,6 +1677,34 @@ sub IsShelved ($;$$) {
return 0;
}
#
# Map nodeid to its pid/eid in the oldreserved holding reservation
#
# usage: NodeidToExpOldReserved(char *nodeid, \$pid, \$eid, \$vname)
# returns 1 if the node is reserved.
# returns 0 if the node is not reserved.
#
sub NodeidToExpOldReserved ($$$) {
my($nodeid, $pid, $eid) = @_;
my $oldreserved_pid = OLDRESERVED_PID;
my $oldreserved_eid = OLDRESERVED_EID;
my $query_result =
DBQueryWarn("select old_pid,old_eid from reserved ".
"where node_id='$nodeid' and pid='$oldreserved_pid' ".
"and eid='$oldreserved_eid'");
if (! $query_result ||
! $query_result->num_rows) {
return 0;
}
my @row = $query_result->fetchrow_array();
$$pid = $row[0];
$$eid = $row[1];
return 1;
}
#
# Map nodeid to its pid/eid/vname. vname is optional.
#
......
......@@ -52,6 +52,8 @@ my $eid = shift;
my @node_names=@ARGV;
my @vals = ();
my @nodes= ();
my $oldreserved_pid = OLDRESERVED_PID;
my $oldreserved_eid = OLDRESERVED_EID;
if ($debug) { print "Expt '$eid', proj '$pid'\n"; }
......@@ -102,11 +104,16 @@ foreach my $n (@node_names) {
if (($r_pid eq $pid) && ($r_eid eq $eid)) {
print "You have already reserved node '$n'.\n";
# Do not increment error code since that throws off tbprerun.
next;
} elsif(NodeidToExpOldReserved($n, \$r_pid, \$r_eid) &&
(($r_pid eq $pid) && ($r_eid eq $eid)) ) {
print "You have already reserved node '$n' which was moved to ".
"a holding reservation: $oldreserved_pid/$oldreserved_eid.\n";
} else {
print "Someone else has already reserved node '$n'.\n";
$noalloc++;
next;
}
next; # Go on to the next node if this one is reserved
}
my $result = DBQueryFatal("select * from nodes where node_id='$n'");
......@@ -130,7 +137,7 @@ foreach my $n (@node_names) {
# End shark hack
} else {
# its not a shark - just add it in...
push(@vals,"('$n','$pid','$eid','$n')");
push(@vals,"('$n','$pid','$eid','$n','','')");
push(@nodes,"$n");
}
}
......@@ -156,7 +163,7 @@ if (!$error && (!$noalloc || $partial) && @vals) {
if ($debug) {
print "Reserving nodes...\n";
}
$cmd = "insert into reserved (node_id,pid,eid,vname) values ".
$cmd = "replace into reserved (node_id,pid,eid,vname,old_pid,old_eid) values ".
join(",",@vals);
if (!DBQueryWarn($cmd)) {
$error++;
......
......@@ -17,10 +17,11 @@ use Getopt::Std;
#
sub usage ()
{
die("Usage: nfree [-x] <pid> <eid> [<node> <node> <...>]\n".
die("Usage: nfree [-x] [-o] <pid> <eid> [<node> <node> <...>]\n".
"Releases all nodes in the specified experiment.\n".
"If nodes are listed, nfree releases only those nodes.\n".
" '-x' frees all virtual nodes on any physical node that gets freed.\n"
" '-x' frees all virtual nodes on any physical node that gets freed.\n".
" '-o' Moves nodes into a oldreserved holding experiment.\n"
);
}
......@@ -38,6 +39,8 @@ my $osselect = "$TB/bin/os_select";
my $reloadpid = "emulab-ops";
my $pendingeid = "reloadpending";
my $reloadeid = "reloading";
my $oldreserved_pid = OLDRESERVED_PID;
my $oldreserved_eid = OLDRESERVED_EID;
my @nodes;
my @freed_nodes=();
......@@ -53,7 +56,7 @@ delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
# Parse command arguments. Once we return from getopts, all that should
# left are the required arguments.
#
my $optlist = "x";
my $optlist = "xo";
%options = ();
......@@ -62,10 +65,14 @@ if (! getopts($optlist, \%options)) {
}
my $freeDependantVirtuals = 0;
my $moveToOldReserved = 0;
if (defined($options{"x"})) {
$freeDependantVirtuals = 1;
}
if (defined($options{"o"})) {
$moveToOldReserved = 1;
}
if (@ARGV < 2) {
usage();
......@@ -133,6 +140,9 @@ if (@ARGV) {
} else {
print "Releasing all nodes from experiment '$eid' in project '$pid'.\n";
@nodes = ExpNodes($pid, $eid);
if (! $moveToOldReserved ) {
push( @nodes, ExpNodesOldReserved($pid, $eid) );
}
}
######################################################################
......@@ -172,20 +182,39 @@ foreach my $n (@nodes) {
next;
}
# Move to locked reservation. Node is not free, but is no longer
# owned by the pid/eid, so cannot be mucked with.
if (! DBQueryWarn("update reserved " .
"set vname='$n', pid='$reloadpid', eid='$lockedeid' ".
"where node_id='$n'")) {
print "*** WARNING: Error locking down node $n!\n";
next;
if ( $moveToOldReserved ) {
# Move to holding reservation. Node is not free, but is no longer
# owned by the pid/eid, so cannot be mucked with.
if (! DBQueryWarn("update reserved " .
"set vname='$n', pid='$oldreserved_pid', ".
"eid='$oldreserved_eid', old_pid='$pid', ".
"old_eid='$eid' where node_id='$n'")) {
print "*** WARNING: Error moving node $n to holding pid/eid: ".
"$oldreserved_pid/$oldreserved_eid\n";
next;
}
} else {
# Move to locked reservation. Node is not free, but is no longer
# owned by the pid/eid, so cannot be mucked with.
if (! DBQueryWarn("update reserved " .
"set vname='$n', pid='$reloadpid', eid='$lockedeid', ".
"old_pid='', old_eid='' ".
"where node_id='$n'")) {
print "*** WARNING: Error locking down node $n!\n";
next;
}
push(@freed_nodes, $n);
}
push(@freed_nodes, $n);
}
DBQueryFatal("unlock tables");
# We are done if called with a -o
if( $moveToOldReserved ) {
exit($error);
}
######################################################################
# Step 2
#
......
......@@ -77,10 +77,13 @@ my %experiment_fields = ("multiplex_factor" => 1,
"wa_plr_solverweight" => 1,
"cpu_usage" => 1,
"mem_usage" => 1,
"allowfixnode" => 1,
"veth_encapsulate" => 1,
"jail_osname" => 1,
"delay_osname" => 1,
"sync_server" => 1);
"sync_server" => 1,
"use_ipassign" => 1,
"ipassign_args" => 1);
#
# Turn off line buffering on output
......@@ -227,7 +230,7 @@ sub readXML($$$) {
$count += scalar(@{$virtual_tables{$table}})
if (defined($virtual_tables{$table}));
}
if ($count > 10000) {
if ($count > 100000) {
fatal("Too many rows of data!");
}
......
......@@ -39,7 +39,8 @@ my $TB = "@prefix@";
"readycount" => "$TB/bin/readycount",
"eventsys_control" => "$TB/bin/eventsys_control",
"batchexp" => "$TB/bin/batchexp",
"nscheck" => "$TB/bin/nscheck"
"nscheck" => "$TB/bin/nscheck",
"swapexp" => "$TB/bin/swapexp",
);
# Need to provide a simple path, because some scripts we call need one
......
This diff is collapsed.
......@@ -213,6 +213,12 @@ namespace eval GLOBALS {
# The name of the sync_server
variable sync_server {}
# Whether or not use use ipassign
variable use_ipassign 0
# Arguments to pass to ipassign
variable ipassign_args {}
# For remote nodes. The solver weights.
variable wa_delay_solverweight 1
variable wa_bw_solverweight 7
......@@ -230,6 +236,9 @@ namespace eval GLOBALS {
variable cpu_usage 3
variable mem_usage 0
# Flag to disable doing a fix-node
variable fix_current_resources 1
# Control veth encapsulation
variable veth_encapsulate 1
......
......@@ -245,8 +245,11 @@ Simulator instproc run {} {
var_import ::GLOBALS::forcelinkdelays
var_import ::GLOBALS::multiplex_factor
var_import ::GLOBALS::sync_server
var_import ::GLOBALS::use_ipassign
var_import ::GLOBALS::ipassign_args
var_import ::GLOBALS::cpu_usage
var_import ::GLOBALS::mem_usage
var_import ::GLOBALS::fix_current_resources
var_import ::GLOBALS::veth_encapsulate
var_import ::GLOBALS::jail_osname
var_import ::GLOBALS::delay_osname
......@@ -254,8 +257,10 @@ Simulator instproc run {} {
var_import ::TBCOMPAT::eventtypes
# Fill out IPs
foreach obj [concat [array names lanlink_list]] {
$obj fill_ips
if {! $use_ipassign } {
foreach obj [concat [array names lanlink_list]] {
$obj fill_ips
}
}
# Go through the list of nodes, and find subnode hosts - we have to add a
......@@ -336,8 +341,8 @@ Simulator instproc run {} {
$prog updatedb "sql"
}
set fields [list "mem_usage" "cpu_usage" "forcelinkdelays" "uselinkdelays" "usewatunnels" "uselatestwadata" "wa_delay_solverweight" "wa_bw_solverweight" "wa_plr_solverweight" "veth_encapsulate"]
set values [list $mem_usage $cpu_usage $forcelinkdelays $uselinkdelays $usewatunnels $uselatestwadata $wa_delay_solverweight $wa_bw_solverweight $wa_plr_solverweight $veth_encapsulate]
set fields [list "mem_usage" "cpu_usage" "forcelinkdelays" "uselinkdelays" "usewatunnels" "uselatestwadata" "wa_delay_solverweight" "wa_bw_solverweight" "wa_plr_solverweight" "veth_encapsulate" "allowfixnode"]
set values [list $mem_usage $cpu_usage $forcelinkdelays $uselinkdelays $usewatunnels $uselatestwadata $wa_delay_solverweight $wa_bw_solverweight $wa_plr_solverweight $veth_encapsulate $fix_current_resources]
if { $multiplex_factor != {} } {
lappend fields "multiplex_factor"
......@@ -352,6 +357,14 @@ Simulator instproc run {} {
lappend values $default_sync_server
}
lappend fields "use_ipassign"
lappend values $use_ipassign
if { $ipassign_args != {} } {
lappend fields "ipassign_args"
lappend values $ipassign_args
}
if { $jail_osname != {} } {
lappend fields "jail_osname"
lappend values $jail_osname
......
......@@ -652,6 +652,25 @@ proc tb-set-sync-server {node} {
set sync_server $node
}
#
# Turn on or of the ipassign program for IP address assignment and route
# calculation
#
proc tb-use-ipassign {onoff} {
var_import ::GLOBALS::use_ipassign
set use_ipassign $onoff
}
#
# Give arguments for ipassign
#
proc tb-set-ipassign-args {stuff} {
var_import ::GLOBALS::ipassign_args
set ipassign_args $stuff
}
#
# Set the startup command for a node. Replaces the tb-set-node-startup
# command above, but we have to keep that one around for a while. This
......@@ -699,6 +718,17 @@ proc tb-bind-parent {sub phys} {
tb-fix-node $sub $phys
}
proc tb-fix-current-resources {onoff} {
var_import ::GLOBALS::fix_current_resources
if {$onoff != 0 && $onoff != 1} {
perror "\[tb-fix-current-resources] $onoff must be 0/1"
return
}
set fix_current_resources $onoff
}
#
# Control veth encapsulation.
#
......
......@@ -67,6 +67,7 @@ my $dbg = 0;
my $failed = 0;
my $failedvnodes= 0;
my $failedplab = 0;
my $canceled = 0;
my %nodes = ();
my %vnodes = ();
my %vnodephosts = ();
......@@ -207,9 +208,13 @@ while (my %row = $db_result->fetchhash()) {
TBGetNodeAllocState( $node, \$nodeAllocState );
$nodes{$node} = $node;
$nodeAllocStates{$node} = $nodeAllocState;
# only reboot node if assign_wrapper just pulled it into expt.
# (e.g. it isnt ALLOCSTATE_RES_READY)
if ($nodeAllocState ne TBDB_ALLOCSTATE_RES_READY()) {
if ($nodeAllocState eq TBDB_ALLOCSTATE_RES_RECONFIG()) {
# Terrible use of state machine.
$reconfigs{$node} = 1;
}
elsif ($nodeAllocState ne TBDB_ALLOCSTATE_RES_READY()) {
# only reboot node if assign_wrapper just pulled it into expt.
# (e.g. it isnt ALLOCSTATE_RES_READY)
$reboots{$node} = 1;
}
}
......@@ -469,8 +474,9 @@ if (!$TESTMODE) {
foreach my $node (@list) {
TBSetNodeAllocState( $node, TBDB_ALLOCSTATE_RES_RELOAD() );
$nodeAllocStates{$node} = TBDB_ALLOCSTATE_RES_RELOAD();
# No point in rebooting, obviously, but it does reboot!
# No point in reboot/reconfig obviously, since node will reboot!
delete $reboots{$node};
delete $reconfigs{$node};
$rebooted{$node} = 1;
}
......@@ -479,6 +485,9 @@ if (!$TESTMODE) {
ForkCmd("$os_load -m $imageid @list");
}
#
# Fire off the reboots.
#
if (keys(%reboots)) {
foreach my $node (keys(%reboots)) {
if ($nodeAllocStates{$node} eq TBDB_ALLOCSTATE_RES_INIT_CLEAN()) {
......@@ -497,30 +506,10 @@ if (!$TESTMODE) {
}
#
# Any nodes that were not reloaded or rebooted, get a reconfig. They
# must have been in the experiment before, but we check the allocstate
# anyway.
# Fire off the reconfigs.
#
foreach my $node (keys(%nodes)) {
next
if (exists($rebooted{$node}) ||
$nodeAllocStates{$node} ne TBDB_ALLOCSTATE_RES_READY());
# Currently, only do this for NORMALv2 images. Need a way to
# know this is allowed!
my $mode;
if (!TBGetNodeOpMode($node, \$mode)) {
print "*** Error getting operational mode for $node!\n";
next;
}
next
if ($mode ne "NORMALv2");
$reconfigs{$node} = $node;
}
if (keys(%reconfigs)) {
$cmd = "$nodereboot -r -d " . join(" ", keys(%reconfigs));
$cmd = "$nodereboot -r " . join(" ", keys(%reconfigs));
$pids{$cmd} = ForkCmd($cmd);
}
......@@ -598,7 +587,19 @@ while ( @nodelist ) {
next;
}
if ($retries{$node}) {
#
# Check for cancelation. Do not want to retry the reboots if the
# swap was canceled.
#
if (!$canceled) {
TBGetCancelFlag($pid, $eid, \$canceled);
if ($canceled) {
print "*** Swap canceled; will terminate os_setup early!\n";
}
}
if ($retries{$node} && !$canceled) {
$retries{$node} -= 1;
print "*** Rebooting $node and waiting again ...\n";
......@@ -694,7 +695,10 @@ foreach my $vnode (@vnodelist) {
# XXX - Don't bother if something above failed. A waste of time and
# usually leads to cascading errors.
#
if ($failed && @vnodelist) {
if ($canceled && @vnodelist) {
print "*** Skipping virtual node setup since swapin was canceled!\n";
}
elsif ($failed && @vnodelist) {
print "*** Skipping virtual node setup since there were previous ".
"failures!\n";
}
......@@ -799,7 +803,7 @@ TBDebugTimeStamp("os_setup finished");
# No retry if vnodes failed. Indicates a fatal problem.
exit(-1)
if ($failedvnodes);
if ($failedvnodes || $canceled);
exit(1)
if ($failed || $failedplab);
exit 0;
......
......@@ -229,7 +229,8 @@ if (defined($exempt_eid)) {
$result =
DBQueryFatal("select a.node_id,a.type,a.phys_nodeid,t.class,t.issubnode," .
"a.def_boot_osid from nodes as a ".
"a.def_boot_osid, (b.pid is not null and b.eid is not null) " .
"from nodes as a ".
"left join reserved as b on a.node_id=b.node_id ".
"left join reserved as m on a.phys_nodeid=m.node_id ".
"left join nodes as np on a.phys_nodeid=np.node_id ".
......@@ -243,7 +244,7 @@ $result =
# to use all nodes), or if there is no entry in the perms table for
# the type/class of node.
#
while (($node,$type,$physnode,$class,$issubnode,$def_boot_osid)
while (($node,$type,$physnode,$class,$issubnode,$def_boot_osid,$reserved)
= $result->fetchrow_array) {
$nodes{$node} = $type
if (!defined($pid) ||
......@@ -252,6 +253,12 @@ while (($node,$type,$physnode,$class,$issubnode,$def_boot_osid)
$subnode_of{$node} = $physnode;
}
$node_def_boot_osid{$node} = $def_boot_osid;
if ($reserved) {
$is_reserved{$node} = 1;
} else {
$is_reserved{$node} = 0;
}
}
foreach $node (keys(%nodes)) {
......@@ -328,6 +335,9 @@ foreach $node (keys(%nodes)) {
push @features, "?+ram:$ram";
# This number can be use for fine-tuning packing
push @features, "?+virtpercent:100";
# Put this silly feature in so that we can try to keep vnodes
# on the same pnode they were before
push @features, "${node}:0.0";
}
if ($simstuff && $simnode_capacity > 0) {
......@@ -351,6 +361,12 @@ foreach $node (keys(%nodes)) {
push @features, @{$features{$node}};
}
# This is for the case that we are modifying an existing experiment - tell
# assign to prefer nodes the user has already allocated
if ($exempt_eid && $is_reserved{$node}) {
push(@features,"already_reserved:0");
}
#
# Handle subnodes
#
......
......@@ -150,11 +150,35 @@ system("prerender -t $pid $eid");
TBDebugTimeStamp("routes started");
print "Setting up static routes (if requested) ... \n";
if (system("staticroutes $pid $eid")) {
cleanup();
die("*** $0:\n".
" Static route calculation failed!\n");
#
# Find out which route calculator we're supposed to use
#
my $result = DBQueryWarn("select use_ipassign, ipassign_args " .
"from experiments where pid='$pid' and eid='$eid'");
if (!$result || ($result->num_rows() != 1)) {
cleanup();
die("*** $0:\n".
" Error determining route calculator!\n");
}
my ($use_ipassign, $ipassign_args) = $result->fetchrow();
if ($use_ipassign) {
if (!defined $ipassign_args) {
$ipassign_args = "";
}
if (system("ipassign_wrapper $ipassign_args $pid $eid")) {
cleanup();
die("*** $0:\n".
" Static route calculation failed!\n");
}
} else {
if (system("staticroutes $pid $eid")) {
cleanup();
die("*** $0:\n".
" Static route calculation failed!\n");
}
}
TBDebugTimeStamp("routes finished");
print "Static routing done! " . TBTimeStamp() . "\n";
......
......@@ -2,7 +2,7 @@
#
# EMULAB-COPYRIGHT
# Copyright (c) 2000-2003 University of Utah and the Flux Group.
# Copyright (c) 2000-2004 University of Utah and the Flux Group.
# All rights reserved.
#
use English;
......@@ -65,7 +65,8 @@ sub UPDATE_RECOVER() { return 0; }
$| = 1;
my $updateReboot = 0;
my $updateReboot = 0;
my $updateReconfig = 1;
my $updateEventsys_restart = 0;
my $force = 0;
my $errors = 0;
......@@ -101,6 +102,7 @@ while ($#ARGV > 1) {
$force = 1;
} elsif ($arg eq "-reboot") {
$updateReboot = 1;
$updateReconfig = 0;
} elsif ($arg eq "-eventsys_restart" && $swapop eq "update") {
$update_Eventsys_restart = 1;
} else {
......@@ -734,8 +736,9 @@ sub doSwapin($) {
# and we are successfully performing the update,
# then mark all nodes in experiment so os_setup will reboot them.
#
if (($type == UPDATE) && $updateReboot) {
print STDERR "Marking nodes for reboot.\n";
if (($type == UPDATE) &&
($updateReboot || $updateReconfig)) {
print STDERR "Marking nodes for reboot/reconfig.\n";
$db_result =
DBQueryFatal("select r.node_id,n.allocstate from reserved as r ".
"left join nodes as n on n.node_id=r.node_id ".
......@@ -749,7 +752,10 @@ sub doSwapin($) {
# does not even exist yet (plab nodes).
#
if ($allocstate ne TBDB_ALLOCSTATE_RES_INIT_CLEAN()) {
TBSetNodeAllocState($node, TBDB_ALLOCSTATE_RES_INIT_DIRTY());
TBSetNodeAllocState($node,
($updateReboot ?
TBDB_ALLOCSTATE_RES_INIT_DIRTY() :
TBDB_ALLOCSTATE_RES_RECONFIG()));
}
}
}
......
......@@ -136,9 +136,14 @@ if (! isset($go)) {
topology (adding or removing nodes, links, and LANs).
If adding/removing a delay to/from an existing link, or
replacing a lost node <i>without modifying the experiment
topology</i>, this won't be necessary.</p>";
topology</i>, this won't be necessary. Restarting the
event system is also highly recommended since the same nodes
in your virtual topology may get mapped to different physical
nodes.</p>";
echo "<input type='checkbox' name='reboot' value='1' checked='1'>
Reboot nodes in experiment (Highly Recommended)</input>";
echo "<br><input type='checkbox' name='eventrestart' value='1' checked='1'>
Restart Event System in experiment (Highly Recommended)</input>";
}
echo "<br>";
echo "<input type='hidden' name='pid' value='$pid'>";
......@@ -209,6 +214,7 @@ set_time_limit(0);
# Run the script.
$retval = SUEXEC($uid, $unix_gid,
"webswapexp $rebootswitch " . ($reboot ? "-r " : "") .
($eventrestart ? "-e " : "") .
"-s modify $pid $eid $nsfile",
SUEXEC_ACTION_IGNORE);
......
......@@ -39,7 +39,8 @@ my $TB = "@prefix@";
"readycount" => "$TB/bin/readycount",
"eventsys_control" => "$TB/bin/eventsys_control",
"batchexp" => "$TB/bin/batchexp",
"nscheck" => "$TB/bin/nscheck"
"nscheck" => "$TB/bin/nscheck",
"swapexp" => "$TB/bin/swapexp",
);
# Need to provide a simple path, because some scripts we call need one
......
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