<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Hi,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Looking for some advice running the debugger and setting breakpoints in Kamailio modules such as the SCSCF. 
<o:p></o:p></p>
<p class="MsoNormal">Example: We were trying to watch the authenticate() function:<o:p></o:p></p>
<p class="MsoNormal">714 int authenticate(struct sip_msg* msg, char* _realm, char* str2, int is_proxy_auth) {<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Our Kamailio 5.2.2 code was compiled and linked from source with the -g option already enabled by default.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">We also dropped our Workers to 1 from 16 in the scscf.xml file for the SCSCF to limit the thread count and get the following list of threads below:<o:p></o:p></p>
<p class="MsoNormal">We tried the first cdp threads: 8462, 8463, and 8464 and while we could set a break point at line 714 for the authenticate() function, it didn’t actually break there at all.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Question: <o:p></o:p></p>
<p class="MsoNormal" style="text-indent:.5in">What pid will we use to catch the authenticate() called during an initial registration from a boghe client?<o:p></o:p></p>
<p class="MsoNormal" style="text-indent:.5in">Anything special we may be missing, gdb related or Kamailio settings?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">kamcmd -s /run/kamailio_scscf/kamailio_ctl<o:p></o:p></p>
<p class="MsoNormal">kamcmd 1.5<o:p></o:p></p>
<p class="MsoNormal">Copyright 2006 iptelorg GmbH<o:p></o:p></p>
<p class="MsoNormal">This is free software with ABSOLUTELY NO WARRANTY.<o:p></o:p></p>
<p class="MsoNormal">For details type `warranty'.<o:p></o:p></p>
<p class="MsoNormal">kamcmd> ps<o:p></o:p></p>
<p class="MsoNormal">8456    main process - attendant<o:p></o:p></p>
<p class="MsoNormal">8457    udp receiver child=0 sock=10.0.20.1:6060<o:p></o:p></p>
<p class="MsoNormal">8458    slow timer<o:p></o:p></p>
<p class="MsoNormal">8459    timer<o:p></o:p></p>
<p class="MsoNormal">8460    secondary timer<o:p></o:p></p>
<p class="MsoNormal">8461    ctl handler<o:p></o:p></p>
<p class="MsoNormal">8462    cdp worker child=0<o:p></o:p></p>
<p class="MsoNormal">8463    cdp receiver peer unknown<o:p></o:p></p>
<p class="MsoNormal">8464    cdp_receiver_peer=hss522.irisims.org<o:p></o:p></p>
<p class="MsoNormal">8465    cdp_acceptor<o:p></o:p></p>
<p class="MsoNormal">8466    cdp_timer<o:p></o:p></p>
<p class="MsoNormal">8470    notification_worker<o:p></o:p></p>
<p class="MsoNormal">8471    notification_worker<o:p></o:p></p>
<p class="MsoNormal">8472    notification_worker<o:p></o:p></p>
<p class="MsoNormal">8473    notification_worker<o:p></o:p></p>
<p class="MsoNormal">8477    JSONRPCS FIFO<o:p></o:p></p>
<p class="MsoNormal">8478    JSONRPCS DATAGRAM<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Any advice appreciated.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks,<o:p></o:p></p>
<p class="MsoNormal">Martin Woscek<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>