Commit 4c25d77e authored by Dan Reading's avatar Dan Reading
Browse files

Output to log file for testbed population

parent bacfad6c
......@@ -38,7 +38,11 @@ initlogs () {
funcdebug $FUNCNAME:$LINENO enter $@
logfile=${1-"/tmp/nodecheck.log"}
logfile4tb=${2-""}
# start XXX XXX should be "" when in production
# logfile4tb=${2-""}
logfile4tb=${2-"/tmp/nodecheck.log.tb"}
touch ${logfile4tb}
# end XXX XXX
tmplog=/tmp/.$$.log ; cat /dev/null > ${tmplog} # create and truncate
logout=/tmp/.$$logout.log ; touch ${logout} # make it exist
......
......@@ -32,7 +32,8 @@ BEGIN { require "/etc/emulab/paths.pm"; import emulabpaths; }
#LINUX
@checkscripts = ("disk", "cpu", "mem", "time", "nic", "diskspeed");
#@checkscripts = ("disk", "cpu", "mem", "time", "nic", "diskspeed");
@checkscripts = ("disk", "cpu", "mem", "time", "nic");
system("echo 'Running nodechecks'");
......
......@@ -23,7 +23,8 @@ if [ -e "/var/emulab/boot/realname" ]; then
host=$(cat /var/emulab/boot/realname)
fi
checks="disk cpu mem time nic diskspeed"
#checks="disk cpu mem time nic diskspeed"
checks="disk cpu mem time nic"
echo "Running nodechecks"
# truncate file at boot time
......@@ -35,7 +36,7 @@ if [ "$1" = "boot" ] ; then
/usr/local/bin/bash /usr/local/etc/emulab/${i}check /var/emulab/logs/nodecheck.log /tmp/nodecheck.log.tb
done
$(echo "-- Finish boot_time_node_check --" >> /var/emulab/logs/nodecheck.log)
if [ -e /tmp/nodecheck.log.tb ] ; then
if [ -f /tmp/nodecheck.log.tb ] ; then
cp /tmp/nodecheck.log.tb /proj/emulab-ops/nodecheck/$host
fi
else
......
Supports Markdown
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