#!/bin/bash logpath=/var/logloglines=5000 for name in `ls $logpath`dotail -n $loglines $logpath/$name > /tmp/log.tempcp -f /tmp/log.temp $logpath/$namedonerm -f /tmp/log.temp /bin/sleep 3/usr/bin/killall -9 httpd/bin/rm -rf /usr/local/apache/logs/*/bin/sleep 5/etc/rc.d/init.d/httpd startssl