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

Back out previous revison cause it was the wrong file.

parent adf76aef
......@@ -16,7 +16,7 @@ use Fcntl ':flock';
# Drag in path stuff so we can find emulab stuff. Also untaints path.
BEGIN { require "/etc/emulab/paths.pm"; import emulabpaths; }
use libsetup qw(REMOTE LOCALROOTFS TMTOPOMAP TBDebugTimeStamp);
use libsetup qw(REMOTE LOCALROOTFS TBDebugTimeStamp);
use libtmcc;
#
......@@ -325,26 +325,9 @@ TBDebugTimeStamp("mkjail tmcc proxy is running");
#
$jailpid = fork();
if ($jailpid) {
#
# We do not really care about the exit status of the jail. We want to catch
# any children, which includes the tmcc proxy. If it dies, something has
# gone wrong, and that appears to happen a lot. Lets restart it until we
# figure out what is going wrong.
#
while (1) {
my $kidpid = waitpid(-1, 0);
if ($kidpid == $jailpid) {
undef($jailpid);
last;
}
if ($kidpid == $tmccpid) {
print("TMCC proxy exited with status $?. Restarting ...\n");
startproxy("$JAILPATH/$vnodeid");
next;
}
print("Unknown child $kidpid exited with status $?!\n");
}
# We do not really care about the exit status of the jail.
waitpid($jailpid, 0);
undef($jailpid);
}
else {
$SIG{TERM} = 'DEFAULT';
......@@ -536,9 +519,6 @@ sub mkrootfs($)
TBDebugTimeStamp("mkjail copying the tmcc cache");
tmcccopycache($vnodeid, "$path/root");
if (-e TMTOPOMAP()) {
mysystem("cp -fp " . TMTOPOMAP() . " $path/root/var/emulab/boot");
}
#
# Stash the control net IP if not the same as the host IP
......@@ -705,9 +685,6 @@ sub restorerootfs($)
}
tmcccopycache($vnodeid, "$path/root");
if (-e TMTOPOMAP()) {
mysystem("cp -fp " . TMTOPOMAP() . " $path/root/var/emulab/boot");
}
#
# The proc FS in the jail is per-jail of course.
......@@ -803,7 +780,6 @@ sub startproxy($)
{
my ($dir) = @_;
my $log = "$dir/tmcc.log";
my $klog = "$dir/tmcc.ktrace";
#
# The point of these paths is so that there is a comman path to
......@@ -834,7 +810,7 @@ sub startproxy($)
# The -o option will cause the proxy to detach but not fork!
# Eventually change this to standard pid file kill.
exec("ktrace -i -a -f $klog $TMCC -d -x $outsidepath -n $vnodeid -o $log");
exec("$TMCC -d -x $outsidepath -n $vnodeid -o $log");
die("Exec of $TMCC failed! $!\n");
}
......
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