Deleting OLD Voicemails

Home » Asterisk Users » Deleting OLD Voicemails
Asterisk Users 8 Comments

Thanks Jason,

But how to delete them? there are a lot of old voicemails, but i don’t want
to break the app_voicemail.

2012/5/22 Jason Parker

> On 05/22/2012 04:54 PM, Danny Dias wrote:
> > There are 4 files for each voicemail:
> >
> > msg0000.gsm
> > msg0000.txt
> > msg0000.wav
> > msg0000.WAV
> >
> That is perfectly normal. The .txt file is metadata that contains things
> like
> caller ID and duration. Asterisk will also save voicemails into every
> format
> you have specified in voicemail.conf.
> —
> _____________________________________________________________________
> — Bandwidth and Colocation Provided by
> New to Asterisk? Join us for a live introductory webinar every Thurs:
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:

8 thoughts on - Deleting OLD Voicemails

  • You can delete old files, it won’t break anything. Also to prevent saving files in multiple formats, edit voicemail.conf and change format parameter under general.

  • Hi, thanks for your answers…

    Can i delete like this:

    rm -rf /var/spool/asterisk/voicemail/voicemailcontextcustomer/300/INBOX/*.*

    Is that ok? will this break something?

    A little doubt here, once the user hears the voicemail using the phone, the
    message is automatically moved to Old folder, is that right?

    Many thanks!

    2012/5/23 Mehmet Avcioglu

  • El mié, 23-05-2012 a las 11:42 +0200, Danny Dias escribió:

    You can make that without problems….

    Yes, that’s ok

  • I did not understand. What do you mean with renumber all the messages?
    El 25/05/2012 02:27, “Edwin Lam” escribió:

  • I believe one of the patches involved in fixing for The Great Voicemail Problem* about a year ago was to make voicemail automatically renumber the mailbox files if it saw a gap.

    * from memory: The Great Voicemail Problem is a bug where if you received a new voicemail while listening to a message, the mailbox was not renumbered correctly when you deleted a message.

  • I use find on a cron schedule to remove old recordings everyday. Im sure
    you can do the same

    find -H /var/log/asterisk/asterisk_rec/* -mtime +90 -type f -exec rm -v {}

    anything older than 90 days