<div dir="ltr"><div class="gmail_extra"><div>Hello Daniel,</div><div><br></div><div>Thanks for you reply.</div><div><br></div><div>I checked again and I am using the version 5.0.4 from the debian packages for debian (bellow there is the output of some commands to confirm this).</div><div><br>I also reboot the machine, but i still have the same problem with the same output on gdb.</div><div><br></div><div><br>Best Regards,<br>Jose Lopes<br></div><div><br></div><div><br></div><div># dpkg -S /usr/sbin/kamcmd<br>kamailio: /usr/sbin/kamcmd</div><div><br></div><div># dpkg -l | grep kamailio<br>ii kamailio 5.0.4+jessie amd64 very fast, dynamic and configurable SIP server<br>ii kamailio-dbg:amd64 5.0.4+jessie amd64 very fast and configurable SIP server [debug symbols]<br>ii kamailio-lua-modules:amd64 5.0.4+jessie amd64 The app_lua module for Kamailio Lua support<br>ii kamailio-mysql-modules:amd64 5.0.4+jessie amd64 MySQL database connectivity module for Kamailio<br>ii kamailio-redis-modules:amd64 5.0.4+jessie amd64 Redis database connectivity module for the Kamailio SIP server<br></div><div><br></div><div>kamcmd> root@abccs-s1gww1:/tmp# /usr/sbin/kamcmd version <br>kamailio 5.0.4 (x86_64/linux) <br></div><br clear="all"><br><div class="gmail_quote">On Tue, Nov 21, 2017 at 6:38 PM, Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div bgcolor="#FFFFFF">
<p>Hello,</p>
<p>are you sure that kamcmd was compiled with the 5.0.4 version? In
branch 5.0, at kamcmd.c line 591 is a line with just a curly
brace, then one starting the send_binrpc_cmd function, so that's
not a line that can cause a segfault.</p>
<p>Cheers,<br>
Daniel<br>
</p><div><div class="gmail-m_7292642528848176147h5">
<br>
<div class="gmail-m_7292642528848176147m_-6597086524060878202moz-cite-prefix">On 21.11.17 17:48, José Lopes wrote:<br>
</div>
</div></div><blockquote type="cite"><div><div class="gmail-m_7292642528848176147h5">
<div dir="ltr">
<div>
<div>
<div>Hello,<br>
</div>
<div><br>
</div>
<div>I invoke kamcmd inside Freeswitch Lua Scripts and right
now i am getting segmentation fault any time.</div>
<div>This started to happen after I upgraded kamailio from
4.4 to 5.0.4 .</div>
<br>
</div>
I tried to analyse the core dump and it give me the next
information.<br>
</div>
When I execute on the console, the command works.<br>
<br>
<div>Am I doing something wrong?</div>
<div>There is any alternative or better way to communicate with
kamailio?</div>
<div><br>
</div>
<div>Thanks in advance</div>
<div><br>
</div>
<div>Best regards,</div>
<div>Jose Lopes<br>
</div>
<div>
<div>
<div>
<div><br>
</div>
<div><br>
</div>
<div>Core was generated by `/usr/sbin/kamcmd -s udp:<a href="http://127.0.0.1:2050" target="_blank">127.0.0.1:2050</a>
uac.reg_refresh s:29010017'.<br>
Program terminated with signal SIGSEGV, Segmentation
fault.<br>
#0 0x000000000040340d in send_binrpc_cmd (s=<error
reading variable: Cannot access memory at address
0x7ffec894a60c>, cmd=<error reading variable:
Cannot access memory at address 0x7ffec894a600>, <br>
cookie=<error reading variable: Cannot access
memory at address 0x7ffec894a608>) at kamcmd.c:591<br>
591 kamcmd.c: No such file or directory.<br>
(gdb) bt<br>
#0 0x000000000040340d in send_binrpc_cmd (s=<error
reading variable: Cannot access memory at address
0x7ffec894a60c>, cmd=<error reading variable:
Cannot access memory at address 0x7ffec894a600>, <br>
cookie=<error reading variable: Cannot access
memory at address 0x7ffec894a608>) at kamcmd.c:591<br>
#1 0x0000000000403eee in run_binrpc_cmd (s=3,
cmd=0x7ffec898a8d0, fmt=0x0) at kamcmd.c:924<br>
#2 0x0000000000404499 in run_cmd (s=3,
cmd=0x7ffec898a8d0, format=0x0) at kamcmd.c:1068<br>
#3 0x00000000004073aa in main (argc=5,
argv=0x7ffec898d1e8) at kamcmd.c:2114<br>
<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>
<div>
<div class="gmail-m_7292642528848176147m_-6597086524060878202gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div dir="ltr">
<div style="font-size:12.8px">
<div dir="ltr" style="font-size:12.8px">
<table style="color:rgb(80,0,80);font-size:12.8px;font-family:Arial,Helvetica,sans-serif;width:600px;border-collapse:collapse">
<tbody>
<tr>
<td style="font-size:13px;color:black">
<table style="color:rgb(34,34,34);font-size:12.7273px;font-family:Arial,Helvetica,sans-serif;width:600px;border-collapse:collapse">
<tbody>
<tr>
<td style="line-height:15px"><br>
</td>
</tr>
<tr>
<td style="line-height:15px"><br>
</td>
</tr>
<tr style="display:block;width:600px;margin-top:10px">
<td style="width:600px;padding:0px"><br>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div style="font-size:12.8px"><br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
<fieldset class="gmail-m_7292642528848176147m_-6597086524060878202mimeAttachmentHeader"></fieldset>
<br>
</div></div><pre>______________________________<wbr>_________________
Kamailio (SER) - Users Mailing List
<a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-abbreviated" href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>
<a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-freetext" href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">https://lists.kamailio.org/cgi<wbr>-bin/mailman/listinfo/sr-users</a><span class="gmail-m_7292642528848176147HOEnZb"><font color="#888888">
</font></span></pre><span class="gmail-m_7292642528848176147HOEnZb"><font color="#888888">
</font></span></blockquote><span class="gmail-m_7292642528848176147HOEnZb"><font color="#888888">
<br>
<pre class="gmail-m_7292642528848176147m_-6597086524060878202moz-signature" cols="72">--
Daniel-Constantin Mierla
<a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-abbreviated" href="http://www.twitter.com/miconda" target="_blank">www.twitter.com/miconda</a> -- <a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda" target="_blank">www.linkedin.com/in/miconda</a>
Kamailio Advanced Training - <a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-abbreviated" href="http://www.asipto.com" target="_blank">www.asipto.com</a>
Kamailio World Conference - May 14-16, 2018 - <a class="gmail-m_7292642528848176147m_-6597086524060878202moz-txt-link-abbreviated" href="http://www.kamailioworld.com" target="_blank">www.kamailioworld.com</a></pre>
</font></span></div>
</blockquote></div><br></div></div>