<br><br><div class="gmail_quote">2009/8/19 Daniel-Constantin Mierla <span dir="ltr">&lt;<a href="mailto:miconda@gmail.com">miconda@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello,<div class="im"><br>
<br>
On 17.08.2009 12:25 Uhr, Dmitri G. wrote:<br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im">
<br>
Hello,<br>
<br>
I would like to implement some kind of failover for my Asterisk, let me describe how I would like to see it.<br>
<br>
<br></div>
I registered 2 sip users with my Kamailio, <a href="mailto:1020@domain.com" target="_blank">1020@domain.com</a> &lt;mailto:<a href="mailto:1020@domain.com" target="_blank">1020@domain.com</a>&gt; and <a href="mailto:1030@domain.com" target="_blank">1030@domain.com</a> &lt;mailto:<a href="mailto:1030@domain.com" target="_blank">1030@domain.com</a>&gt;.<br>

I have added aliases to 1020 (aliases from 1021@domain com to <a href="mailto:1029@domain.com" target="_blank">1029@domain.com</a> &lt;mailto:<a href="mailto:1029@domain.com" target="_blank">1029@domain.com</a>&gt;).<div class="im">
<br>
<br>
Right now calls to 1020-1029 goes well to 1020, it works fine.<br>
<br>
But I would like to do the following:<br>
<br>
If 1020 isn&#39;t registered with Kamailio (let&#39;s say if registration for 1020 is down in Kamailio, so AOR not found for 1020), it is possible to route calls to 1030?<br>
So route calls to 1030 only when registration for 1020 isn&#39;t active in Kamailio.<br>
</div></blockquote>
this should be handled in the lookup(&quot;location&quot;) condition:<br>
<br>
if(!lookup(&quot;location&quot;))<br>
{<br>
    if($rU==&quot;1020&quot;)<br>
    {<br>
        $rU=&quot;1030&quot;;<br>
        ....<br>
    }<br>
}<br>
<br>
Cheers,<br><font color="#888888">
Daniel<br>
</font></blockquote></div><br>Thank you for your reply Daniel! It works fine.<br><br>Thanks,<br><br>Dmitri<br>