#########start script#############
#!/bin/bash
s=`du -k /home/xiaoyi/test.log | awk '{print $1}'`
if [ $s -gt "204800" ]
then
cp /home/cisco/Cisco.log /home/shell/
cat /dev/null > /home/cisco/Cisco.log
else
exit
fi
##########end script##############
转载于:https://blog.51cto.com/441970/997271