<div dir="ltr">Yes<div><br></div><div>If either of the t_next_contacts are executed, they fail.</div><div><br></div><div>If they are removed from the routing logic, the calls are completing, but not reliably as, as the least, some SIP packets like BYE are being dropped.</div>
<div><br></div><div> here is a snippet:<div><div>        $avp(oexten) = $rU;</div><div>        if (!lookup("location")) {</div><div>                $var(rc) = $rc;</div><div>                route(TOVOICEMAIL);</div>
<div>                t_newtran();</div><div>                switch ($var(rc)) {</div><div>                        case -1:</div><div>                        case -3:</div><div>                                send_reply("404", "2 Not Found");</div>
<div>                                exit;</div><div>                        case -2:</div><div>                                send_reply("405", "Method Not Allowed");</div><div>                                exit;</div>
<div>                }</div><div>        }</div><div><br></div><div>        if (!t_load_contacts()) {</div><div>                send_reply("500", "1 Server Internal Error");</div><div>                exit;</div>
<div>        }</div><div><br></div><div>       if (!t_next_contacts()) {</div><div>               send_reply("500", "2 Server Internal Error");</div><div>               exit;</div><div>       }</div><div>
<br></div><div>       t_on_failure("FAIL_OUTBOUND");</div></div><div><br></div><div>and another</div><div><div><br></div><div># manage failure routing cases</div><div>failure_route[FAIL_OUTBOUND] {</div><div>        if (t_check_status("408|430")) {</div>
<div>                if (!t_next_contact_flows() && !t_next_contacts()) {</div><div>                        send_reply("500", "3 Server Internal Error");</div><div>                        exit;</div>
<div>                }</div><div>        } else if (!t_next_contacts()) {</div><div>                send_reply("500", "4 Server Internal Error");</div><div>                exit;</div><div>        }</div>
<div><br></div><div>        t_on_failure("FAIL_OUTBOUND");</div><div>        route(RELAY);</div><div>}</div></div><div><br></div><div><br></div><div>Thanks!</div><div><br></div><div>- Coy</div><div><br></div></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Oct 21, 2013 at 3:17 PM, Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    Hello,<br>
    <br>
    before using t_load_contacts()/t_next_contacts(), you have to use
    lookup("location");<br>
    <br>
    Do you have that one, too?<br>
    <br>
    Cheers,<br>
    Daniel<div><div class="h5"><br>
    <br>
    <div>On 10/17/13 11:40 PM, Coy Cardwell
      wrote:<br>
    </div>
    </div></div><blockquote type="cite"><div><div class="h5">
      <div dir="ltr">Hello again.
        <div><br>
        </div>
        <div>Compiling from source, using the proxy-to-central registrar
          configurations outlined here <a href="http://www.kamailio.org/docs/modules/4.0.x/modules/outbound.html" target="_blank">http://www.kamailio.org/docs/modules/4.0.x/modules/outbound.html</a> and
          adding in the additional "append_hf("Supported: path,
          outbound\r\n");" on the proxy, registration works.</div>
        <div><br>
        </div>
        <div>However, when a call is made, the debug traces show
          problems when entering this area of the configuration outlined
          in the Outbound Module:</div>
        <div><br>
        </div>
        <div>
          <pre style="padding-left:15pt;background-color:rgb(254,254,238);border:1px solid rgb(153,204,204)">   if (!t_load_contacts()) {
                send_reply("500", "Server Internal Error");
                exit;
        }

        if (!t_next_contacts()) {
                send_reply("500", "Server Internal Error");
                exit;
        }
</pre>
        </div>
        <div>as shown here:</div>
        <div>
          <div>1(26960) ERROR: *** cfgtrace:
            c=[//etc/kamailio/kamailio.cfg] l=700 a=16 n=if</div>
          <div> 1(26960) ERROR: *** cfgtrace:
            c=[//etc/kamailio/kamailio.cfg] l=695 a=24 n=t_load_contacts</div>
          <div> 1(26960) DEBUG: tm [t_serial.c:166]: t_load_contacts():
            nr_branches is 0</div>
          <div> 1(26960) DEBUG: tm [t_serial.c:169]: t_load_contacts():
            nothing to do - only one contact!</div>
          <div> 1(26960) ERROR: *** cfgtrace:
            c=[//etc/kamailio/kamailio.cfg] l=705 a=16 n=if</div>
          <div> 1(26960) ERROR: *** cfgtrace:
            c=[//etc/kamailio/kamailio.cfg] l=700 a=24 n=t_next_contacts</div>
          <div> 1(26960) DEBUG: tm [t_serial.c:376]: t_next_contacts():
            no contacts in contacts_avp - we are done!</div>
          <div> 1(26960) ERROR: *** cfgtrace:
            c=[//etc/kamailio/kamailio.cfg] l=701 a=26 n=send_reply</div>
        </div>
        <div><br>
        </div>
        <div>The result from t_load_contacts seems to imply one contact
          exists, which would be correct as there should be one, but
          then t_next_contacts sees no cotacts and the sever returns an
          error, breaking the call.</div>
        <div><br>
        </div>
        <div>Any ideas?</div>
        <div><br>
        </div>
      </div>
      <br>
      <fieldset></fieldset>
      <br>
      </div></div><pre>_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a>
<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><span class="HOEnZb"><font color="#888888">
</font></span></pre><span class="HOEnZb"><font color="#888888">
    </font></span></blockquote><span class="HOEnZb"><font color="#888888">
    <br>
    <pre cols="72">-- 
Daniel-Constantin Mierla - <a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a>
<a href="http://twitter.com/#!/miconda" target="_blank">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda" target="_blank">http://www.linkedin.com/in/miconda</a>
Kamailio Advanced Trainings - Berlin, Nov 25-28; Miami, Nov 18-20, 2013
  - more details about Kamailio trainings at <a href="http://www.asipto.com" target="_blank">http://www.asipto.com</a> -
</pre>
  </font></span></div>

<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></blockquote></div><br></div>