<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Some extra note to be able to spot the memory summary in syslog --
    should be a set of lines looking like:<br>
    <br>
    <meta charset="utf-8">
    20(4082) NOTICE: fm_status: summarizing all alloc'ed. fragments:<br>
    20(4082) NOTICE: fm_status:  count=     1 size=     16640 bytes from
    <core>: counters.c: counters_prefork_init(207)<br>
    20(4082) NOTICE: fm_status:  count=     1 size=     14560 bytes from
    debugger: debugger_api.c: dbg_init_pid_list(572)<br>
    .......<br>
    16(44262) NOTICE: fm_status:  count=     1 size=         8 bytes
    from <core>: mem/shm_mem.c: shm_mem_init_mallocs(179)<br>
    16(44262) NOTICE: fm_status: -----------------------------<br>
    <br>
    Cheers,<br>
    Daniel<br>
    <br>
    <div class="moz-cite-prefix">On 04/09/15 01:03, Daniel-Constantin
      Mierla wrote:<br>
    </div>
    <blockquote cite="mid:55E8D1B5.9090609@gmail.com" type="cite">
      <meta content="text/html; charset=windows-1252"
        http-equiv="Content-Type">
      Hello,<br>
      <br>
      I tried to reproduce the scenario, but couldn't get the leak,
      might be specific for your config and use case.<br>
      <br>
      Can you try the next steps, in order to check there is indeed a
      leak:<br>
      <br>
       - use kamailio 4.2<br>
       - set memlog parameter in kamailio.cfg to a lower value than
      debug parameter (e.g., memlog=1)<br>
       - start kamailio and do the tests you expect to lead to the issue<br>
       - stop sending traffic to kamailio (no more calls)<br>
       - issue the command "kamcmd corex.shm_summary" and look in the
      syslog file, grab the memory dump summary messages<br>
       -  wait for 3 minutes (still with no traffic) and issue again
      "kamcmd corex.shm_summary", grab again the summary from the syslog<br>
       - send here the messages from the two summaries<br>
      <br>
      Cheers,<br>
      Daniel<br>
      <br>
      <div class="moz-cite-prefix">On 30/08/15 06:05, Bui Minh Yen
        wrote:<br>
      </div>
      <blockquote
cite="mid:CAC5bOT1VMznO_yzNhv67VBQRuT3EoSSxvpTj5VRuDV_TR=NmWQ@mail.gmail.com"
        type="cite">
        <div dir="ltr">Hi everyone,
          <div><br>
          </div>
          <div>I am using Kamailio-4.1.5 and Kamailio-4.2.5 but with
            this both version I had a problem:</div>
          <div><br>
          </div>
          <div>Connection diagrams:<br>
          </div>
          <div>SIP client ---- SBC --- Kamailio --- MGC/MGW --- GSM/PSTN
            subscriber</div>
          <div><br>
          </div>
          <div>Scenario:</div>
          <div>- Caller (SIP) make a new call to GSM (PSTN) subscriber</div>
          <div>- When GSM/PSTN is ringing or not ringing, Caller cancel
            call (Caller send CANCEL message)</div>
          <div>- But MGC does not send response message for CANCEL
            message</div>
          <div>- After about 120s (<code class=""
              style="color:rgb(0,0,0)">fr_inv_timer<font
                face="Helvetica, Arial">), Kamailio send 487 Request
                Terminated to SBC.</font></code></div>
          <div><code class="" style="color:rgb(0,0,0)"><font
                face="Helvetica, Arial"><br>
              </font></code></div>
          <div><code class="" style="color:rgb(0,0,0)"><font
                face="Helvetica, Arial">From this time, Kamailio have
                memory leak (tm does not free transactions)</font></code></div>
          <div><code class="" style="color:rgb(0,0,0)"><font
                face="Helvetica, Arial"><br>
              </font></code></div>
          <div><code class="" style="color:rgb(0,0,0)"><span
                style="font-family:Helvetica,Arial">I reproduced this
                bugs 4-5 times and same problem is happen</span><font
                face="Helvetica, Arial"><br>
              </font></code></div>
          <div><br>
          </div>
          <div>I attached capture file and log when I show shared memory
            (using kamcmd core.shmmem) and tm statistics (using kamcmd
            tm.stats). And time Kamailio start memory leak
            is 08-30-15-10:18:53</div>
          <div><br>
          </div>
          <div>Could you help me solve this problem?</div>
          <div><br>
          </div>
          <div>Thank you so much!<br clear="all">
            <div><br>
            </div>
            -- <br>
            <div class="gmail_signature">
              <div dir="ltr"><font color="black" size="2" face="Tahoma"><span
                    style="font-size:10pt" dir="ltr">
                    <div><font size="1"><span style="font-size:13px">
                          <div>
                            <p><span><span
                                  style="font-size:10.5pt;color:black">---------------------------</span></span>
                            </p>
                            <p><span><b><span
                                    style="font-size:10pt;font-family:'Segoe
                                    UI',sans-serif;color:rgb(27,93,141)">Bui

                                    Thi Minh Yen</span></b></span></p>
                          </div>
                        </span></font></div>
                  </span></font><span
style="border-collapse:collapse;font-family:arial,sans-serif;font-size:13px"></span></div>
            </div>
          </div>
        </div>
        <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
        <br>
        <pre wrap="">_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
      </blockquote>
      <br>
      <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://twitter.com/#%21/miconda">http://twitter.com/#!/miconda</a> - <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a>
Book: SIP Routing With Kamailio - <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a></pre>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla
<a class="moz-txt-link-freetext" href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a>
Book: SIP Routing With Kamailio - <a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a></pre>
  </body>
</html>