[SR-Users] disparcher making loop with call

David Villasmil david.villasmil.work at gmail.com
Fri Nov 22 12:11:30 CET 2019


Hello,

You’re only pasting the dispatcher route.

You need to follow the script logic. An invite comes in, how does it know
the call is coming from the client and has to be sent to freeSWITCH?
Conversely, how does it know it’s coming from freeswitch?

Probably using the permissions module with
https://kamailio.org/docs/modules/3.1.x/modules_k/permissions.html#id2528655

You can check if the $si is the freeswitch, then send to clientB

On Fri, 22 Nov 2019 at 11:40, Daniel-Constantin Mierla <miconda at gmail.com>
wrote:

> Hello,
>
> there is something wrong in your config file, failing to detect the
> traffic from freeswitch. Load debugger module and enable cfgtrace logging,
> then see what actions are executed in the configuration file, maybe you can
> spot what goes wrong there.
>
> Otherwise, to get more help from the mailing lists, the full config is
> needed.
>
> Cheers,
> Daniel
> On 22.11.19 09:51, Gaurav Bmotra wrote:
>
> hi
> i m using kamailio 5.3 as register server and using dispatcher i m dendign
> the calls to freeswitch ..
>
> but the issue is then freeswitch send back call to kamailio after
> processing media ... it should go back to client but it again send call to
> freeswitch ,, which create the loop and hangup the call with (Temporarily
> Unavailable (code: 480))
>
>
> *what i want  *client1------>Kamailio------>FS-----Kamailio----->Client2
>
> *but I am getting this *
> client1------>Kamailio------>FS-----Kamailio----->FS----->kamailio----->FS
>
>
> *Routing Logic *-------------------------------
> if(!ds_is_from_list()) {
>
>    route(DISPATCH);
>                                                         }
>
> --------
> # Dispatch requests
>
>
> route[DISPATCH] {
>
>
>         # round robin dispatching on gateways group '1'
>
>
>         if(!ds_select_dst("1", "4")) {
>
>
>                 send_reply("404", "No destination");
>
>
>                 exit;
>
>
>         }
>
>
>         xdbg("--- SCRIPT: going to <$ru> via <$du> (attrs:
> $xavp(_dsdst_=>attrs))\n");
>
>
>         t_on_failure("RTF_DISPATCH");
>
>
>         route(RELAY);
>
>
>         exit;
>
>
> }
>
>
>
>
>
> # Try next destionations in failure route
>
>
> failure_route[RTF_DISPATCH] {
>
>
>         xnotice("RTF_DISPATCH: $rm $rU [$ci]");
>
>
>         if (t_is_canceled()) {
>
>
>                 exit;
>
>
>         }
>
>
>         # next DST - only for 500 or local timeout
>
>
>         if (t_check_status("(^5)")
>
>
>                         or (t_branch_timeout() and !t_branch_replied())) {
>
>
>                 xnotice("RTF_DISPATCH: WARNING $du is broken and marked as
> inactive");
>
>                  # ds_mark_dst("ip");
>
>
>                 if(ds_next_dst()) {
>
>
>                         #xdbg("--- SCRIPT: retrying to <$ru> via <$du>
> (attrs: $xavp(_dsdst_=>attrs))\n");
>
>
>                         t_on_failure("RTF_DISPATCH");
>
>
>                         route(RELAY);
>
>
>                         exit;
>
>
>                 }
>
>
>         }
>
>
> }
>
>
> --
> thank you
>
>
>
>
>
>
>
> *Regards:*
> Gaurav Kumar
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing Listsr-users at lists.kamailio.orghttps://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
> --
> Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
> Kamailio World Conference - April 27-29, 2020, in Berlin -- www.kamailioworld.com
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
-- 
Regards,

David Villasmil
email: david.villasmil.work at gmail.com
phone: +34669448337
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20191122/1b958148/attachment.html>


More information about the sr-users mailing list