Megatest

Artifact [d63bf48441]
Login

Artifact d63bf484412a387ee9fdd01a87df01c0feaa85af:


#!/bin/bash -e
diskpath=$1
spacereq=$2
freespace=`df -k $diskpath | grep $diskpath | awk '{print $4}'`
if [[ $freespace -lt $spacereq ]];then
  echo "ERROR: insufficient space on $diskpath"
  exit 1
else
  echo "There is adequate space on $diskpath"
fi