Delete expire backup data after seven day
#!/bin/bash
path=/usr/local
find ${path:-/tmp} -name ".tar.gz" -type f -mtime +7 | xargs rm -rf
retal=$?
if [ $retal - eq 0 ];then
echo " the file ".tar.gz" deleted ."
else
echo " Not found archive files."
fi