[sr-dev] LCR: defunct_gw() is dangerous

Klaus Darilion klaus.mailinglists at pernau.at
Tue Jan 24 09:56:54 CET 2012



On 28.12.2011 17:12, Iñaki Baz Castillo wrote:
> 2011/12/28 Juha Heinanen<jh at tutpro.com>

>> further, you could define a
>> timed route, and based on the htable, ping your gws.
>
> Right, but is failure_route executed for those locally sent requests?
> I must check it.

Lat time I tried it the failure route was not triggered. I solved the 
problem by reversing the logic. "Pinging" the gateways every few seconds 
and increase the failure counter with every ping. If I get a response 
(reply routes work fine) I clear the failure counter. If the failure 
counter > 3 I disable the gateway.

It is all possible from kamailio.cfg, although the code is quite complex.

regards
Klaus



More information about the sr-dev mailing list