[asterisk-bugs] [Asterisk 0018194]: [patch] Loading chan_iax2.so allocates >100M RSS

Asterisk Bug Tracker noreply at bugs.digium.com
Mon Jan 31 00:41:40 CST 2011


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=18194 
====================================================================== 
Reported By:                job
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   18194
Category:                   Channels/chan_iax2
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     ready for testing
Asterisk Version:           SVN 
JIRA:                        
Regression:                 No 
Reviewboard Link:           https://reviewboard.asterisk.org/r/1066 
SVN Branch (only for SVN checkouts, not tarball releases): 1.8 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-10-22 16:07 CDT
Last Modified:              2011-01-31 00:41 CST
====================================================================== 
Summary:                    [patch] Loading chan_iax2.so allocates >100M RSS
Description: 
The main asterisk process resident memory usage jumps over 100 MB when
loading chan_iax2.so. The configuration file iax.conf is empty.

If this is not reproducible for other people, let's compare build
environment and libraries.
====================================================================== 

---------------------------------------------------------------------- 
 (0131254) svnbot (reporter) - 2011-01-31 00:41
 https://issues.asterisk.org/view.php?id=18194#c131254 
---------------------------------------------------------------------- 
Repository: asterisk
Revision: 304950

U   branches/1.8/.cleancount
U   branches/1.8/include/asterisk/lock.h
U   branches/1.8/main/heap.c
U   branches/1.8/main/lock.c
U   branches/1.8/main/utils.c

------------------------------------------------------------------------
r304950 | tilghman | 2011-01-31 00:41:38 -0600 (Mon, 31 Jan 2011) | 18
lines

Change mutex tracking so that it only consumes memory in the core mutex
object when it's actually being used.

This reduces the overall size of a mutex which was 3016 bytes before this
back
down to 216 bytes (this is on 64-bit Linux with a glibc-implemented
mutex).
The exactness of the numbers here may vary slightly based upon how mutexes
are
implemented on a platform, but the long and short of it is that prior to
this
commit, chan_iax2 held down 98MB of memory on a 64-bit system for nothing
more
than a table of 32767 locks.  After this commit, the same table occupies a
mere
7MB of memory.

(closes issue https://issues.asterisk.org/view.php?id=18194)
 Reported by: job
 Patches: 
       20110124__issue18194.diff.txt uploaded by tilghman (license 14)
 Tested by: tilghman
 
Review: https://reviewboard.asterisk.org/r/1066

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=304950 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2011-01-31 00:41 svnbot         Note Added: 0131254                          
======================================================================




More information about the asterisk-bugs mailing list