Commit d484d202 authored by Andrea Sciaba's avatar Andrea Sciaba
Browse files

ERRORs in disk space checks downgraded to WARNINGs

parent c321f342
......@@ -48,6 +48,7 @@ function check_quota {
return 0
}
warn=0
echo "Printing preliminary information..."
echo
echo -n "Sysinfo: "
......@@ -193,17 +194,17 @@ fi
space=`check_df .`
echo "WorkDirSpace: $space MB"
if [ $space -lt 10000 ] ; then
echo "ERROR: less than 10 GB of free space in working directory ."
echo "summary: WORKDIR_LOW_SPACE"
exit $SAME_ERROR
echo "WARNING: less than 10 GB of free space in working directory"
summary="summary: WORKDIR_LOW_SPACE"
warn=1
fi
space=`check_df /tmp`
echo "TmpSpace: $space MB"
if [ $space -lt 10 ] ; then
echo "ERROR: less than 10 MB of free space in /tmp"
echo "summary: TMP_LOW_SPACE"
exit $SAME_ERROR
echo "WARNING: less than 10 MB of free space in /tmp"
summary="summary: TMP_LOW_SPACE"
warn=1
fi
# Check quota, if any
......@@ -211,9 +212,9 @@ space=`check_quota .`
if [ $space -ne -1 ] ; then
echo "Quota: $space MB"
if [ $space -lt 10000 ] ; then
echo "ERROR: too little quota"
echo "summary: TMP_LOW_QUOTA"
exit $SAME_ERROR
echo "WARNING: too little quota"
summary="summary: TMP_LOW_QUOTA"
warn=1
fi
fi
......@@ -282,6 +283,10 @@ else
fi
fi
echo
if [ $warn == 1 ] ; then
echo $summary
exit $SAME_WARNING
fi
echo "All checks OK"
echo "summary: OK"
exit $SAME_OK
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