aboutsummaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
authorKris Kennaway <kris@FreeBSD.org>2006-02-15 07:48:53 +0000
committerKris Kennaway <kris@FreeBSD.org>2006-02-15 07:48:53 +0000
commit6d04ba603f158cff9df737525d4a62863d34e8ab (patch)
tree53735dcfa087d848c61faf2cb02e65a72107f75c /Tools
parentaf8d1f0fc373500f3d8041dd27b25fad268d7604 (diff)
downloadports-6d04ba603f158cff9df737525d4a62863d34e8ab.tar.gz
ports-6d04ba603f158cff9df737525d4a62863d34e8ab.zip
Notes
Diffstat (limited to 'Tools')
-rwxr-xr-xTools/portbuild/scripts/reportload15
1 files changed, 14 insertions, 1 deletions
diff --git a/Tools/portbuild/scripts/reportload b/Tools/portbuild/scripts/reportload
index 911b08fa38ff..42d5e72eaa80 100755
--- a/Tools/portbuild/scripts/reportload
+++ b/Tools/portbuild/scripts/reportload
@@ -11,6 +11,19 @@ if [ -f ${pb}/${arch}/portbuild.$(hostname) ]; then
. ${pb}/${arch}/portbuild.$(hostname)
fi
-num=$(echo $(ls -1d ${scratchdir}/*/chroot/*/used 2>/dev/null| wc -l))
+# Look for exceptional conditions
+error=0
+for i in squid disk; do
+ if [ -f ${scratchdir}/.${i} ]; then
+ error=1
+ fi
+done
+
+if [ ${error} = 0 ]; then
+ num=$(echo $(ls -1d ${scratchdir}/*/chroot/*/used 2>/dev/null| wc -l))
+else
+ num=ERR
+fi
+
echo -n "$num "
uptime