[asterisk-bugs] [Asterisk 0019219]: Memleak with every incoming SUBSCRIBE.
Asterisk Bug Tracker
noreply at bugs.digium.com
Thu May 5 10:01:00 CDT 2011
The following issue has been UPDATED.
======================================================================
https://issues.asterisk.org/view.php?id=19219
======================================================================
Reported By: vrban
Assigned To:
======================================================================
Project: Asterisk
Issue ID: 19219
Category: Channels/chan_sip/Subscriptions
Reproducibility: always
Severity: minor
Priority: normal
Status: acknowledged
Asterisk Version: 1.4.41
JIRA:
Regression: No
Reviewboard Link:
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!):
Request Review:
======================================================================
Date Submitted: 2011-05-03 07:48 CDT
Last Modified: 2011-05-05 10:01 CDT
======================================================================
Summary: Memleak with every incoming SUBSCRIBE.
Description:
The Contact address of every incoming SUBSCRIBE is stored im memory.
It happen in when calling "parse_ok_contact" in "handle_request_subscribe"
I simply removed the call to parse_ok_contact, because i dont need the
contact header in the URI in NOTIFY's because i have a opensips between
the phones and asterisk. that's a working workaround for me.
To reproduce this issue, do the following:
Run the attached perl script, that fire out 1000 SUBSCRIBE's
(make sure you have a hint for that extension, and answer to the
SUBSCRIBE's is a 200 OK)
Then let asterisk do a coredump with kill -6 <asterisk_pid>
Then search for the string "memleak" which is part of the contact
address in the 1000 SUBSCRIBE's.
strings <coredumpfile> |grep memleak
the you will see 1000 lines with the same contact address.
So when you have 1000 phones, and every phone has some activ
SUBSCRIBE, then after a week asterisk use 200MB memory just
to store millons lines of contact addresses.
I work with 1.4 but probably this issue is in all other asterisk versions
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2011-05-05 10:01 lmadsen Description Updated
======================================================================
More information about the asterisk-bugs
mailing list