Experiment ". "$pid/". "$eid\n"; # # We run this twice. The first time we are checking for a confirmation # by putting up a form. The next time through the confirmation will be # set. Or, the user can hit the cancel button (see above). # if (!$confirmed) { echo "

Confirming this operation will initiate various updates to be performed, including updating the password and group files, adding new mounts, and installing (or updating if modified) tarballs and rpms. This is sometimes quicker and easier than rebooting nodes.\n"; echo "


Are you sure you want to perform an update on "; if (isset($nodeid)) { echo "node $nodeid in experiment '$eid?'\n"; } else { echo "all of the nodes in experiment '$eid?'\n"; } echo "

\n"; if (isset($nodeid)) { SHOWNODE($nodeid, SHOWNODE_SHORT); } else { SHOWEXP($pid, $eid, 1); } echo "
"; echo "\n"; echo "\n"; if (isset($nodeid)) { echo "\n"; } echo "
\n"; echo "
\n"; echo "
NOTE that this operation will consume a small number of CPU cycles on each node. If this would disturb an experiment in progress, you should cancel this operation until later. Please note that accounts are automatically updated whenever a node reboots, or when an experiment is swapped back in.\n"; PAGEFOOTER(); return; } # # We need the unix gid for the project for running the scripts below. # Note usage of default group in project. # TBGroupUnixInfo($pid, $gid, $unix_gid, $unix_name); # # Start up a script to do this. # echo "

"; echo "

Starting node update. Please wait a moment ...

"; flush(); $retval = SUEXEC($uid, "$pid,$unix_gid", "webnodeupdate -b $pid $eid" . (isset($nodeid) ? " $nodeid" : ""), SUEXEC_ACTION_IGNORE); # # Fatal Error. Report to the user, even though there is not much he can # do with the error. Also reports to tbops. # if ($retval < 0) { SUEXECERROR(SUEXEC_ACTION_DIE); # # Never returns ... # die(""); } # # Exit status 0 means the operation is proceeding in the background. # echo "
\n"; if ($retval) { echo "

Node update could not proceed

"; echo "
$suexec_output
"; } else { echo "You will be notified via email when the update has completed on all of the nodes in your experiment. This might take a just a few minutes (if updating only accounts) or it might take longer if new tar/rpm files need to be installed. In the meantime, the experiment is locked it may not be swapped or modified.\n"; echo "

If you do not receive email notification within a reasonable amount of time, please contact $TBMAILADDR.\n"; } # # Standard Testbed Footer # PAGEFOOTER(); ?>