Monitor() – splitting long calls into several sound files

Home » Asterisk Users » Monitor() – splitting long calls into several sound files
Asterisk Users 2 Comments

Hi,

I’m not sure whether this is possible but if it is, I’m sure someone on
here might know …

Is it possible to use Monitor() to record a conversation[1], but make it
start a new pair of wav files at intervals (eg every 15 minutes) if the
calls go on for a long time?

We already have this happening if the callers press a specific key
sequence (which we’ve defined in features.conf) to pause/resume
recordings but I’d also like to do this automatically during long calls
so that we can split the recordings up into several ‘legs’.

The reason for this is that the wav files spool to a ram disk[2] and if
there are quite a few very long calls they can fill the ram disk up. If
we could split long calls into a series of smaller files, we could move
files off the ramdisk once they’re no longer being actively written to
and recombine them later once the call has finished.

Any ideas?

[1] we used to use MixMonitor() but we stopped using that for a valid
reason though I can’t remember what the reason was now.

[2] if spooling to disk we get audio dropouts when a lot of calls are
being simultaneously recorded

Cheers,
Kingsley.

2 thoughts on - Monitor() – splitting long calls into several sound files

  • Once the call is completed you can use SOX to split the call. In my
    opinion, you will have to get a larger ram disk or record the files to a
    different format like WAV49, but maybe somebody has a better solution for
    you.

  • Hi.

    Yeah, sox and soxmix are no problem – we’re already using that to
    merge/join all of the segments together if people pause then resume the
    recordings mid call.

    The main issue is getting Asterisk to split the recordings into segments
    even when users don’t pause/resume the recordings (which most don’t do).

    The problem with ramdisks is that they’re inherently limited in their
    storage compared to hard disks, so increasing the size of the ramdisk or
    changing the codec might improve matters but it’s still several orders
    of magnitude inferior (in terms of storage). If we could get Asterisk to
    split the recording into segments during a call, it would allow us to
    raise the bar considerably.

    I’m doubting whether it’s actually possible, but I’m hoping to be
    pleasantly surprised 🙂

    Cheers,
    Kingsley.