<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <tt>Hi Denis,<br>
      <br>
      See <a class="moz-txt-link-freetext" href="http://www.opensips.org/Documentation/TroubleShooting-OutOfMem">http://www.opensips.org/Documentation/TroubleShooting-OutOfMem</a>
      - this will help you make the difference between a mem leak and a
      temporary memory outage due load. <br>
      <br>
      On the second question - the 1G of mem will be reserved from the
      beginning and internally managed by OpenSIPS.<br>
      <br>
      Regards,<br>
    </tt>
    <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
    <div class="moz-cite-prefix">On 20.10.2016 16:58, Denis wrote:<br>
    </div>
    <blockquote cite="mid:1266754152.20161020165805@ptl.ru" type="cite">
      <title>Re: [OpenSIPS-Users] Out of memory problem</title>
      <span style=" font-family:'Times New Roman'; font-size: 12pt;">Hello
        Bogdan!<br>
        <br>
        Now i am using Opensips 2.2.1 and  i have two problems with shm
        memory <br>
        "Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]:
        ERROR:core:fm_malloc: not enough free shm memory (130982512
        bytes left), please increase the "-m" command line parameter!<br>
        Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]: <a class="moz-txt-link-freetext" href="INFO:core:fm_malloc">INFO:core:fm_malloc</a>:
        attempting defragmentation... (need 206024 bytes)<br>
        Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]: <a class="moz-txt-link-freetext" href="INFO:core:fm_malloc">INFO:core:fm_malloc</a>:
        unable to alloc a big enough fragment!<br>
        Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]:
        ERROR:tm:sip_msg_cloner: no more share memory<br>
        Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]: ERROR:tm:new_t: out
        of mem<br>
        Oct 20 14:22:06 opensips-main
        /usr/local/opensips2.2/sbin/opensips[9431]: ERROR:tm:t_newtran:
        new_t failed<br>
        "<br>
        <br>
        Two questions:<br>
        1) If this problem appears only during some time (after which
        everything became fine), should i still stopped Opensips to try
        catch debug?<br>
        2) Share memory. For example, i established 1G shm. Please, can
        you explain me, what does it value mean? Opensips could use this
        amount of memory (or cannot if it is not necessary), or it
        reserve it?<br>
        <br>
        Thank you.<br>
        <br>
      </span><a moz-do-not-send="true" style=" font-family:'arial';
        font-size: 10pt;" href="mailto:denis7979@mail.ru">mailto:denis7979@mail.ru</a><br>
      <br>
      <table bgcolor="#ffffff">
        <tbody>
          <tr>
            <td bgcolor="#0000ff" width="2"><br>
            </td>
            <td><span style=" font-family:'courier new'; font-size:
                12pt;">Hi Denis,<br>
                <br>
                If you upgrade to 2.2, use the DBG_MALLOC (together with
                your memory manager like F_MALLOC, HP_MALLOC or
                QM_MALLOC) to enable memory leak troubleshooting - at
                shutdown you will get a memory dump, so you will clearly
                see if there is a leak of not.<br>
                <br>
                Regards,<br>
                Bogdan-Andrei Iancu<br>
                OpenSIPS Founder and Developer<br>
              </span><a moz-do-not-send="true" style="
                font-family:'courier new'; font-size: 12pt;"
                href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a><br>
              <span style=" font-family:'times new roman'; font-size:
                12pt;">On 31.05.2016 19:16, Denis wrote:<br>
              </span>
              <table>
                <tbody>
                  <tr>
                    <td bgcolor="#3200ff" width="2"><br>
                    </td>
                    <td><span style=" font-family:'times new roman';
                        font-size: 12pt;">Re: [OpenSIPS-Users] Out of
                        memory problem Hello!<br>
                        <br>
                        I had increased PKG memory twice (to 1000 M) but
                        the problem is still exists.<br>
                        <br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:core:db_allocate_rows: no memory left<br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:db_mysql:db_mysql_fetch_result: no memory
                        left<br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:dialplan:dp_load_db: failed to fetch<br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:dialplan:dp_load_all_db: unable to load
                        ast_dialplan table<br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:dialplan:mi_reload_rules: failed to reload
                        database<br>
                        May 31 19:09:29 opensips-main
                        /usr/local/opensips2.1/sbin/opensips[20681]:
                        ERROR:mi_fifo:mi_fifo_server: command
                        (dp_reload) processing failed<br>
                        <br>
                        Haw else can i make memory debug without
                        Opensips stopped?<br>
                        <br>
                        Thank you.<br>
                        <br>
                      </span><a moz-do-not-send="true" style="
                        font-family:'arial'; font-size: 10pt;"
                        href="mailto:denis7979@mail.ru">mailto:denis7979@mail.ru</a><br>
                      <br>
                      <table bgcolor="#ffffff">
                        <tbody>
                          <tr>
                            <td bgcolor="#0000ff" width="3"><br>
                            </td>
                            <td><span style=" font-family:'courier new';
                                font-size: 12pt;">No, more like the 2.2+
                                LTS, due to be released towards the end
                                of March, a fork of the current "master"
                                branch on git.<br>
                                Liviu Chircu<br>
                                OpenSIPS Developer<br>
                              </span><a moz-do-not-send="true" style="
                                font-family:'courier new'; font-size:
                                12pt;"
                                href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a><br>
                              <span style=" font-family:'times new
                                roman'; font-size: 12pt;">On 29.02.2016
                                12:58, Денис Путято wrote:<br>
                                Re: [OpenSIPS-Users] Out of memory
                                problem Newer version = 2.1?<br>
                                <br>
                              </span><a moz-do-not-send="true" style="
                                font-family:'arial'; font-size: 10pt;"
                                href="mailto:denis7979@mail.ru">mailto:denis7979@mail.ru</a><br>
                              <br>
                              <table bgcolor="#ffffff">
                                <tbody>
                                  <tr>
                                    <td bgcolor="#0000ff" width="6"><br>
                                    </td>
                                    <td><span style="
                                        font-family:'courier new';
                                        font-size: 12pt;">This is PKG
                                        memory (i.e. packaged / private
                                        / per-process), so you should
                                        actually increase "-M" CLI
                                        switch!<br>
                                        <br>
                                        Note: Newer versions of OpenSIPS
                                        will have improved error
                                        reporting for easier
                                        troubleshooting of oom
                                        (out-of-memory) errors.<br>
                                        Liviu Chircu<br>
                                        OpenSIPS Developer<br>
                                      </span><a moz-do-not-send="true"
                                        style=" font-family:'courier
                                        new'; font-size: 12pt;"
                                        href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a><br>
                                      <span style=" font-family:'times
                                        new roman'; font-size: 12pt;">On
                                        29.02.2016 10:20, Денис Путято
                                        wrote:<br>
                                        Re: [OpenSIPS-Users] Out of
                                        memory problem
                                        ERROR:core:db_allocate_rows: no
                                        memory left<br>
ERROR:db_mysql:db_mysql_fetch_result: no memory left<br>
                                        ERROR:dialplan:dp_load_db:
                                        failed to fetch<br>
                                        ERROR:dialplan:dp_load_all_db:
                                        unable to load ast_dialplan
                                        table<br>
                                        ERROR:dialplan:mi_reload_rules:
                                        failed to reload database<br>
                                        ERROR:mi_fifo:mi_fifo_server:
                                        command () processing failed<br>
                                        <br>
                                        <br>
                                      </span><a moz-do-not-send="true"
                                        style=" font-family:'arial';
                                        font-size: 10pt;"
                                        href="mailto:denis7979@mail.ru">mailto:denis7979@mail.ru</a><br>
                                      <br>
                                      <span style=" font-family:'arial';
                                        font-size: 10pt;"><i>&gt; What
                                          is the exact text of the
                                          error?<br>
                                          &gt; ‎<br>
                                          &gt; --<br>
                                          &gt; Alex Balashov | Principal
                                          | Evariste Systems LLC<br>
                                          &gt; 303 Perimeter Center
                                          North, Suite 300<br>
                                          &gt; Atlanta, GA 30346<br>
                                          &gt; United States<br>
                                          <br>
                                          &gt; Tel: +1-800-250-5920
                                          (toll-free) / +1-678-954-0671
                                          (direct)<br>
                                          &gt; Web: </i></span><a
                                        moz-do-not-send="true" style="
                                        font-family:'times new roman';
                                        font-size: 12pt;"
                                        href="http://www.evaristesys.com/">http://www.evaristesys.com/</a><span
                                        style=" font-family:'arial';
                                        font-size: 10pt;"><i>, </i></span><a
                                        moz-do-not-send="true" style="
                                        font-family:'times new roman';
                                        font-size: 12pt;"
                                        href="http://www.csrpswitch.com/">http://www.csrpswitch.com/</a><br>
                                      <br>
                                      <span style=" font-family:'arial';
                                        font-size: 10pt;"><i>&gt; Sent
                                          from my BlackBerry.<br>
                                          &gt;   Original Message  <br>
                                          &gt; From: Денис Путято<br>
                                          &gt; Sent: Monday, February
                                          29, 2016 00:58<br>
                                          &gt; To: Alex Balashov;
                                          OpenSIPS users mailling list<br>
                                          &gt; Subject: Re:
                                          [OpenSIPS-Users] Out of memory
                                          problem<br>
                                          <br>
                                          <br>
                                          &gt;
                                          _______________________________________________<br>
                                          &gt; Users mailing list<br>
                                          &gt; </i></span><a
                                        moz-do-not-send="true" style="
                                        font-family:'arial'; font-size:
                                        10pt; font-style: Italic;"
                                        href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
                                      <span style=" font-family:'arial';
                                        font-size: 10pt;"><i>&gt; </i></span><a
                                        moz-do-not-send="true" style="
                                        font-family:'times new roman';
                                        font-size: 12pt;"
                                        href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
                                      <br>
                                      <br>
                                      <span style=" font-family:'arial';
                                        font-size: 10pt;"><i>_______________________________________________<br>
                                          Users mailing list<br>
                                        </i></span><a
                                        moz-do-not-send="true" style="
                                        font-family:'arial'; font-size:
                                        10pt; font-style: Italic;"
                                        href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
                                      <a moz-do-not-send="true" style="
                                        font-family:'arial'; font-size:
                                        10pt; font-style: Italic;"
                                        href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a></td>
                                  </tr>
                                </tbody>
                              </table>
                            </td>
                          </tr>
                        </tbody>
                      </table>
                      <br>
                      <br>
                      <span style=" font-family:'courier new';
                        font-size: 12pt;">_______________________________________________<br>
                        Users mailing list<br>
                      </span><a moz-do-not-send="true" style="
                        font-family:'courier new'; font-size: 12pt;"
                        href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
                      <span style=" font-family:'courier new';
                        font-size: 12pt;">
                      </span><a moz-do-not-send="true" style="
                        font-family:'courier new'; font-size: 12pt;"
                        href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
                      <span style=" font-family:'courier new';
                        font-size: 12pt;">
                      </span></td>
                  </tr>
                </tbody>
              </table>
            </td>
          </tr>
        </tbody>
      </table>
    </blockquote>
    <br>
  </body>
</html>