#!/bin/bash
#cleaning top two max applications' log reguarly when disk's usage exceeds 90%
maxUsed=$(df -h|awk 'NR==8 {print $5}'|sed 's/%$//')
std=90
if [ "$maxUsed" -gt "$std" ];then
echo > /home/sc/projects/lease-consumer/logs/tomcat_stdout.log
fi

Logo

更多推荐