I don&#39;t believe 483 really means UNAVAILABLE.  It means &quot;TOO MANY HOPS&quot;.  Somewhere in your script logic you are missing something and it is looping.  You need to ngrep and see what is truly going on and also place some XLOGs in your script to figure this out.  Your IF statement in your Failure Route for 483 will never be true because the <br />      if (!mf_process_maxfwd_header(&quot;5&quot;)) { <br /> <br />            xlog(&quot;L_INFO&quot;,&quot;LOOP [$fd/$fu/$rd/$ru/$si/]\n&quot;); <br /> <br />            sl_send_reply(&quot;483&quot;,&quot;Unavailable&quot;); <br /> <br />            exit; <br /> <br />      } <br />is going to catch it and end the loop. <br /> <br /> <br />On Mar 1, 2011 11:28am, Juri Nysschen &lt;juri@greydotelecom.com&gt; wrote: <br />&gt; Hi All, I am trying to call forward when the destination agent is not registered/available on the proxy. The relevant routes are below.  On a 486 BUSY it works perfectly ! At the top of my route block I have:      if (!mf_process_maxfwd_header(&quot;5&quot;)) {            xlog(&quot;L_INFO&quot;,&quot;LOOP [$fd/$fu/$rd/$ru/$si/]\n&quot;);            sl_send_reply(&quot;483&quot;,&quot;Unavailable&quot;);            exit;      } so if the UA is not registered to the proxy and it cannot find it, 483 is returned on the INVITE. on 483 if I use the same code as on 486:             revert_uri();            prefix(&quot;171&quot;);            rewritehostport(&quot;X.X.X.X:5060&quot;);            t_relay(); It seems to endlessly loop, eventually giving header errors. In both cases the INVITE is called using: do_routing(&quot;1&quot;);lookup(&quot;location&quot;);route(1);exit; What am I missing? Surely it should act the same in both cases.  route[1] {            xlog(&quot;L_INFO&quot;,&quot;Route1 [$fd/$fu/$rd/$ru/$si/]\n&quot;);             if (is_method(&quot;INVITE&quot;)) {                  t_on_branch(&quot;1&quot;);                  t_on_failure(&quot;1&quot;);                  xlog(&quot;L_INFO&quot;,&quot;Route1 INVITE [$fd/$fu/$rd/$ru/$si/]\n&quot;);                  if(has_body(&quot;application/sdp&quot;)){                        xlog(&quot;L_INFO&quot;,&quot;Route1 INVITE has SDP [$fd/$fu/$rd/$ru/$si/]\n&quot;);                        if (rtpproxy_offer()){                              xlog(&quot;L_INFO&quot;,&quot;Route1 INVITE Proxy Offered [$fd/$fu/$rd/$ru/$si/]\n&quot;);                              t_on_reply(&quot;1&quot;);                        }                        else {                              t_on_reply(&quot;3&quot;);                        };                      } else {                        xlog(&quot;L_INFO&quot;,&quot;Route1 INVITE No SDP [$fd/$fu/$rd/$ru/$si/]\n&quot;);                        t_on_reply(&quot;2&quot;);                  }            }                        if (is_method(&quot;ACK&quot;) && has_body(&quot;application/sdp&quot;)){                  xlog(&quot;L_INFO&quot;,&quot;Route1 INVITE ACK with SDP Answer Proxy [$fd/$fu/$rd/$ru/$si/]\n&quot;);                  rtpproxy_answer();            }                             if (is_method(&quot;BYE&quot;)){                  xlog(&quot;L_INFO&quot;,&quot;Route1 BYE [$fd/$fu/$rd/$ru/$si/]\n&quot;);            }                         if (!t_relay()) {                sl_reply_error();        };        }  branch_route[1] {      xlog(&quot;L_INFO&quot;,&quot;Branch Route1  [$fd/$fu/$rd/$ru/$si/]\n&quot;);      setflag(3); # start db accounting} failure_route[1] {    xlog(&quot;L_INFO&quot;,&quot;Failure Route1  [$fd/$fu/$rd/$ru/$si/]\n&quot;);    if (t_was_cancelled()) {            xlog(&quot;L_INFO&quot;,&quot;Failed on Cancel [$fd/$fu/$rd/$ru/$si/]\n&quot;);            exit;    }        if (t_check_status(&quot;6[0-9]&quot;)) {            xlog(&quot;L_INFO&quot;,&quot;Global Failure on Congestion [$fd/$fu/$rd/$ru/$si/]\n&quot;);            exit;    }        if (t_check_status(&quot;486&quot;)){ # Divert on BUSY            xlog(&quot;L_INFO&quot;,&quot;Call Forward on BUSY [$fd/$fu/$rd/$ru/$si/]\n&quot;);            revert_uri();            prefix(&quot;171&quot;);            rewritehostport(&quot;X.X.X.X:5060&quot;);            t_relay();            exit;       };       if (t_check_status(&quot;483&quot;)){ # Divert on UNAVAILABLE            xlog(&quot;L_INFO&quot;,&quot;Call Forward on UNAVAILABLE not available [$fd/$fu/$rd/$ru/$si/]\n&quot;);            exit;      }; }  RegardsJuri Nysschen  <br />&gt;  <br />&gt;