<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
Hello,<br>
<br>
<div class="moz-cite-prefix">On 20/02/14 18:32, Uri Shacked wrote:<br>
</div>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Hi,</span><span
style="font-size:12pt;font-family:'Times New Roman',serif"></span><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span>
</p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Following
my issue
with the above....</span></p>
<p class="" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">1.<span
style="font-size:7pt;font-family:'Times New Roman'">Â Â Â
</span></span><span dir="LTR"></span><span
style="font-size:12pt;font-family:Arial,sans-serif">Is
there a way to see if a worker (child) is processing a
transaction for too long (let’s say 2-3 sec)?</span></p>
</div>
</div>
</blockquote>
<br>
you can get a log message when execution of an action is slow, see:<br>
<br>
<a class="moz-txt-link-freetext" href="http://www.kamailio.org/wiki/cookbooks/4.1.x/core#latency_limit_action">http://www.kamailio.org/wiki/cookbooks/4.1.x/core#latency_limit_action</a><br>
<br>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">2.<span
style="font-size:7pt;font-family:'Times New Roman'">Â Â Â
</span></span><span dir="LTR"></span><span
style="font-size:12pt;font-family:Arial,sans-serif">Is
there an option to see if the DB connection is alive? (I
am
familiar with db_mysql options)</span></p>
</div>
</div>
</blockquote>
<br>
Probably you can use OS tools like netstat to see active connections
in the system.<br>
<br>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">3.<span
style="font-size:7pt;font-family:'Times New Roman'">Â Â Â
</span></span><span dir="LTR"></span><span
style="font-size:12pt;font-family:Arial,sans-serif">If all
workers are stuck on this "long" transaction,
is there a Q for the new INVITES? Can I see how many are
there?</span></p>
</div>
</div>
</blockquote>
<br>
The queu is in the OS socket buffer, but I am not aware of how to
see what's there.<br>
<br>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">What I
was
experiencing is that when my DB was very slow, kamailio
crashed after a
while....</span></p>
</div>
</div>
</blockquote>
<br>
Still haven't had time to get to look at it more close. It should
not crash, but could be also from the library, like killing it when
something is stuck too long. Overall, it should be good not to get
long queries, even if it is asynchronous, it will fill up at some
point even there (e.g., by number of threads or memory) -- these
remarks are not specific for kamailio, but in general.<br>
<br>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">I will
configure
db_mysql to ping every 30 sec and timeout after 1 sec.</span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Still,
it can create a
3 sec delay for transactions.</span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Any
one has an idea?</span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Using
the ASYNC module
can help here? Does it free the worker to deal with new
requests?</span></p>
</div>
</div>
</blockquote>
Yes, it will get in another process to handle the actions after
t_suspend() and the sip worker will get to next packet from the
network.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
<blockquote
cite="mid:CAMMbDhQ9gvwQwwK1wnxwhppSmuoQrefKzxDdjrf4+xtG6yPN8w@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Â </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">BR,</span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt"><span
style="font-size:12pt;font-family:Arial,sans-serif">Uri</span></p>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a 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 class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
<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></pre>
</body>
</html>