<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Thank you Sven,</p>
    <p>I'm not using Redis for calls yet, so it's not that big and it
      starts (around 140MB now), but this can be interesting for other
      users too.<br>
    </p>
    <p>For me the only problem is the starting order. Your fix will
      work, but as Sipwise already made an effort to release a patch I
      will test until it works as it should.</p>
    <p>Regards,</p>
    <p>Henk<br>
    </p>
    <div class="moz-cite-prefix">On 20-5-2019 18:03, Sven Van Gorp
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:8aed7d3c-5225-4009-86a2-b76fddc59467@alea-soluciones.com">
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <p>Hi Henk,</p>
      <p>we had the same problem like a month ago:</p>
      <div dir="ltr"><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">In our case the problem was that Redis checks the database file</span><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap"> /ngcp-data/</span><span class="gmail-il" style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">redis</span><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">/mpc-</span><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">nivisng1.aof at startup, and ours was 1G and that took longer then the 1,5 minute that systemd waits and so systemd abandoned startup of Redis and so redis never started, hence no calls</span>
        <div><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">
</span></div>
        <div><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">we changed the timeout in systemd from the default 1m 30sec to 3 minutes by adding to </span><font
            face="Arial" color="#000000"><span style="white-space:pre-wrap"> /etc/systemd/system/redis-server.service.d/override.conf:</span></font></div>
      </div>
      <blockquote style="margin:0 0 0 40px;border:none;padding:0px">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div dir="ltr">
                <div><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">TimeoutStartSec=3min</span></div>
              </div>
            </div>
          </div>
        </div>
      </blockquote>
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">
</span></div>
              <div><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">On the other hand we added a dependency for Redis in Kamailio therfore we added to /</span>etc/systemd/system/kamailio-proxy.service.d/override.conf</div>
              <div><br>
              </div>
            </div>
          </div>
        </div>
      </div>
      <blockquote style="margin:0 0 0 40px;border:none;padding:0px">
        <div>
          <div>
            <div>
              <div>
                <div><font face="Arial" color="#000000"><span style="white-space:pre-wrap">[Unit]</span></font></div>
              </div>
            </div>
          </div>
        </div>
        <div>
          <div>
            <div>
              <div>
                <div><font face="Arial" color="#000000"><span style="white-space:pre-wrap">Requires=redis-server.service</span></font></div>
              </div>
            </div>
          </div>
        </div>
        <div>
          <div>
            <div>
              <div>
                <div><font face="Arial" color="#000000"><span style="white-space:pre-wrap">After=redis-server.service</span></font></div>
                <div><font face="Arial" color="#000000"><span style="white-space:pre-wrap">
</span></font></div>
              </div>
            </div>
          </div>
        </div>
      </blockquote>
      <div class="moz-cite-prefix">
        <div dir="ltr"><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">That did the trick for us</span></div>
        <div dir="ltr"><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">
</span></div>
        <div dir="ltr"><span style="color:rgb(0,0,0);font-family:Arial;white-space:pre-wrap">cheers, Sven
</span></div>
        <br>
      </div>
      <div class="moz-cite-prefix">El 11/5/19 a las 11:24, Henk
        escribió:<br>
      </div>
      <blockquote type="cite"
        cite="mid:6e68f927-348b-cc35-f2c2-77712665d769@voipdigit.nl">
        <meta http-equiv="content-type" content="text/html;
          charset=UTF-8">
        <p>Hi,</p>
        <p>After upgrading to mr6.5.4 and applying the latest patches,
          kamailio-proxy still starts with this error and stops:</p>
        <p><font size="-1"><tt>May 11 11:06:36 spce proxy[1840]: ERROR:
              db_redis [redis_connection.c:124]: db_redis_connect():
              cannot open connection to redis://localhost:6379/23:
              Connection refused</tt><tt><br>
            </tt><tt>May 11 11:06:36 spce proxy[1840]: ERROR: db_redis
              [redis_connection.c:226]: db_redis_new_connection():
              Failed to connect to redis db</tt><tt><br>
            </tt><tt>May 11 11:06:36 spce proxy[1840]: ERROR:
              <core> [db.c:319]: db_do_init2(): could not add
              connection to the pool</tt><tt><br>
            </tt><tt>May 11 11:06:36 spce proxy[1840]: ERROR: dialog
              [dlg_db_handler.c:146]: init_dlg_db(): Unable to connect
              to the database</tt><tt><br>
            </tt><tt>May 11 11:06:36 spce proxy[1840]: ERROR: dialog
              [dialog.c:688]: mod_init(): failed to initialize the DB
              support</tt><tt><br>
            </tt><tt>May 11 11:06:36 spce proxy[1840]: ERROR:
              <core> [core/sr_module.c:990]: init_mod(): Error
              while initializing module dialog
              (/usr/lib/x86_64-linux-gnu/kamailio/modules/dialog.so)</tt></font><br>
        </p>
        It looks like dependencies on redis are still not all defined in
        systemd.<br>
        As I search through the configuration only SEMS and prosody
        seems to have a defined dependency
        <p>Regards,</p>
        <p>Henk<br>
        </p>
        <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
        <pre class="moz-quote-pre" wrap="">_______________________________________________
Spce-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Spce-user@lists.sipwise.com" moz-do-not-send="true">Spce-user@lists.sipwise.com</a>
<a class="moz-txt-link-freetext" href="https://lists.sipwise.com/listinfo/spce-user" moz-do-not-send="true">https://lists.sipwise.com/listinfo/spce-user</a>
</pre>
      </blockquote>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Spce-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Spce-user@lists.sipwise.com">Spce-user@lists.sipwise.com</a>
<a class="moz-txt-link-freetext" href="https://lists.sipwise.com/listinfo/spce-user">https://lists.sipwise.com/listinfo/spce-user</a>
</pre>
    </blockquote>
  </body>
</html>