hi

using kamailio 4.4.7 on that environment

i will try to run some test locally simulating reception of a lot presence subscription and  observe mem_copy_subs_noc(), 
Just to understand,  both mem_copy_subs_noc are not expected to increase, is that right? What do they exactly mean?

Thanks


On Sat, 11 Sep 2021, 22:22 Henning Westerholt, <hw@skalatan.de> wrote:

Hello,

 

the output below indicates the memory allocated in the individual functions. So it seems that the mem_copy_subs_noc() function allocates a lot of memory. It is increasing over time? The final output looks like a wrapping error, the counter goes negative.

 

Which version of Kamailio do you use on the



server?

 

Cheers,

 

Henning

 

--

Henning Westerholt – https://skalatan.de/blog/

Kamailio services – https://gilawa.com

 

From: sr-users <sr-users-bounces@lists.kamailio.org> On Behalf Of Albert Petit
Sent: Thursday, September 9, 2021 11:42 PM
To: SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) - Users Mailing List <sr-users@lists.sip-router.org>
Subject: [SR-Users] Question about suspected memory leak presence module

 

Hi,

 

I am suspecitng presence module might be having a memory leak on a production server used by an end user (not have access to it).

 

The output of command kamcmd mod.stats presence shm is

Module: presence

{

        mem_copy_subs(148): 25720

        mem_copy_subs_noc(214): 1672201904

        mem_copy_subs_noc(251): 678406560

        add_event(181): 88

        shm_copy_event(57): 40

        shm_copy_event(50): 312

        add_event(156): 40

        add_event(149): 456

        new_shtable(66): 5767168

        new_shtable(53): 262144

        init_evlist(289): 16

        Total: -1938302848

}

 

I am not sure what mem_copy_subs_noc is meaning. And final output is negative,  SHM is incfreasing all the time but not sure of the root cause

 

is this a reasonable hint that a memory leak is related to presence?