<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000066">
<p><font face="Courier New, Courier, monospace">Hello;</font></p>
<p><font face="Courier New, Courier, monospace"> it is working
but some braces are missing.</font></p>
<p><font face="Courier New, Courier, monospace">Thanks for support.
Have a nice day.<br>
</font></p>
<p><font face="Courier New, Courier, monospace">[root@TestDispatcher
~]# kamcmd cr.reload_routes<br>
[root@TestDispatcher ~]# kamcmd cr.dump_routes<br>
{<br>
routes: {<br>
{<br>
carrier: default<br>
id: 1<br>
domains: {<br>
{<br>
domain: 185.88.7.201<br>
id: 1<br>
data: {<br>
3:
100.000 %, '192.168.4.180:5060': ON, '0', '2', '1', '338'<br>
}<br>
data: {<br>
}<br>
}<br>
domains: {<br>
}<br>
}<br>
routes: {<br>
}</font></p>
<p><font face="Courier New, Courier, monospace">[root@TestDispatcher
~]# kamctl rpc cr.dump_routes<br>
{"jsonrpc":"2.0","result":{"routes":[{"carrier":"default","id":1,"domains":[{"domain":"myip","id":1,"data":["
3: 100.000 %, '192.168.4.180:5060': ON, '0', '2', '1',
'338'"]}]}]},"id":19726}<br>
[root@TestDispatcher ~]# kamcmd cr.dump_routes<br>
{<br>
routes: {<br>
{<br>
carrier: default<br>
id: 1<br>
domains: {<br>
{<br>
domain: 185.88.7.201<br>
id: 1<br>
data: {<br>
3:
100.000 %, '192.168.4.180:5060': ON, '0', '2', '1', '338'<br>
}<br>
data: {<br>
}<br>
}<br>
domains: {<br>
}<br>
}<br>
routes: {<br>
}<br>
</font><br>
</p>
<br>
<div class="moz-cite-prefix">6.01.2017 10:56 tarihinde
Daniel-Constantin Mierla yazdı:<br>
</div>
<blockquote
cite="mid:171d82f2-9e40-2a33-7511-cd4733a4ddc1@gmail.com"
type="cite">
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<p>Hello,</p>
<p>I think I found the issue -- an improper pointer was passed to
rpc struct_add. Fetch again master and try to see if this time
all goes ok.</p>
<p>Cheers,<br>
Daniel<br>
</p>
<br>
<div class="moz-cite-prefix">On 05/01/2017 09:47, Yasin CANER
wrote:<br>
</div>
<blockquote
cite="mid:dacbf84d-61f2-0f7f-6a31-9f88ee9445fb@netgsm.com.tr"
type="cite">
<meta content="text/html; charset=utf-8"
http-equiv="Content-Type">
<p><font face="Courier New, Courier, monospace">Hello;</font></p>
<p><font face="Courier New, Courier, monospace"> it gives
error as below.</font></p>
<p><font face="Courier New, Courier, monospace">Cheers.<br>
</font></p>
<p><font face="Courier New, Courier, monospace">[root@Test
master]# 10(29238) ERROR: <u>ctl [binrpc_run.c:1112]:
rpc_struct_add(): failed to add attribute-value (S)</u><br>
10(29238) ERROR: carrierroute [cr_fifo.c:1192]:
cr_rpc_dump_routes(): add carrier structure failure at count
0<br>
</font><br>
</p>
<br>
<div class="moz-cite-prefix">5.01.2017 11:17 tarihinde
Daniel-Constantin Mierla yazdı:<br>
</div>
<blockquote
cite="mid:edf10279-a756-311f-f562-d208dfe475aa@gmail.com"
type="cite">
<meta content="text/html; charset=utf-8"
http-equiv="Content-Type">
<p>Hello,</p>
<p>thanks, got some leads with the new log messages, so I
pushed another commit to see which of the fields there is
causing the problem. Can you fetch again master and give it
another try?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<br>
<div class="moz-cite-prefix">On 05/01/2017 09:09, Yasin CANER
wrote:<br>
</div>
<blockquote
cite="mid:79a30fcf-506b-4442-cc1c-763e8c224a4a@netgsm.com.tr"
type="cite">
<meta content="text/html; charset=utf-8"
http-equiv="Content-Type">
<p><font face="Courier New, Courier, monospace">Hello;</font></p>
<p><font face="Courier New, Courier, monospace">Results are
here. Once i tried carrierroute config with kamailio
V4.1.9 and it works. here version is kamailio
5.0.0-dev10 . it is started with "kamailio -dd -E"<br>
</font></p>
<p><font face="Courier New, Courier, monospace"><br>
</font></p>
<p><font face="Courier New, Courier, monospace">[root@Test
master]# kamcmd cr.reload_routes<br>
[root@Test master]# kamcmd cr.dump_routes<br>
error: 500 - Internal error - carrier structure<br>
[root@Test master]#<br>
[root@Test master]#<br>
[root@Test master]# kamctl rpc cr.dump_routes<br>
{"jsonrpc":"2.0","result":{"routes":[{"carrier":,"id":1,"domains":[{"domain":,"id":1,"data":["
NULL: 100.000 %, 'ip:5060': ON, '0', '', '',
'338'"]}]}]},"id":9684}<br>
</font></p>
<p><br>
</p>
<p>here is log</p>
<p><br>
</p>
<p>[root@TestDispatcher master]# 10(9666) INFO: carrierroute
[cr_db.c:315]: load_route_data_db(): carrier 'default' (id
1) has 1 domains<br>
10(9666) INFO: carrierroute [cr_data.c:456]: add_route():
adding prefix , prob 1.000000<br>
10(9666) INFO: carrierroute [cr_carrier.c:98]:
add_domain_data(): adding domain 1 'mydomainip' to carrier
1 'default'10(9666) INFO: carrierroute [cr_data.c:412]:
get_domain_data_or_add(): added domain 1 'mydomainip' to
carrier 1 'default'10(9666) INFO: carrierroute
[cr_data.c:468]: add_route(): found carrier and domain,
now adding route<br>
10(9666) INFO: carrierroute [cr_rule.c:118]:
add_route_rule(): no backed up rules<br>
10(9666) INFO: carrierroute [cr_data.c:653]: rule_fixup():
fixing tree mydomainip<br>
10(9666) INFO: carrierroute [cr_data.c:613]:
rule_fixup_recursor(): hashless rule with host ip:5060
hash, hash_index 1<br>
<u>10(9666) ERROR: ctl [binrpc_run.c:1112]:
rpc_struct_add(): failed to add attribute-value</u><u><br>
</u><u>10(9666) ERROR: carrierroute [cr_fifo.c:1192]:
cr_rpc_dump_routes(): add carrier structure failure at
count 0</u><br>
</p>
<p><br>
</p>
<p>In addition , I tried to modify code like this and it
didnt work either. it gives same error.<br>
</p>
<p><br>
</p>
<p> if(rpc->struct_add(dh, "Sd[",
"carrier", "at",<br>
"id",
"123",<br>
"domains", &eh)<0) {<br>
LM_ERR("add carrier
structure failure at count %d\n", i);<br>
rpc->fault(ctx, 500,
"Internal error - carrier structure");<br>
goto error;<br>
}<br>
<br>
</p>
<br>
<div class="moz-cite-prefix">5.01.2017 00:39 tarihinde
Daniel-Constantin Mierla yazdı:<br>
</div>
<blockquote
cite="mid:578d71c8-4767-1e29-e2c8-983f12b39864@gmail.com"
type="cite">kamctl rpc cr.dump_routes</blockquote>
<br>
<div class="moz-signature">-- <br>
<meta http-equiv="Content-Type" content="text/html;
charset=utf-8">
<title></title>
<div align="left">
<div style="width:300px;" align="left"> <a
moz-do-not-send="true"
href="http://www.netgsm.com.tr" target="_blank"> <img
src="cid:part1.FC51A730.B3C900ED@netgsm.com.tr"
alt"netgsm"="" border="0"> </a> </div>
</div>
</div>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Kamailio World Conference - May 8-10, 2017 - <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.kamailioworld.com">www.kamailioworld.com</a></pre>
</blockquote>
<br>
<div class="moz-signature">-- <br>
<meta http-equiv="Content-Type" content="text/html;
charset=utf-8">
<title></title>
<div align="left">
<div style="width:300px;" align="left"> <a
moz-do-not-send="true" href="http://www.netgsm.com.tr"
target="_blank"> <img
src="cid:part6.CCBE2EBB.904B12D6@netgsm.com.tr"
alt"netgsm"="" border="0"> </a> </div>
</div>
</div>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Kamailio World Conference - May 8-10, 2017 - <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.kamailioworld.com">www.kamailioworld.com</a></pre>
</blockquote>
<br>
<div class="moz-signature">-- <br>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title></title>
<div align="left">
<div style="width:300px;" align="left">
<a href="http://www.netgsm.com.tr" target="_blank">
<img src="cid:part11.72DC50E3.47C6A78F@netgsm.com.tr"
alt"netgsm"="" border="0">
</a>
</div>
</div>
</div>
</body>
</html>