A way to delete record files from asterisk server
Posted: Wed Oct 08, 2008 12:00 pm
Hi, I'd been having the .cvs problem, I think it is cause when the crontab is trying to delete the old files (log and recordings) from the server , I set that the recordings has to be delete every two days heres the crontabs from it removal task:
I dont know maybe I did something wrong, Or maybe I can setup the mp3 ftp script to delete each file when this is send via ftp to the data server
Can you please tell me if I didi something wrong on the crontab and how I can modify the script to delete immediately when the record is send via ftp (if this can be done)
### remove old recordings more than 7 days old
24 0 * * * /usr/bin/find /var/spool/asterisk/monitorDONE/ORIG -maxdepth 2 -type f -mtime +2 -print | xargs rm -f
### remove old vicidial logs and asterisk logs more than 2 days old
28 0 * * * /usr/bin/find /var/log/astguiclient -maxdepth 1 -type f -mtime +2 -print | xargs rm -f
29 0 * * * /usr/bin/find /var/log/asterisk -maxdepth 3 -type f -mtime +2 -print | xargs rm -f
I dont know maybe I did something wrong, Or maybe I can setup the mp3 ftp script to delete each file when this is send via ftp to the data server
Can you please tell me if I didi something wrong on the crontab and how I can modify the script to delete immediately when the record is send via ftp (if this can be done)