– Kamailio SIP Server –

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
troubleshooting:private-memory-size [2006/12/19 10:40]
81.180.83.75
troubleshooting:private-memory-size [2008/02/13 18:09] (current)
212.227.35.68 fix errors, actualize content
Line 1: Line 1:
 +===== Increase Private Memory Size =====
  
 +OpenSER has its own memory manager. Even if you have lot of memory in the system, OpenSER will use only the memory size it was configured, and you may get "out of memory" errors sooner than expected. This does not mean that there is a memory leak, but insufficient allocated size for your subscriber population. Common cases for large needs of private memory are: loading user location contacts, doing NAT pinging. Actual OpenSER versions overcome the first issue by implementing database FETCH support. The other cases will be taken in consideration very soon.
 +
 +By default the size of private memory chunk used by each OpenSER process is 1 MB.
 +
 +To increase the size of private memory you need to compile OpenSER from sources. Once you get the sources from SVN or the openser.org's download site, do the following steps:
 +
 +- edit the file '**config.h**' and search for the next lines:
 +
 +  /*used only if PKG_MALLOC is defined*/
 +  #define PKG_MEM_POOL_SIZE 1024*1024
 +
 +- change the value of PKG_MEM_POOL_SIZE to desired size, for example to have 4MB of private memory:
 +
 +  #define PKG_MEM_POOL_SIZE 4*1024*1024
 +
 +- recompile and reinstall OpenSER
 +
 +  make all; make install;
 +
 +
 +====== Increase Share Memory Size ======
 +
 +To increase the share memory size use '-m' command line parameter of OpenSER.
 +
 +<code>
 +openser -m 256
 +
 +# this will run OpenSER with 256MB of share memory
 +</code>
 +
 +===== Troubleshooting Stuff =====
 +
 +{{indexmenu>troubleshooting|js}}