[Kamailio-Users] problem with relaying invite

Alex Balashov abalashov at evaristesys.com
Mon Oct 13 13:52:18 CEST 2008


The FAILURE-ROUTE is automatically triggered if fr{_inv}_timer expires.

Asim Riaz wrote:

> thanks for that,  this is  incase  my first proxy is canceling the 
> request route to second proxy, what about proxy does not reply at all .
> I can configure the timer using  modparam("tm" , "fr_timer", 20) but how 
> to route call to second if first proxy is timedout ?
> 
> thanks again
> 
> Asim
> 
> 
> 
> On Mon, Oct 13, 2008 at 11:59 AM, Alex Balashov 
> <abalashov at evaristesys.com <mailto:abalashov at evaristesys.com>> wrote:
> 
>     Of course, this is the manual approach for two gateways.  If you
>     have more than two gateways and need to cycle through a list, you
>     may want to consider the dispatcher module. s
> 
> 
> 
>     Alex Balashov wrote:
> 
>         Asim Riaz wrote:
> 
>                  so then what is the posibility to send calls the first
>             proxy if
>                thats fail route to another one and so on ?
> 
> 
>         The possibility is high.  :-)
> 
>         Here - try something like this:
> 
>         route {
> 
>            ...
> 
>            if(is_method("INVITE"))
>               route(1);
> 
>            ...
>         }
> 
> 
>         # -- Relay INVITE -- #
> 
>         route[1] {
>            t_on_failure("1");
> 
>            if(!t_relay("udp:proxy1:5060")) {
>               xlog("L_INFO", "Final relay failure!\n");
>               t_reply("503", "Service Unavailable");
>               exit;
>            }
>         }
> 
>         # -- Backup INVITE route on failure of route(1) -- #
> 
>         failure_route[1] {
>            if(t_was_cancelled()) {
>               xlog("L_INFO", "Transaction cancelled.\n");
>               exit;
>            }
> 
>            append_branch();
> 
>            if(!t_relay("udp:proxy2:5060")) {
>               xlog("L_INFO", "Relay to proxy2 failed - not so good!\n");
>               t_reply("503", "Service Unavailable");
>               exit;
>            }
>         }
> 
> 
> 
>     -- 
>     Alex Balashov
>     Evariste Systems
>     Web    : http://www.evaristesys.com/
>     Tel    : (+1) (678) 954-0670
>     Direct : (+1) (678) 954-0671
>     Mobile : (+1) (706) 338-8599
> 
> 


-- 
Alex Balashov
Evariste Systems
Web    : http://www.evaristesys.com/
Tel    : (+1) (678) 954-0670
Direct : (+1) (678) 954-0671
Mobile : (+1) (706) 338-8599




More information about the Users mailing list