<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<tt>And if you remove the routeid (in the rule definition), does the
routing works ok ?<br>
<br>
Regards,<br>
</tt>
<pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a class="moz-txt-link-freetext" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div class="moz-cite-prefix">On 04/04/2017 05:56 PM, Denis wrote:<br>
</div>
<blockquote cite="mid:2995341491317765@web47g.yandex.ru" type="cite">
<div>No, i don`t</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div>04.04.2017, 16:22, "Bogdan-Andrei Iancu"
<a class="moz-txt-link-rfc2396E" href="mailto:bogdan@opensips.org"><bogdan@opensips.org></a>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF">Do you do an "drop" or "exit" in that
routeid ??
<pre>Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com/">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a moz-do-not-send="true" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div>On 04/04/2017 03:16 PM, Denis wrote:</div>
<blockquote cite="mid:2200711491308210@web4m.yandex.ru"
type="cite">
<div>Bogdan,</div>
<div> </div>
<div>Ok, dr_rules has filled 'routeid' column.</div>
<div>In routeid i, using dialplan, verify dialed prefix for
some reason. If dialed prefix verified i make some action,
if not, returns to the parent route.</div>
<div>In my example, dialed prefix does not verified.</div>
<div> </div>
<div>So, route with do_routing</div>
<div>
<pre style="background-color:#ffffff;color:#000000;font-family:"Courier New";font-size:9,0pt;">951: xlog ("Prepare routing");
952: if (!do_routing("$avp(5)",,,"$avp(300)","$avp(3)",)) {
953: send_reply("404", "Not found");
954: exit;
955: }</pre>
<div>
<pre style="background-color:#ffffff;color:#000000;font-family:"Courier New";font-size:9,0pt;">route [routeid] {
1848: if (dp_translate("20004", "$rU/$rU", "$avp(999)")) {
........
} else {
......
}
1867: }</pre>
</div>
<div> </div>
<div>The last strings for the call flow in syslog:</div>
</div>
<div>
<div> </div>
<div>:951][me][core xlog]</div>
<div>:952][me][module do_routing]</div>
<div>
<div>:1867][me][core if]</div>
<div>:1848][me][module dp_translate]</div>
</div>
<div><a moz-do-not-send="true">INFO:drouting:do_routing</a>:
All the gateways are disabled</div>
<div> </div>
<div>That is all. After that only my CANCEL from the
caller, because there is no provisioning message after
100 Trying from Opensips.</div>
</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div>04.04.2017, 14:14, "Bogdan-Andrei Iancu" <a
moz-do-not-send="true" href="mailto:bogdan@opensips.org"><a class="moz-txt-link-rfc2396E" href="mailto:bogdan@opensips.org"><bogdan@opensips.org></a></a>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF">Hi Denis,<br>
<br>
Again, as drouting is not doing any signalling action,
it CANNOT block/freeze your OpenSIPS.<br>
<br>
Use script_trace() function to see how your INVITE is
handled :<br>
<a moz-do-not-send="true"
href="http://www.opensips.org/Documentation/Script-CoreFunctions-2-2#toc43">http://www.opensips.org/Documentation/Script-CoreFunctions-2-2#toc43</a><br>
<br>
Regards,
<pre>Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com/">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a moz-do-not-send="true" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div>On 03/28/2017 04:46 PM, Denis via Users wrote:</div>
<blockquote cite="mid:8211490708789@web58g.yandex.ru"
type="cite">
<div>In additional,</div>
<div>a part of the opensips.cfg</div>
<div> </div>
<div>
<pre style="background-color:#ffffff;color:#000000;font-family:"Courier New";font-size:9,0pt;">xlog ("Prepare routing");
if (!do_routing("$avp(5)","W",,"$avp(300)","$avp(3)",)) {
send_reply("404", "Not found");
exit;
}</pre>
</div>
<div> </div>
<div>a part of the log</div>
<div> </div>
<div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
Prepare routing</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:drouting:do_routing_1: using weights in GW
selection</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:drouting:do_routing: using dr group 2,
rule_idx 0, username <span><span>88123364021</span></span></div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:drouting:internal_check_rt: found rgid 2 (rule
list 0x7f77f0f63188)</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:dp_translate_f: dpid is 20004
partition is default</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:dp_get_svalue: searching 15</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:dp_translate_f: input is <span><span>88123364021</span></span></div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:dp_translate_f: Checking with dpid
20004</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:translate: Regex operator testing.
Got result: -1</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:translate: No matching rule for input
<span><span>88123364021</span></span></div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialplan:dp_translate_f: could not translate <span><span>88123364021</span></span>
with dpid 20004</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]: <a
moz-do-not-send="true"><a class="moz-txt-link-freetext" href="INFO:drouting:do_routing">INFO:drouting:do_routing</a></a>:
All the gateways are disabled</div>
</div>
<div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:next_state_dlg: unref dlg
0x7f77f3c8bc70 with 1 -> 2 in entry
0x7f77ef003548</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:evi_param_set: adding string param</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:evi_param_set: adding string param</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:evi_param_set: adding int param</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:evi_param_set: adding int param</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:destroy_avp_list: destroying list (nil)</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:next_state_dlg: dialog 0x7f77f3c8bc70
changed from state 1 to state 5, due event 1</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:dlg_onreply: dialog 0x7f77f3c8bc70
failed (negative reply)</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:unref_dlg: unref dlg 0x7f77f3c8bc70
with 1 -> 1 in entry 0x7f77ef003548</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:unref_dlg: unref dlg 0x7f77f3c8bc70
with 1 -> 0 in entry 0x7f77ef003548</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:unref_dlg: ref <=0 for dialog
0x7f77f3c8bc70</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:destroy_dlg: destroying dialog
0x7f77f3c8bc70</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:dialog:destroy_dlg: dlg expired or not in list
- dlg 0x7f77f3c8bc70 [1301:<span><span>1538288757</span></span>]
with clid
'84253MzdiNGJmNzcwYjI1OTE2NmE2ZDUyNGJmZWJiYWQ3NTM'
and tags '2c479443' 'NULL'</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:destroy_avp_list: destroying list
0x7f77f3c8ed08</div>
<div>Mar 28 09:38:28 ubuntu-amd64
/usr/local/opensips2.2/sbin/opensips[7170]:
DBG:core:receive_msg: cleaning up</div>
</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div>28.03.2017, 13:00, "Denis" <<span><a
moz-do-not-send="true"
href="mailto:denis7979@mail.ru"><a class="moz-txt-link-abbreviated" href="mailto:denis7979@mail.ru">denis7979@mail.ru</a></a></span>>:</div>
<blockquote type="cite">
<div>Hello, Bogdan!</div>
<div> </div>
<div>Is there any idea about problem?</div>
<div> </div>
<div>Thank you.</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div>24.03.2017, 07:52, "Denis" <<a
moz-do-not-send="true"
href="mailto:denis7979@mail.ru"><a class="moz-txt-link-abbreviated" href="mailto:denis7979@mail.ru">denis7979@mail.ru</a></a>>:</div>
<blockquote type="cite">
<div>Hello!</div>
<div> </div>
<div>It does not work.</div>
<div>Opensips "freezes" a call.</div>
<div> </div>
<div>In syslog i see "<a moz-do-not-send="true">INFO:drouting:do_routing:
All the gateways are disabled</a>"</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div>23.03.2017, 18:42, "Bogdan-Andrei Iancu" <<a
moz-do-not-send="true"
href="mailto:bogdan@opensips.org"><a class="moz-txt-link-abbreviated" href="mailto:bogdan@opensips.org">bogdan@opensips.org</a></a>>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF">Hi,<br>
<br>
You should do :<br>
if (!do_routing(.......) ) {<br>
send_reply("404","No Route");<br>
exit;<br>
}<br>
<br>
Regards,
<pre>Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com/">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a moz-do-not-send="true" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div>On 03/23/2017 04:21 PM, Denis wrote:</div>
<blockquote
cite="mid:1600201490278865@web19j.yandex.ru"
type="cite">
<div>Hello, Bogdan!</div>
<div> </div>
<div>"test the return code for
do_routing()".</div>
<div>How can i do that?</div>
<div> </div>
<div>I tried</div>
<div>
<pre style="background-color:#ffffff;color:#000000;font-family:"Courier New";font-size:9,0pt;">if (!do_routing("$avp(5)","W",,"$avp(300)","$avp(3)",)) {
xlog ("Route4: Reason = $rc");
}</pre>
</div>
<div>but can see in log only <a
moz-do-not-send="true"><a class="moz-txt-link-rfc2396E" href="INFO:drouting:do_routing:Allthegatewaysaredisabled">"INFO:drouting:do_routing:
All the gateways are disabled"</a></a>.</div>
<div> </div>
<div>Thank you.</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div>20.03.2017, 17:20, "Bogdan-Andrei
Iancu" <a moz-do-not-send="true"
href="mailto:bogdan@opensips.org"><bogdan@opensips.org></a>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF">Failure route does
not help you if your routing does not
start at all - if do_routing() returns
negative. Again, in request route, test
the return code for do_routing() - it
will return a negative code if no
destination is available for routing.<br>
<br>
Regards,
<pre>Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com/">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a moz-do-not-send="true" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div>On 03/20/2017 02:28 PM, Denis
wrote:</div>
<blockquote
cite="mid:6200251490012896@web18g.yandex.ru"
type="cite">
<div>Hello, Bogdan!</div>
<div> </div>
<div>Yes, i know about that.</div>
<div>In failure_route i have
<pre style="background-color:#ffffff;color:#000000;font-family:"Courier New";font-size:9,0pt;">if (($DLG_status == 1) && t_check_status("408"))</pre>
</div>
<div>action. And it works if i have
multiple direction (using
alternative mode) for the prefix.</div>
<div>But when i use only one direction
for the prefix i have the problem
described below.</div>
<div> </div>
<div>Thank you.</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<div>20.03.2017, 15:24, "Bogdan-Andrei
Iancu" <a moz-do-not-send="true"
href="mailto:bogdan@opensips.org"><bogdan@opensips.org></a>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF">Hi Denis,<br>
<br>
I suspect a scripting error on
your side. If all the destinations
are disabled, the do_routing()
returns a negative code into the
script - you need to handle this
case and send back whatever
negative reply you want. The
Drouting modules does not do any
SIP signalling for you.<br>
<br>
Best regards,
<pre>Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com/">http://www.opensips-solutions.com</a>
OpenSIPS Summit May 2017 Amsterdam
<a moz-do-not-send="true" href="http://www.opensips.org/events/Summit-2017Amsterdam.html">http://www.opensips.org/events/Summit-2017Amsterdam.html</a>
</pre>
<div>On 03/17/2017 07:50 AM, Denis
via Users wrote:</div>
<blockquote
cite="mid:1304261489729842@web58g.yandex.ru"
type="cite">
<div>Hello!</div>
<div> </div>
<div>According to drouting
module documentation i am
trying to introduce a probing
feature to control destination
SIP UA access.</div>
<div>Almost everything works
correct, besides one thing.</div>
<div>If i have only one
destination, which became
inaccessible, Opensips
"freezes" a call, i.e. it
sends 100 trying (script
logging) and after does not
sent any code (i expected,
that Opensips will sent 408
code in such situation after
fr_timeout triggering).</div>
<div>Inaccessible destination
has "probing" status and i see
OPTIONS sent by Opensis to
destination.</div>
<div> </div>
<div>Server:: OpenSIPS (2.2.3
(x86_64/linux))</div>
<div> </div>
<div>Thank you for any help.</div>
<div> </div>
<div>-- </div>
<div>С уважением, Денис.</div>
<div>Best regards, Denis</div>
<div> </div>
<div> </div>
<div> </div>
<pre>_______________________________________________
Users mailing list
<a moz-do-not-send="true" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a moz-do-not-send="true" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
</div>
</blockquote>
</blockquote>
</div>
</blockquote>
</blockquote>
</div>
</blockquote>
</blockquote>
</blockquote>
<pre>_______________________________________________
Users mailing list
<a moz-do-not-send="true" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a moz-do-not-send="true" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
</div>
</blockquote>
</blockquote>
</div>
</blockquote>
</blockquote>
<br>
</body>
</html>