10 lines
225 B
Plaintext
10 lines
225 B
Plaintext
|
#!/usr/bin/bash
|
|||
|
#
|
|||
|
#by fuxiaoshun 4/1
|
|||
|
time=`date +%F-%T`
|
|||
|
a=`df -h | awk NR==6'{print $5}'`
|
|||
|
if [ ${a%\%*} -ge 1 ];then
|
|||
|
echo "$time告警,/分区使用不足" >>/tmp/1.txt
|
|||
|
else
|
|||
|
echo "/分区内存足够"
|
|||
|
fi
|