#551 Stuck Transactions/Memory Leak with B2B top hiding

1.8.x
closed-out-of-date
modules (454)
8
2015-04-07
2012-08-14
Ryan Bullock
No

I am experiencing a memory leak when using the B2B modules with the internal "top hiding" scenario. It appears to be related to struck/un-freed transactions, as the opensips mi will report many thousands of inuse_transactions when the reality is only a handful. An example is we currently show 15000+ inuse_transactions while only a handful of calls are actually in progress. These transactions appear to build up over time.

Opensips information:
version: opensips 1.8.0-notls (x86_64/linux)
flags: STATS: Off, USE_IPV6, USE_TCP, DISABLE_NAGLE, USE_MCAST, SHM_MEM, SHM_MMAP, PKG_MALLOC, DBG_QM_MALLOC, FAST_LOCK-ADAPTIVE_WAIT
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
svnrevision: 2:9164M
@(#) $Id: main.c 8772 2012-03-08 11:16:13Z bogdan_iancu $
main.c compiled on 12:24:36 Aug 3 2012 with gcc 4.4.6

I currently have the memdump option enabled and am waiting for another buildup of transactions to gather the memdump information. I can supply access to the dump and the opensips configuration file via email.

Discussion

<< < 1 2 (Page 2 of 2)
  • Ryan Bullock
    Ryan Bullock
    2012-09-24

    Hey Bogdan,

    I tried the patch, but the compiler complained that tm might be uninitialized and it caused a segfault when I tried to run it. I have the core dump if you would like a backtrace.

     
  • First attempt for a fix

     
    Attachments
  • Hi Ryan,

    Just uploaded a patch with a first attempt for a fix - couple you give it a try (with cautious :) )

    Thanks and regards,
    Bogdan

     
  • Ryan Bullock
    Ryan Bullock
    2012-10-12

    Adding the patch to my list of things to test. Might be a bit before I get to it.

     
  • Ryan Bullock
    Ryan Bullock
    2012-10-22

    Sorry for the delay in updating this.

    Still showing memory and transactions climb after this patch, so it seems there are still some leaks present.

    Would a new memory dump be helpful?

    Let me know if there is anything I can do to help.

    Regards,

    Ryan

     
    • status: open --> closed-out-of-date
     
<< < 1 2 (Page 2 of 2)