go ahead... be a heretic | |
PerlMonks |
Whoops - here's the scriptby prodevel (Scribe) |
on Jun 30, 2000 at 23:46 UTC ( [id://20663]=note: print w/replies, xml ) | Need Help?? |
#!/usr/bin/ksh
x=0
for filesys in `df -k | awk '{print $1}'`
do
x=`expr $x + 1`
dfline=`df -k | head -$x | tail -1`
full=`echo $dfline | awk '{print $5}' | sed 's/%//g' | egrep -v capacity`
if $full -gt 76
then
mailx -s "Filesystem: $filesys is ${full}% full!!!" pager@pagerhost.com <<EOF
$dfline
EOF
fi
done
In Section
Craft
|
|