<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Hello Daniel,<div><br></div><div>I compiled and i'm testing 5.2, but it doesn't seem to be doing what I was expecting, my config is as follows:</div><div><br></div><div><div><font face="monospace, monospace">route[DISPATCH] {</font></div><div><font face="monospace, monospace"> dp_match("1", "$ru");</font></div><div><font face="monospace, monospace"><br></font></div><div><font face="monospace, monospace"> if(!ds_select_routes("1=4;11=9", "ruri", "10"))</font></div><div><font face="monospace, monospace"> {</font></div><div><font face="monospace, monospace"> send_reply("404", "No destination");</font></div><div><font face="monospace, monospace"> exit;</font></div><div><font face="monospace, monospace"> } else {</font></div><div><font face="monospace, monospace"> xlog("[DISPATCH] ds_select_dst was succesful\n");</font></div><div><font face="monospace, monospace"> }</font></div><div><font face="monospace, monospace"> xlog("L_DBG", "--- SCRIPT: going to <$ru> via <$du>\n");</font></div><div><font face="monospace, monospace"> t_on_failure("RTF_DISPATCH");</font></div><div><font face="monospace, monospace"> route(RELAY);</font></div><div><font face="monospace, monospace"> exit;</font></div><div><font face="monospace, monospace">}</font></div></div><div><br></div><div>And my table is:</div><div><br></div><div><div><font face="monospace, monospace">+----+-------+------------------------------------+-------+----------+----------------------------+-------------+</font></div><div><font face="monospace, monospace">| id | setid | destination | flags | priority | attrs | description |</font></div><div><font face="monospace, monospace">+----+-------+------------------------------------+-------+----------+----------------------------+-------------+</font></div><div><div><font face="monospace, monospace">| 213 | 1 | sip:<a href="http://34.201.28.49:5080">34.201.28.49:5080</a> | 0 | 10 | weight=100 | node1-proxy |</font></div><div><font face="monospace, monospace">| 229 | 1 | sip:<a href="http://54.209.229.198:5080">54.209.229.198:5080</a> | 0 | 10 | weight=100 | node2-proxy |</font></div><div><font face="monospace, monospace">| 232 | 11 | sip:<a href="http://35.170.67.206:5080">35.170.67.206:5080</a> | 0 | 10 | weight=100 | node3-proxy |</font></div></div><div><span style="font-family:monospace,monospace">+----+-------+------------------------------------+-------+----------+----------------------------+-------------+</span><br></div></div><div><br></div><div>But kamailio is always sending to the same ip 198, although it should be load-balancing round-robin to the 2 nodes on setid 1. And when those 2 nodes have 10 calls, then start sending to setid 11.</div><div><br></div><div>Is my config wrong?</div><div><br clear="all"><div><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Regards,</div><div><br></div>David Villasmil<div>email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank">david.villasmil.work@gmail.com</a></div><div>phone: +34669448337</div></div></div></div><br></div></div></div></div></div><div hspace="streak-pt-mark" style="max-height:1px"><img alt="" style="width:0px;max-height:0px;overflow:hidden" src="https://mailfoogae.appspot.com/t?sender=aZGF2aWQudmlsbGFzbWlsLndvcmtAZ21haWwuY29t&type=zerocontent&guid=9c3fcaae-7d67-4d0d-9ff2-8761604bead6"><font color="#ffffff" size="1">ᐧ</font></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Nov 15, 2018 at 4:09 PM David Villasmil <<a href="mailto:david.villasmil.work@gmail.com">david.villasmil.work@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Ah, 5.2 branch. Will test it, thanks!<br><br><div class="gmail_quote"><div dir="ltr">On Thu, 15 Nov 2018 at 16:06, Daniel-Constantin Mierla <<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<p>Hello,</p>
<p>besides master, you can also use branch 5.2 -- this is going to
be used to release 5.2.0 and other future 5.2.x versions. Those
two branches have the same version of the module at this moment.<br>
</p>
<p>Cheers,<br>
Daniel<br>
</p></div><div text="#000000" bgcolor="#FFFFFF">
<div class="m_5982409531991712506m_4811850720338942491moz-cite-prefix">On 15.11.18 16:48, David Villasmil
wrote:<br>
</div>
<blockquote type="cite">
Hey Daniel,<br>
<br>
Thanks for replying. Can I test this from master?<br>
<br>
David<br>
<div class="gmail_quote">
<div dir="ltr">On Thu, 15 Nov 2018 at 15:12, Daniel-Constantin
Mierla <<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>> wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
<br>
On 14.11.18 23:16, David Villasmil wrote:<br>
> Hello,<br>
><br>
> Is it possible to set an algorithm like the following?<br>
><br>
> fs1 - Priority 10 - maxload 20 calls<br>
> fs2 - Priority 10 - maxload 20 calls<br>
> fs3 - Priority 9 - maxload 20 calls<br>
> fs4 - Priority 8 - maxload 20 calls<br>
> fs5 - Priority 7 - maxload 20 calls<br>
><br>
> So that, whenever any new call comes in, fs1 and fs2
would be used,<br>
> meaning the fs with the highest priority would be use
UNLESS there's<br>
> 20 calls on that server, in which case, the next server
with the<br>
> highest priority would be used.<br>
><br>
this should be easier possible with the upcoming 5.2.0 (to be
released<br>
in about 2 weeks or so), see:<br>
<br>
-<br>
<a href="https://www.kamailio.org/docs/modules/devel/modules/dispatcher.html#dispatcher.f.ds_select_routes" rel="noreferrer" target="_blank">https://www.kamailio.org/docs/modules/devel/modules/dispatcher.html#dispatcher.f.ds_select_routes</a><br>
<br>
For older versions you may need to do more complex logic in
the<br>
configuration file to call dispatcher for different groups at
different<br>
stages of failure re-routing.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
-- <br>
Daniel-Constantin Mierla -- <a href="http://www.asipto.com" rel="noreferrer" target="_blank">www.asipto.com</a><br>
<a href="http://www.twitter.com/miconda" rel="noreferrer" target="_blank">www.twitter.com/miconda</a>
-- <a href="http://www.linkedin.com/in/miconda" rel="noreferrer" target="_blank">www.linkedin.com/in/miconda</a><br>
Kamailio World Conference -- <a href="http://www.kamailioworld.com" rel="noreferrer" target="_blank">www.kamailioworld.com</a><br>
Kamailio Advanced Training, Nov 12-14, 2018, in Berlin -- <a href="http://www.asipto.com" rel="noreferrer" target="_blank">www.asipto.com</a><br>
<br>
</blockquote>
</div>
</blockquote>
<pre class="m_5982409531991712506m_4811850720338942491moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="m_5982409531991712506m_4811850720338942491moz-txt-link-abbreviated" href="http://www.asipto.com" target="_blank">www.asipto.com</a>
<a class="m_5982409531991712506m_4811850720338942491moz-txt-link-abbreviated" href="http://www.twitter.com/miconda" target="_blank">www.twitter.com/miconda</a> -- <a class="m_5982409531991712506m_4811850720338942491moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda" target="_blank">www.linkedin.com/in/miconda</a>
Kamailio World Conference -- <a class="m_5982409531991712506m_4811850720338942491moz-txt-link-abbreviated" href="http://www.kamailioworld.com" target="_blank">www.kamailioworld.com</a>
Kamailio Advanced Training, Nov 12-14, 2018, in Berlin -- <a class="m_5982409531991712506m_4811850720338942491moz-txt-link-abbreviated" href="http://www.asipto.com" target="_blank">www.asipto.com</a></pre>
</div>
</blockquote></div>
</blockquote></div>