[asterisk-dev] Asterisk consuming lots of memory in frame.c cache

James Lamanna jlamanna at gmail.com
Fri Nov 28 13:18:46 CST 2014


On Wed, Nov 26, 2014 at 4:54 PM, James Lamanna <jlamanna at gmail.com> wrote:

> Hi,
> I have filed a bug for this here:
> https://issues.asterisk.org/jira/browse/ASTERISK-24555
>
> It appears that something in Asterisk 11 is continuously allocating frames
> and not freeing them.
> This causes Asterisk 11.14.0 to allocate almost 4GB of memory within a
> couple of days and ~15000 calls.
> This PBX is primarily used for faxing (Asterisk + IAXModem & T.38 Gateway)
> so I'm wondering if the issue is in the SLIN codec or the T.38 gateway code.
>
> I've taken a quick glance and I haven't seen any mismatched ast_frdup() /
> ast_frfree() yet.
>
> Thanks.
>
>
I did a quick valgrind run and attempted a couple of faxes.
I found 7 or so entries in the valgrind log with:

==30640== 211,203 bytes in 279 blocks are definitely lost in loss record
1,772 of 1,789
==30640==    at 0x4C267CC: calloc (vg_replace_malloc.c:467)
==30640==    by 0x4DC50E: ast_frdup (utils.h:523)
==30640==    by 0x47125F: __ast_queue_frame (channel.c:1284)
==30640==    by 0x1EF75589: __do_deliver (chan_iax2.c:3102)
==30640==    by 0x1EF76C5A: schedule_delivery (chan_iax2.c:4374)
==30640==    by 0x1EF8F497: socket_process_helper (chan_iax2.c:12010)
==30640==    by 0x1EF99C37: iax2_process_thread (chan_iax2.c:12030)
==30640==    by 0x56C458: dummy_start (utils.c:1192)
==30640==    by 0x5E359C9: start_thread (pthread_create.c:300)
==30640==    by 0x271A66FF: ???
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20141128/2db20ed9/attachment.html>


More information about the asterisk-dev mailing list