Ηι Carsten,<br><br>I added in my failure route the following :<br><br>if (t_check_status("408")) {<br>
ds_mark_dst("i");<br>
}<br><br>and everything works fine.<br><br>Thank you very much for your help<br><br>Alex<br><br><br><br><div class="gmail_quote">On Tue, Nov 16, 2010 at 6:03 PM, Carsten Bock <span dir="ltr"><<a href="mailto:lists@bock.info">lists@bock.info</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">Hi Alex,<br>
<br>
you must have set this to ds_mark_dst("i") instead of "p", only "i"<br>
will set the gateway to inactive.<br>
Also you should add a "t_check_status()" before calling ds_mark_dst()<br>
in order to define the codes, which should lead to the required state,<br>
e.g.:<br>
<br>
if (t_check_status("408|503")) {<br>
ds_mark_dst("p");<br>
}<br>
<br>
So only in case the ds_mark_dst would only be called, if the status of<br>
the transaction was 408 (Request timeout) or 503 (Service<br>
unavailable).<br>
<br>
Please be aware, that the new setting to probing does only apply to<br>
new requests (retransmits to the disabled destination will still occur<br>
until the transaction does timeout).<br>
<br>
We have been using this functionality for several years now and we<br>
never had problems....<br>
<div><div></div><div class="h5"><br>
Carsten<br>
<br>
2010/11/16 alex pappas <<a href="mailto:rebel.pappas@gmail.com">rebel.pappas@gmail.com</a>>:<br>
> Hi Carsten,<br>
><br>
> I tried that before but it's not what I really need. By saying that , when I<br>
> added this function to my failure route then every call failure that<br>
> happened (routing problem let's say) then immediately this GW was set to<br>
> Inactive mode and I was not able to use it.<br>
><br>
> What I'm asking is to understand why Dispatcher module is sending calls to a<br>
> GW in P state?<br>
><br>
> Thanks<br>
><br>
> Alex<br>
><br>
><br>
><br>
> On Tue, Nov 16, 2010 at 3:54 PM, Carsten Bock <<a href="mailto:lists@bock.info">lists@bock.info</a>> wrote:<br>
>><br>
>> Hi Alex,<br>
>><br>
>> do you have a "ds_mark_dst("p")" in your failure route? This needs to<br>
>> be called "threshhold" times in order to set the gateway to probing...<br>
>> And please be aware of timeouts: If you have a Transaction-timeout of<br>
>> e.g. 60 seconds, then the failure-route would be executed after 60<br>
>> seconds and for this time the gateway would stay "active".<br>
>><br>
>> Carsten<br>
>><br>
>><br>
>> 2010/11/16 alex pappas <<a href="mailto:rebel.pappas@gmail.com">rebel.pappas@gmail.com</a>>:<br>
>> > Hi Daniel,<br>
>> ><br>
>> > I have configured that option before i send it the email.<br>
>> > modparam("dispatcher", "ds_probing_threshhold", 2)<br>
>> ><br>
>> > I have gateways A,A,B,C. (A and A is the same gw. I want to send more<br>
>> > calls<br>
>> > that's why is added twice)<br>
>> ><br>
>> > C is the dead gateway. It never responds back to the options because is<br>
>> > not<br>
>> > a real IP.<br>
>> ><br>
>> > When Dispatcher is sending the Invites it always includes the dead gw C<br>
>> > which by the way is in probing mode.<br>
>> ><br>
>> > Doing some test calls i have the following results in send it Invites:<br>
>> ><br>
>> > A, B, A, C<br>
>> > B, A, C, A<br>
>> > A, C, A, B<br>
>> > A, B , A ,C<br>
>> > B, A, C, A<br>
>> > A, C, A, B<br>
>> > A, B , A ,C<br>
>> > B, A, C, A<br>
>> > A, C, A, B<br>
>> > A, B, A, C<br>
>> > B, A, C, A<br>
>> ><br>
>> > As you can see the C dead gw is always included to the Invites send.<br>
>> ><br>
>> > Am i missing something in the configuration?<br>
>> > I also tried to use “9” - use weight based load distribution but with no<br>
>> > success. i got in the logs that this algorithm is not implemented. I'm<br>
>> > doing<br>
>> > something wrong here or is not implemented in this version of Kamailio.<br>
>> > (<br>
>> > 3.0.1)<br>
>> ><br>
>> > Thank you in advance for your help.<br>
>> ><br>
>> > Regards<br>
>> > Alex<br>
>> ><br>
>> ><br>
>> ><br>
>> ><br>
>> > On Fri, Nov 12, 2010 at 10:14 PM, Daniel-Constantin Mierla<br>
>> > <<a href="mailto:miconda@gmail.com">miconda@gmail.com</a>> wrote:<br>
>> >><br>
>> >> Hi Alex,<br>
>> >><br>
>> >> dispatcher module does not send new invites to inactive gateways. But<br>
>> >> in<br>
>> >> case a destination became inactive while some INVITEs were already<br>
>> >> through<br>
>> >> dispatcher, these recent inactive gateways may still be used for them.<br>
>> >><br>
>> >> Regarding the probing mode, dispatcher will never select a probing<br>
>> >> gateway<br>
>> >> as first option to route the call, but they are kept as alternative.<br>
>> >> This is<br>
>> >> the current implementation, we may add a module parameter to skip<br>
>> >> gateways<br>
>> >> in probing mode even for secondary alternatives.<br>
>> >><br>
>> >> Non-responsive gateways change the state after a while, see:<br>
>> >><br>
>> >><br>
>> >> <a href="http://kamailio.org/docs/modules/stable/modules_k/dispatcher.html#id2567110" target="_blank">http://kamailio.org/docs/modules/stable/modules_k/dispatcher.html#id2567110</a><br>
>> >><br>
>> >> Cheers,<br>
>> >> Daniel<br>
>> >><br>
>> >> On 11/12/10 12:58 PM, alex pappas wrote:<br>
>> >><br>
>> >> Dear all,<br>
>> >><br>
>> >> Does anyone can explain how Dispatcher module is sending calls to the<br>
>> >> gateways in the different states?<br>
>> >><br>
>> >> I mean if I have 3 gateways and the one of them is in Probing mode why<br>
>> >> Dispatcher is continuing sending there calls? Why this gateway is not<br>
>> >> changing from Probing to Inactive since is not replaying to OPTIONS<br>
>> >> messages<br>
>> >> send by Kamailio?<br>
>> >><br>
>> >> Configuration:<br>
>> >><br>
>> >> modparam("dispatcher", "flags", 2)<br>
>> >> modparam("dispatcher", "ds_ping_interval", 5)<br>
>> >> modparam("dispatcher", "ds_probing_mode", 1)<br>
>> >> modparam("dispatcher", "ds_probing_threshhold", 2)<br>
>> >> modparam("dispatcher", "dst_avp", "$avp(s:dst_avp)")<br>
>> >> modparam("dispatcher", "grp_avp", "$avp(dsgrp)")<br>
>> >> modparam("dispatcher", "cnt_avp", "$avp(i:202)")<br>
>> >> modparam("dispatcher", "ds_append_branch", 0)<br>
>> >><br>
>> >> using db for gw:<br>
>> >><br>
>> >> setid 123,destination sip:xxx.xxxx.xxx, flag 0 ...<br>
>> >><br>
>> >> in ROUTE:<br>
>> >> if(ds_select_domain("$avp(s:disp_dstgrp)", "4"))<br>
>> >><br>
>> >> in Failure Route<br>
>> >><br>
>> >> if(!ds_next_domain())<br>
>> >><br>
>> >> I want Dispatcher when it sees a node gateway that is dead , to Not<br>
>> >> send<br>
>> >> any other calls.<br>
>> >><br>
>> >> Thank you in advance<br>
>> >><br>
>> >> Alex<br>
>> >><br>
>> >><br>
>> >><br>
>> >> _______________________________________________<br>
>> >> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
>> >> <a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>
>> >> <a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br>
>> >><br>
>> >> --<br>
>> >> Daniel-Constantin Mierla<br>
>> >> <a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a><br>
>> ><br>
>> > _______________________________________________<br>
>> > SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
>> > <a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>
>> > <a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br>
>> ><br>
>> ><br>
>><br>
>><br>
>><br>
>> --<br>
>> Carsten Bock<br>
>> Schomburgstr. 80<br>
>> 22767 Hamburg<br>
>> Germany<br>
>><br>
>> Mobile +49 179 2021244<br>
>> Home +49 40 34927217<br>
>> Fax +49 40 34927218<br>
>> mailto:<a href="mailto:carsten@bock.info">carsten@bock.info</a><br>
><br>
><br>
<br>
<br>
<br>
</div></div>--<br>
<div><div></div><div class="h5">Carsten Bock<br>
Schomburgstr. 80<br>
22767 Hamburg<br>
Germany<br>
<br>
Mobile +49 179 2021244<br>
Home +49 40 34927217<br>
Fax +49 40 34927218<br>
mailto:<a href="mailto:carsten@bock.info">carsten@bock.info</a><br>
</div></div></blockquote></div><br>