<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>OK. Can you run the tests for a while and then execute:</p>
<p>kamctl rpc corex.pkg_summary idx 1</p>
<p>The value for idx should be the kamailio process expected to
handle sip traffic. If it is mostly udp and the first socket is
the corresponding udp socket, then the value 1, like above, is ok.
If it is tcp/tls or you have different listen parameters on udp,
see the processes index with:</p>
<p>kamctl ps</p>
<p>It should not be required to wait till you get out of memory
errors, but be sure you run it long enough to have many accounting
records written by the process that is going to print the pkg
summary. You can eventually set the children to 1 or 2, to "force"
traffic via a smaller group of processes.</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div class="moz-cite-prefix">On 14.10.22 10:12, mayamatakeshi wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CABaNFCb24jEkRoMv_68fPfyMS3sE+gTWFo07ZRvQygqMVghdBA@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">
<div>Hi,</div>
<div>I am using acc for CDR generation. Here is the module
configuration I'm using:</div>
<div><br>
</div>
<div>modparam("acc", "db_url",
"mysql://kamailio:kamailiorw@localhost/kamailio")<br>
modparam("acc", "db_flag", 1) <br>
modparam("acc", "db_missed_flag", 2)<br>
modparam("acc", "failed_transaction_flag", 3)<br>
modparam("acc", "cdr_enable", 1)<br>
modparam("acc", "cdrs_table", "cdr")<br>
modparam("acc", "cdr_extra",
"callid=$ci;caller_domain=$dlg_var(caller_domain);callee_domain=$dlg_var(callee_domain);caller_username=$dlg_var(caller_username);callee_username=$dlg_var(callee_username);calling_number=$dlg_var(calling_number);destination=$dlg_var(destination);anonymous=$dlg_var(anonymous);forwarding=$dlg_var(forwarding);tracing=$dlg_var(tracing);relay=$dlg_var(relay);sip_code=$dlg_var(sip_code);status_code=$dlg_var(status_code);start_time=$dlg_var(start_time)")<br>
modparam("acc", "cdr_start_on_confirmed", 1)<br>
modparam("acc", "cdr_start_id", "answer_time")<br>
modparam("acc", "log_level", 9)<br>
modparam("acc", "log_facility", "LOG_LOCAL0")<br>
modparam("acc", "log_flag", 10)<br>
modparam("acc", "cdr_facility", "LOG_LOCAL0")<br>
modparam("acc", "cdr_log_enable", 1)<br>
</div>
<div><br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Fri, Oct 14, 2022 at 3:57
PM Daniel-Constantin Mierla <<a
href="mailto:miconda@gmail.com" moz-do-not-send="true"
class="moz-txt-link-freetext">miconda@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div>
<p>Hello,</p>
<p>are you using accounting to generate CDRs with dialog
module (records in acc_cdrs table)? Or only for getting
the event records in the acc table?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div>On 13.10.22 23:19, mayamatakeshi wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div dir="ltr"><br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Mon, Oct 3,
2022 at 11:41 AM mayamatakeshi <<a
href="mailto:mayamatakeshi@gmail.com"
target="_blank" moz-do-not-send="true"
class="moz-txt-link-freetext">mayamatakeshi@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px
0px 0px 0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
<div dir="ltr">
<div dir="ltr"><br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Mon, Sep
26, 2022 at 8:32 PM Daniel-Constantin Mierla
<<a href="mailto:miconda@gmail.com"
target="_blank" moz-do-not-send="true"
class="moz-txt-link-freetext">miconda@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote"
style="margin:0px 0px 0px
0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">Hello,<br>
<br>
as I am not a user of dialog variables, I am
turning to community to ask<br>
for help testing the current master branch
with configurations that make<br>
use of dialog variables and acc dialog-based
cdr generation.<br>
<br>
With a few reports of issues related to
dialog modules and unexpected<br>
crashes, I looked over the code and noticed
that the access of the value<br>
for dialog variables was not protected,
making them vulnerable of<br>
invalid memory access in case of the
variable was updated by another<br>
process or dialog was terminated.<br>
<br>
I introduced a couple of new functions to
try to cover different use<br>
cases of getting the dlg variable values,
dialog management code was not<br>
affected, but given that these commits need
to be backported to stable<br>
branch (5.6), I want to get proper feedback
from community that things<br>
work fine.<br>
<br>
A previous attempt of a simpler fix was not
enough, having side effects<br>
to acc module for dialog-based cdr
generation, because it was keeping<br>
referenced to many dlg variables at the same
time.<br>
<br>
In short, it would be appreciated any
feedback on testing dialog and acc<br>
with dialog-based cdr generation using git
master branch.<br>
<br>
</blockquote>
<div><br>
</div>
<div>I have started 4 load test environments
today with latest
commit 6f400a8074fe60916867596431ca26dff00435d1.</div>
<div>I usually leave a commit load test
running for 2 months before consider it
ready for production release.</div>
<div>I will report any crash/problem.</div>
</div>
</div>
</blockquote>
<div><br>
</div>
<div>After a few hours of load test, all 4 load test
environments start to log memory allocation
problems:</div>
<div><br>
</div>
[root@lab002107-flip-server ~]$ grep memory
/var/log/kamailio/kamailio.log |head<br>
2022-10-13T01:36:10.429809+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: rtpengine [rtpengine.c:2721]:
rtpp_function_call(): out of memory - bencode failed<br>
2022-10-13T01:36:12.923609+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: rtpengine [rtpengine.c:2721]:
rtpp_function_call(): out of memory - bencode failed<br>
2022-10-13T01:36:12.961677+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: acc [acc_extra.c:234]: extra2strar(): could
not allocate private memory from pkg pool<br>
2022-10-13T01:36:14.983281+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: rtpengine [rtpengine.c:2721]:
rtpp_function_call(): out of memory - bencode failed<br>
2022-10-13T01:36:14.983537+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: acc [acc_extra.c:234]: extra2strar(): could
not allocate private memory from pkg pool<br>
2022-10-13T01:36:14.983665+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: acc [acc_extra.c:234]: extra2strar(): could
not allocate private memory from pkg pool<br>
2022-10-13T01:36:20.861558+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: rtpengine [rtpengine.c:2721]:
rtpp_function_call(): out of memory - bencode failed<br>
2022-10-13T01:36:20.864388+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: acc [acc_extra.c:234]: extra2strar(): could
not allocate private memory from pkg pool<br>
2022-10-13T01:36:20.878469+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: acc [acc_extra.c:234]: extra2strar(): could
not allocate private memory from pkg pool<br>
<div>2022-10-13T01:36:23.174159+09:00
lab002107-flip-server
/usr/local/src/git/kamailio-master/src/kamailio[3286370]:
ERROR: rtpengine [rtpengine.c:2721]:
rtpp_function_call(): out of memory - bencode
failed </div>
<div><br>
</div>
<div><br>
</div>
<div>I reverted 2 of the load test envs to previous
kamailio 5.6 commit
61e86a1f502388ffd4dce6e52811ba640337c813 and
restarted the load tests, then again, kamailio
master commit
6f400a8074fe60916867596431ca26dff00435d1 started
to write the above logs but this doesn't happen
with 5.6.</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
</div>
</div>
</blockquote>
<pre cols="72">--
Daniel-Constantin Mierla -- <a href="http://www.asipto.com" target="_blank" moz-do-not-send="true">www.asipto.com</a>
<a href="http://www.twitter.com/miconda" target="_blank" moz-do-not-send="true">www.twitter.com/miconda</a> -- <a href="http://www.linkedin.com/in/miconda" target="_blank" moz-do-not-send="true">www.linkedin.com/in/miconda</a>
Kamailio Advanced Training - Online
Nov 7-10, 2022 (Europe Timezone)
* <a href="https://www.asipto.com/sw/kamailio-advanced-training-online/" target="_blank" moz-do-not-send="true" class="moz-txt-link-freetext">https://www.asipto.com/sw/kamailio-advanced-training-online/</a></pre>
</div>
</blockquote>
</div>
</div>
</blockquote>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a>
<a class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Kamailio Advanced Training - Online
Nov 7-10, 2022 (Europe Timezone)
* <a class="moz-txt-link-freetext" href="https://www.asipto.com/sw/kamailio-advanced-training-online/">https://www.asipto.com/sw/kamailio-advanced-training-online/</a></pre>
</body>
</html>