<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>
<div>freeswitch@internal&gt; version<br/>
FreeSWITCH Version 1.5.15b+git~20150220T192157Z~9a6c29f8f7~64bit (git 9a6c29f 2015-02-20 19:21:57Z 64bit)</div>

<div>&nbsp;</div>

<div>
<div>freeswitch@internal&gt; originate {fail_on_single_reject=USER_BUSY}error/NO_ANSWER&#124;error/NO_ROUTE_DESTINATION&#124;error/USER_BUSY&#124;error/SERVICE_UNAVAILABLE 999<br/>
-ERR USER_BUSY</div>

<div>2015-02-20 21:56:36.324455 [DEBUG] switch_ivr_originate.c:2100 Parsing global variables<br/>
2015-02-20 21:56:36.324455 [DEBUG] switch_event.c:1688 Parsing variable [fail_on_single_reject]=[USER_BUSY]<br/>
2015-02-20 21:56:36.324455 [NOTICE] switch_ivr_originate.c:2732 Cannot create outgoing channel of type [error] cause: [NO_ANSWER]<br/>
2015-02-20 21:56:36.324455 [DEBUG] switch_ivr_originate.c:3720 Originate Resulted in Error Cause: 19 [NO_ANSWER]<br/>
2015-02-20 21:56:36.324455 [NOTICE] switch_ivr_originate.c:2732 Cannot create outgoing channel of type [error] cause: [NO_ROUTE_DESTINATION]<br/>
2015-02-20 21:56:36.324455 [DEBUG] switch_ivr_originate.c:3720 Originate Resulted in Error Cause: 3 [NO_ROUTE_DESTINATION]<br/>
2015-02-20 21:56:36.324455 [NOTICE] switch_ivr_originate.c:2732 Cannot create outgoing channel of type [error] cause: [USER_BUSY]<br/>
freeswitch@internal&gt;</div>

<div>&nbsp;</div>

<div>is OK</div>

<div>&nbsp;</div>

<div>now trying on real channels:</div>
</div>

<div>&nbsp;</div>

<div>freeswitch@internal&gt; originate {fail_on_single_reject=USER_BUSY}sofia/external/1111@1.1.1.1&#124;sofia/external/2222@2.2.2.2 999<br/>
-ERR USER_BUSY</div>

<div>&nbsp;</div>

<div>
<div>2015-02-20 21:47:19.524442 [DEBUG] switch_ivr_originate.c:2100 Parsing global variables<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_event.c:1688 Parsing variable [fail_on_single_reject]=[USER_BUSY]<br/>
2015-02-20 21:47:19.524442 [NOTICE] switch_channel.c:1055 New Channel sofia/external/1111@1.1.1.1 [0b3dc328-b94a-11e4-b8f0-2ddfb755c79b]<br/>
2015-02-20 21:47:19.524442 [DEBUG] mod_sofia.c:4701 (sofia/external/1111@1.1.1.1) State Change CS_NEW -&gt; CS_INIT<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_session.c:1396 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:472 (sofia/external/1111@1.1.1.1) Running State Change CS_INIT<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:512 (sofia/external/1111@1.1.1.1) State INIT<br/>
2015-02-20 21:47:19.524442 [DEBUG] mod_sofia.c:87 sofia/external/1111@1.1.1.1 SOFIA INIT<br/>
2015-02-20 21:47:19.524442 [DEBUG] sofia_glue.c:1232 sofia/external/1111@1.1.1.1 sending invite version: 1.5.15b git 9a6c29f 2015-02-20 19:21:57Z 64bit<br/>
Local SDP:<br/>
v=0<br/>
o=FreeSWITCH 1424445415 1424445416 IN IP4 3.3.3.3<br/>
s=FreeSWITCH<br/>
c=IN IP4 3.3.3.3<br/>
t=0 0<br/>
m=audio 23424 RTP/AVP 18 8 0 101 13<br/>
a=rtpmap:8 PCMA/8000<br/>
a=rtpmap:0 PCMU/8000<br/>
a=rtpmap:101 telephone-event/8000<br/>
a=fmtp:101 0-16<br/>
a=ptime:20<br/>
a=sendrecv</div>

<div>2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:40 sofia/external/1111@1.1.1.1 Standard INIT<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:48 (sofia/external/1111@1.1.1.1) State Change CS_INIT -&gt; CS_ROUTING<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_session.c:1396 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:512 (sofia/external/1111@1.1.1.1) State INIT going to sleep<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:472 (sofia/external/1111@1.1.1.1) Running State Change CS_ROUTING<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:528 (sofia/external/1111@1.1.1.1) State ROUTING<br/>
2015-02-20 21:47:19.524442 [DEBUG] mod_sofia.c:123 sofia/external/1111@1.1.1.1 SOFIA ROUTING<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_ivr_originate.c:67 (sofia/external/1111@1.1.1.1) State Change CS_ROUTING -&gt; CS_CONSUME_MEDIA<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_session.c:1396 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:528 (sofia/external/1111@1.1.1.1) State ROUTING going to sleep<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:472 (sofia/external/1111@1.1.1.1) Running State Change CS_CONSUME_MEDIA<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:547 (sofia/external/1111@1.1.1.1) State CONSUME_MEDIA<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_state_machine.c:547 (sofia/external/1111@1.1.1.1) State CONSUME_MEDIA going to sleep<br/>
2015-02-20 21:47:19.524442 [DEBUG] switch_core_session.c:1061 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.524442 [DEBUG] sofia.c:6623 Channel sofia/external/1111@1.1.1.1 entering state [calling][0]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_session.c:1061 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_session.c:1061 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_session.c:1061 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.584431 [DEBUG] sofia.c:5851 Remote Reason: 17<br/>
2015-02-20 21:47:19.584431 [DEBUG] sofia.c:6623 Channel sofia/external/1111@1.1.1.1 entering state [terminated][486]<br/>
2015-02-20 21:47:19.584431 [NOTICE] sofia.c:7539 Hangup sofia/external/1111@1.1.1.1 [CS_CONSUME_MEDIA] [USER_BUSY]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_channel.c:3222 Send signal sofia/external/1111@1.1.1.1 [KILL]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_session.c:1396 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:472 (sofia/external/1111@1.1.1.1) Running State Change CS_HANGUP<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:735 (sofia/external/1111@1.1.1.1) Callstate Change DOWN -&gt; HANGUP<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:737 (sofia/external/1111@1.1.1.1) State HANGUP<br/>
2015-02-20 21:47:19.584431 [DEBUG] mod_sofia.c:413 Channel sofia/external/1111@1.1.1.1 hanging up, cause: USER_BUSY<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:60 sofia/external/1111@1.1.1.1 Standard HANGUP, cause: USER_BUSY<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:737 (sofia/external/1111@1.1.1.1) State HANGUP going to sleep<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:504 (sofia/external/1111@1.1.1.1) State Change CS_HANGUP -&gt; CS_REPORTING<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_session.c:1396 Send signal sofia/external/1111@1.1.1.1 [BREAK]<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:472 (sofia/external/1111@1.1.1.1) Running State Change CS_REPORTING<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_core_state_machine.c:823 (sofia/external/1111@1.1.1.1) State REPORTING<br/>
2015-02-20 21:47:19.584431 [DEBUG] switch_ivr_originate.c:3720 Originate Resulted in Error Cause: 17 [USER_BUSY]<br/>
2015-02-20 21:47:19.584431 [NOTICE] switch_channel.c:1055 New Channel sofia/external/2222@2.2.2.2 [0b472918-b94a-11e4-b8f3-2ddfb755c79b]</div>

<div>&nbsp;</div>
</div>

<div>Thanks / Mike
<div name="quote" style="margin:10px 5px 5px 10px; padding: 10px 0 10px 10px; border-left:2px solid #C3D9E5; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="margin:0 0 10px 0;"><b>Sent:</b>&nbsp;Friday, February 20, 2015 at 10:40 PM<br/>
<b>From:</b>&nbsp;&quot;Brian West&quot; &lt;brian@freeswitch.org&gt;<br/>
<b>To:</b>&nbsp;&quot;FreeSWITCH Users Help&quot; &lt;freeswitch-users@lists.freeswitch.org&gt;<br/>
<b>Subject:</b>&nbsp;Re: [Freeswitch-users] piped failover doesn&#39;t work in dialplan, but works from console</div>

<div name="quoted-content">
<div>Did you happen to update your FreeSWITCH code to something more recent?</div>

<div class="gmail_extra">&nbsp;
<div class="gmail_quote">On Fri, Feb 20, 2015 at 1:21 PM, Mi Ke <span>&lt;<a href="mi.ke@null.net" target="_parent">mi.ke@null.net</a>&gt;</span> wrote:

<blockquote class="gmail_quote" style="margin: 0 0 0 0.8ex;border-left: 1.0px rgb(204,204,204) solid;padding-left: 1.0ex;">
<div>
<div style="font-family: Verdana;font-size: 12.0px;">
<div>
<div>Dear Michael,</div>

<div>&nbsp;</div>

<div>Thank you for your response. I liked your idea so I have removed all channel vars I was assigning before bridge, removed tls and left only USER_BUSY in the single reject list. Still no luck neither from console nor from dialplan:</div>

<div>&nbsp;</div>

<div>originate {fail_on_single_reject=USER_BUSY}sofia/external/<a href="1111@1.1.1.1" target="_parent">1111@1.1.1.1</a>&#124;sofia/external/<a href="2222@1.1.1.1" target="_parent">2222@1.1.1.1</a> 999</div>

<div>&nbsp;</div>

<div>tries both 1111 and 2222 in order, the same result is with simplified DP:</div>

<div>&nbsp;</div>

<div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;extension name=&quot;outbound&quot;&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;condition field=&quot;destination_number&quot; expression=&quot;&#92;d+&quot;&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_answer_timeout=120&quot;/&gt;</span><br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;verbose_sdp=true&quot;/&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_early_media=true&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;sip_jitter_buffer_during_bridge=true&quot;/&gt;</span><br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;fail_on_single_reject=USER_BUSY&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;info&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;bridge&quot; data=&quot;sofia/external/<a href="1111@1.1.1.1" target="_parent">1111@1.1.1.1</a>&#124;sofia/external/<a href="2222@1.1.1.1" target="_parent">2222@1.1.1.1</a>&quot;/&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;hangup&quot; data=&quot;&#36;{last_bridge_hangup_cause}&quot;/&gt;</span><br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;anti-action application=&quot;hangup&quot; data=&quot;SERVICE_UNAVAILABLE&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/condition&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/extension&gt;</div>

<div>&nbsp;</div>

<div>quote from info output just before bridge:</div>

<div>&nbsp;</div>

<div>
<div>variable_bridge_answer_timeout: [120]<br/>
variable_verbose_sdp: [true]<br/>
variable_bridge_early_media: [true]<br/>
variable_hangup_after_bridge: [true]<br/>
variable_sip_jitter_buffer_during_bridge: [true]<br/>
variable_fail_on_single_reject: [USER_BUSY]<br/>
variable_current_application: [info]</div>

<div>&nbsp;</div>

<div>I also tried different escapings in {} as per Brian&#39;s advise, but all of them produced the same (correct) output in info and did not affect the end result. Any thoughts on where else I could dig?</div>

<div>&nbsp;</div>

<div>Thanks / Mike</div>
</div>
</div>

<div>&nbsp;
<div style="margin: 10.0px 5.0px 5.0px 10.0px;padding: 10.0px 0 10.0px 10.0px;border-left: 2.0px solid rgb(195,217,229);">
<div style="margin: 0 0 10.0px 0;"><b>Sent:</b>&nbsp;Friday, February 20, 2015 at 6:47 PM<br/>
<b>From:</b>&nbsp;&quot;Michael Collins&quot; &lt;<a href="msc@freeswitch.org" target="_parent">msc@freeswitch.org</a>&gt;<br/>
<span><b>To:</b>&nbsp;&quot;FreeSWITCH Users Help&quot; &lt;<a href="freeswitch-users@lists.freeswitch.org" target="_parent">freeswitch-users@lists.freeswitch.org</a>&gt;<br/>
<b>Subject:</b>&nbsp;Re: [Freeswitch-users] piped failover doesn&#39;t work in dialplan, but works from console</span></div>

<div>
<div>&nbsp;
<div class="gmail_extra">&nbsp;
<div>
<div class="h5">
<div class="gmail_quote">On Thu, Feb 19, 2015 at 4:58 PM, Mi Ke <span>&lt;<a href="http://mi.ke@null.net" target="_blank">mi.ke@null.net</a>&gt;</span> wrote:

<blockquote class="gmail_quote" style="margin: 0.0px 0.0px 0.0px 0.8ex;border-left: 1.0px solid rgb(204,204,204);padding-left: 1.0ex;">
<div>
<div style="font-family: Verdana;font-size: 12.0px;">
<div>
<div>Dear Brian,</div>

<div>&nbsp;</div>

<div>I have tuned escaping as per your advise and variable parsing looks OK now:</div>

<div>&nbsp;</div>

<div>2015-02-20 00:20:27.057113 [DEBUG] switch_ivr_originate.c:2100 Parsing global variables<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_event.c:1688 Parsing variable [fail_on_single_reject]=[USER_BUSY,NO_ANSWER,NO_USER_RESPONSE,RECOVERY_ON_TIMER_EXPIRE,ORIGINATOR_CANCEL] &lt;---properly escaped now<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_ivr_originate.c:2550 Parsing session specific variables<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_event.c:1688 Parsing variable [rtp_secure_media]=[true]<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_event.c:1688 Parsing variable [sdp_secure_savp_only]=[true]<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_event.c:1688 Parsing variable [origination_caller_id_number]=[1111]<br/>
2015-02-20 00:20:27.057113 [DEBUG] switch_event.c:1688 Parsing variable [origination_caller_id_name]=[aaaa]</div>

<div>&nbsp;</div>

<div>However a failover&#39;s behaviour in console and in dialplan is still different:</div>

<div>&nbsp;</div>

<div>2015-02-20 00:20:27.057113 [NOTICE] switch_channel.c:1055 New Channel sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a> [45088610-b896-11e4-99d1-858de6bd5367]<br/>
2015-02-20 00:20:27.057113 [DEBUG] mod_sofia.c:4701 (sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a>) State Change CS_NEW -&gt; CS_INIT</div>

<div>
<div>&nbsp;</div>

<div>call originates and hit 1.1.1.1</div>

<div>&nbsp;</div>

<div>
<div>2015-02-20 00:20:27.117077 [DEBUG] sofia.c:5845 Remote Reason: 17<br/>
2015-02-20 00:20:27.117077 [DEBUG] sofia.c:6617 Channel sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a> entering state [terminated][486]<br/>
2015-02-20 00:20:27.117077 [NOTICE] sofia.c:7533 Hangup sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a> [CS_CONSUME_MEDIA] [USER_BUSY]<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_channel.c:3222 Send signal sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a> [KILL]</div>

<div>&nbsp;</div>

<div>
<div>2015-02-20 00:20:27.117077 [DEBUG] switch_core_state_machine.c:823 (sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a>) State REPORTING<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_ivr_originate.c:3720 Originate Resulted in Error Cause: 17 [USER_BUSY]</div>

<div>&nbsp;</div>

<div>it should stop here since USER_BUSY is in fail_on_single_reject list, but hunting continues:</div>

<div><br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_ivr_originate.c:2550 Parsing session specific variables<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_event.c:1688 Parsing variable [rtp_secure_media]=[true]<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_event.c:1688 Parsing variable [sdp_secure_savp_only]=[true]<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_event.c:1688 Parsing variable [origination_caller_id_number]=[2222]<br/>
2015-02-20 00:20:27.117077 [DEBUG] switch_event.c:1688 Parsing variable [origination_caller_id_name]=[bbbb]</div>

<div>&nbsp;
<div>and the same continues for gw 2.2.2.2</div>

<div>&nbsp;</div>

<div>Meanwhile from console everything is OK:</div>

<div>&nbsp;</div>

<div>
<div>freeswitch@internal&gt; originate {fail_on_single_reject=CALL_REJECTED&#92;,USER_BUSY&#92;,NO_ANSWER}error/NO_ANSWER&#124;error/USER_BUSY&#124;error/CALL_REJECTED 999<br/>
-ERR NO_ANSWER</div>

<div>2015-02-20 00:35:15.057125 [DEBUG] switch_ivr_originate.c:2100 Parsing global variables<br/>
2015-02-20 00:35:15.057125 [DEBUG] switch_event.c:1688 Parsing variable [fail_on_single_reject]=[CALL_REJECTED,USER_BUSY,NO_ANSWER]<br/>
2015-02-20 00:35:15.057125 [NOTICE] switch_ivr_originate.c:2732 Cannot create outgoing channel of type [error] cause: [NO_ANSWER]</div>

<div>&nbsp;</div>
</div>

<div>My dialplan is:</div>

<div>&nbsp;</div>

<div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;extension name=&quot;outbound&quot;&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;condition field=&quot;destination_number&quot; expression=&quot;^&#92;d{4}&#36;&quot;&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_answer_timeout=120&quot;/&gt;</span><br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_early_media=true&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;</span><br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;sip_jitter_buffer_during_bridge=true&quot;/&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;odbc_query&quot; inline=&quot;true&quot; data=&quot;route_out&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;bridge&quot; data=&quot;&#36;{bridge_to}&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;hangup&quot; data=&quot;&#36;{last_bridge_hangup_cause}&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;anti-action application=&quot;hangup&quot; data=&quot;INVALID_NUMBER_FORMAT&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/condition&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/extension&gt;</span></div>

<div>&nbsp;</div>

<div>bridge data var as returned from the db backend is:</div>

<div>&nbsp;</div>

<div>
<div>{fail_on_single_reject=USER_BUSY&#92;,NO_ANSWER&#92;,NO_USER_RESPONSE&#92;,RECOVERY_ON_TIMER_EXPIRE&#92;,ORIGINATOR_CANCEL}[rtp_secure_media=true,sdp_secure_savp_only=true,origination_caller_id_number=1111,origination_caller_id_name=aaaa,called_id=5555]sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a>;transport=tls&#124;[rtp_secure_media=true,sdp_secure_savp_only=true,origination_caller_id_number=2222,origination_caller_id_name=bbbb,called_id=5555]sofia/external/<a href="http://5555@2.2.2.2" target="_blank">5555@2.2.2.2</a>;transport=tls</div>

<div>&nbsp;</div>

<div>a testing sites at 1.1.1.1 and 2.2.2.2 are doing nothing but hangup incoming calls with code 17</div>

<div>&nbsp;</div>

<div>Any ideas?</div>

<div>&nbsp;</div>

<div>Thanks / Mike</div>
</div>

<div>&nbsp;</div>
</div>
</div>
</div>

<div>&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>

<div>One thing I think you should try is to use the set application instead of using the curly brackets in the bridge line. I strongly recommend that you get it working manually with hard-coded values and then add the database lookup after that. I&#39;d create a separate extension and test it. Something like this:<br/>
<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;extension name=&quot;outbound&quot;&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;condition field=&quot;destination_number&quot; expression=&quot;^&#92;d{4}&#36;&quot;&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_answer_timeout=120&quot;/&gt;</span><br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;bridge_early_media=true&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;hangup_after_bridge=true&quot;/&gt;</span><br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;sip_jitter_buffer_
<div>during_bridge=true&quot;/&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;set&quot; data=&quot;</span><span>fail_on_single_reject=USER_</span>

<div>BUSY,NO_ANSWER,NO_USER_RESPONSE,RECOVERY_ON_TIMER_EXPIRE,ORIGINATOR_CANCEL&quot;/&gt;</div>
<span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;bridge&quot; data=&quot;</span><span>[</span>rtp_secure_media=true,sdp_secure_savp_only=true,origination_caller_id_number=1111,origination_caller_id_name=aaaa,called_id=5555]sofia/external/<a href="http://5555@1.1.1.1" target="_blank">5555@1.1.1.1</a>;transport=tls&#124;[rtp_secure_media=true,sdp_secure_savp_only=true,origination_caller_id_number=2222,origination_caller_id_name=bbbb,called_id=5555]sofia/external/<a href="http://5555@2.2.2.2" target="_blank">5555@2.2.2.2</a>;transport=tls&quot;/&gt;<br/>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;action application=&quot;hangup&quot; data=&quot;&#36;{last_bridge_hangup_cause}&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;anti-action application=&quot;hangup&quot; data=&quot;INVALID_NUMBER_FORMAT&quot;/&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/condition&gt;<br/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/extension&gt;</span></div>
</div>

<div>I have a hunch that once you get it working with predictable, hard-coded values that the rest of it will fall into place.<br/>
&nbsp;</div>

<div>-MC</div>

<div>&nbsp;</div>
</div>
</div>
</div>
</div>
</div>
<span>_________________________________________________________________________ Professional FreeSWITCH Consulting Services: <a href="consulting@freeswitch.org" target="_parent">consulting@freeswitch.org</a> <a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a> Official FreeSWITCH Sites <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a> <a href="http://confluence.freeswitch.org" target="_blank">http://confluence.freeswitch.org</a> <a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a> FreeSWITCH-users mailing list <a href="FreeSWITCH-users@lists.freeswitch.org" target="_parent">FreeSWITCH-users@lists.freeswitch.org</a> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a> <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a></span></div>
</div>
</div>
</div>
</div>
</div>
<br/>
_________________________________________________________________________<br/>
Professional FreeSWITCH Consulting Services:<br/>
<a href="consulting@freeswitch.org" target="_parent">consulting@freeswitch.org</a><br/>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br/>
<br/>
Official FreeSWITCH Sites<br/>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br/>
<a href="http://confluence.freeswitch.org" target="_blank">http://confluence.freeswitch.org</a><br/>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br/>
<br/>
FreeSWITCH-users mailing list<br/>
<a href="FreeSWITCH-users@lists.freeswitch.org" target="_parent">FreeSWITCH-users@lists.freeswitch.org</a><br/>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br/>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br/>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a></blockquote>
</div>
&nbsp;

<div>&nbsp;</div>
--

<div class="gmail_signature">
<div>
<p><font face="courier new, monospace"><b><i><font size="4">Brian West</font></i></b><br/>
<span style="font-size: x-small;"><a href="brian@freeswitch.org" target="_parent">brian@freeswitch.org</a></span></font></p>

<p><font face="courier new, monospace" size="1"><img src="http://billing.freeswitch.org/templates/default/img/whmcslogo.png"/></font></p>

<p><font face="courier new, monospace"><b><i>Twitter: @FreeSWITCH , @briankwest</i></b><br/>
<a href="http://www.freeswitchbook.com" target="_blank">http://www.freeswitchbook.com</a><br/>
<a href="http://www.freeswitchcookbook.com" target="_blank">http://www.freeswitchcookbook.com</a></font></p>

<p><font face="courier new, monospace"><b>T:</b>+19184209001 &#124; <b>F:</b>+19184209002 &#124; <b>M:</b>+1918424WEST (9378)<br/>
<b>iNUM:</b>+883 5100 1420 9001 &#124;&nbsp;<b>ISN:</b>410*543 &#124;&nbsp;<b>Skype:</b>briankwest</font></p>
</div>
</div>
</div>
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a> Official FreeSWITCH Sites <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a> <a href="http://confluence.freeswitch.org" target="_blank">http://confluence.freeswitch.org</a> <a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a> FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a> <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a></div>
</div>
</div>
</div></div></body></html>