[Kamailio-Users] Shared memory

Bruno Machado bsmufu at yahoo.com.br
Mon Mar 22 18:14:47 CET 2010


I have some questions regarding the shared memory. I'm working with the version 1.5.2 and
its environment is quite simple. It does'nt storage any informations in the memory, like dialplan,
contacts of subscribers, carrierroute, LCR and etc. The only purpose of this server is being a
redirect server. Some calls have several possible destinations, reaching easily 12 contacts.
The config.h's constant MAX_BRANCHES is set in 12, the default number. Ok.
Like I said, almost the requests have more than 12 possible contacts. When it happens, Kamailio
logs these messages:

/usr/local/kamailio-1.5.2/sbin/kamailio[26188]: ERROR:core:append_branch: max nr of branches exceeded
/usr/local/kamailio-1.5.2/sbin/kamailio[26188]: ERROR:pv:pv_set_branch: append_branch action failed

Ok. It is not a problem. It is an error but it does not stop the system. The SIP messages still flowing 
normally. The server works for several days, 24/7 without functional errors, receiving 
five hundred thousand requests per day . But, usually at the weekends and the clock tells 2:30 am,
the company's cell phone rings bringing a message: 'the system is down'. Kamailio shows:

/usr/local/kamailio-1.5.2/sbin/kamailio[25492]: ERROR:core:add_avp: no more shm mem 
/usr/local/kamailio-1.5.2/sbin/kamailio[25492]: ERROR:exec:exec_avp: unable to add avp 

Kamailio stills running but it is not possible to route any request. All the new incoming
calls generates the same error: 'no more shm mem'. I changed the size of shared memory, 
running Kamailio with '-m 64', but the server stopped again after some days. I see the options:

- increase MAX_BRANCHES
- increase again 'm' parameter (but it will just add more some days in the running time)
- reduce the maximum number of contacts to 11 of the script that returns them to Kamailio

So, my doubts are:

- is it possible to have a memory leak when the message "max nr of branches exceeded" is showed?
- changing '-m parameter' to a higher value, like 256, could affect the performance?

tks friends
bruno machado



      ____________________________________________________________________________________
Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/users/attachments/20100322/041ec97f/attachment.htm>


More information about the Users mailing list