Rev 1 | Blame | Last modification | View Log
#!/bin/sh
# script de nettoyage des archives supérieures à 1 an ( 365 jours)
DATE=`date +%F`
REP="/var/log/squid/ /var/log/httpd/ /var/log/firewall/ /var/Save/base/ /var/Save/logs/firewall/ /var/Save/logs/squid/ /var/Save/logs/httpd/"
delay=365
for i in $REP
do
find $i -mtime +$delay -name '*.gz' -exec rm -f {} \;
find $i -mtime +$delay -name '*.sql' -exec rm -f {} \;
done
exit 0