[Serusers] Memory leak?

Andrei Pelinescu-Onciul pelinescu-onciul at fokus.fraunhofer.de
Tue May 27 19:34:10 CEST 2003

On May 27, 2003 at 11:16, Jamin W. Collins <jcollins at asgardsrealm.net> wrote:
> On Tue, May 27, 2003 at 06:58:00PM +0200, Andrei Pelinescu-Onciul wrote:
> > Could you stop the proxy and send us the memory status log dumped at the
> > end, or (if you don't want to stop it) kill -SIGUSR1 and again send the
> > mem. log.
> I'm not sure which log you are referring to.  The server itself has been
> rebooted by the customer to return functionality.  I found the errors
> after the fact.

Look in the log for lines conatining: "qm_status" , "heap size=", 
"dumping all allocked. fragments:". They should appear before ser

> > What happens is ser runs out of local memory. ser uses shared memory
> > (you can specify the shared mem. size with -m) and "local" memory (per
> > process). The local memory can be alloc'ed/dealloc'ed much faster (it
> > does not require any locking). Usually ser runs out of shared mem., since
> > "local" mem. is used in general only for temporary storage.
> > ser will use maximum 1 Mb of "local" memory. So far we didn't need more.
> > As a quick fix you can try to increase the size. You will have to change
> > the value of PKG_MEM_POOL_SIZE in config.h and recompile.
> Is the local memory allocated per listening process (as reported by
> 'ps') or per child process (as configured in ser.cfg) or based on
> something else?  Just trying to get a grasp on how much the change will
> effect the memory usage in my environment. 

per listening process ( total no. of processes = child_no *
 no_of_listening_addresses + 3).
> Also how much shared memory does SER allocate by default?  Would
> increasing this number possibly help?

32 Mb. In this case it will not help since this is not shared mem. The
shared mem. runs out (usually :-)) when ser is in statefull mode (tm is
used for forwarding) and a lot of calls are handled almost
simultaneously (within sip expire time limits). This also depends on the
CPU power (if the machine can handle only 100 cps due to cpu limits you
will never exceed the default 32 Mb). On a dual athlon 2000+ which can
handle ~4900 cps, 256 Mb are enough (ser -m 256).


More information about the sr-users mailing list