Sip Trace Log Retention

Hello, is it possible to set a time limit for sip trace data retention? I would like to delete all logs on daily basis.
Can you please also tell me how can I manually delete all traces via gui or via command line? Right now i simply delete all contents in /var/spool/sems/dump folder but on cdr list the icon that announces that there are sip logs for that calls still remains, I would like to know if there’s a faster way for doing it. If there’s an already done script I can set a cronjob with the command to delete all traces.
Thank you

there is no build-in tool for this. You can write some script and use it with cron.

but how to remove icon on cdr? do I have also to update the cdr db?

I’m using a distributed setup so right now i’ve implemented this on /etc/crontab to delete all files older than 4 hours, every 4 hours

0 */4 * * * root find /var/www/dump -type f -mmin +240 -exec rm {} ;

who want to add this feature on single server can put
0 */4 * * * root find /var/spool/sems/dump/ -type f -mmin +240 -exec rm {} ;

yes, but I don’t recommend to do this.

Ok, it doesn’t justify the risk and the work, the important thing is to free space.