You won&#39;t be able to do it that way.  lcr is already using the [] and you can&#39;t get two for each leg.  So, either use the same timeout for all legs using {leg_timeout=5} or you can push me to get the new mod_lcr in which lets you put arbitrary key/value pairs in their populated from your custom_sql.  Unfortunately I&#39;m travelling next week so I don&#39;t see doing something sooner than that...<br>
<br><div class="gmail_quote">On Thu, Apr 29, 2010 at 10:50 AM, Peder <span dir="ltr">&lt;<a href="mailto:peder@networkoblivion.com">peder@networkoblivion.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">









<div lang="EN-US" link="blue" vlink="purple">

<div>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">Didn’t like that at all.  Here is what I have in
dialplan:</span></p><div class="im">

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">&lt;action application=&quot;bridge&quot;
data=&quot;[leg_timeout=4]${lcr_route_1}|[leg_timeout=6]${lcr_route_2}&quot;/&gt;</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

</div><p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">Here is debug:</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">EXECUTE sofia/internal/<a href="mailto:1111@192.168.1.108" target="_blank">1111@192.168.1.108</a>
bridge([leg_timeout=4][lcr_carrier=tex,lcr_rate=0.01900]sofia/gateway/Tex/5551212|[leg_timeout=6][lcr_carrier=tel,lcr_rate=0.03000]sofia/gateway/Tel/5551212)</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">2010-04-29 15:40:12.370181 [ERR] switch_core_session.c:360 Could
not locate channel type [lcr_carrier=tex|lcr_rate=0.01900]sofia</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">2010-04-29 15:40:12.370181 [ERR] switch_ivr_originate.c:2480
Cannot create outgoing channel of type [[lcr_carrier=tex|lcr_rate=0.01900]sofia]
cause: [CHAN_NOT_IMPLEMENTED]</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">2010-04-29 15:40:12.370181 [DEBUG] switch_ivr_originate.c:3299
Originate Resulted in Error Cause: 66 [CHAN_NOT_IMPLEMENTED]</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">2010-04-29 15:40:12.370181 [ERR] switch_core_session.c:360 Could
not locate channel type [lcr_carrier=tel|lcr_rate=0.03000]sofia</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">2010-04-29 15:40:12.370181 [ERR] switch_ivr_originate.c:2480
Cannot create outgoing channel of type [[lcr_carrier=tel|lcr_rate=0.03000]sofia]
cause: [CHAN_NOT_IMPLEMENTED]</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D">Since ${lcr_route_1} already contains variables in [], it
appears that the extra set in the beginning may be causing an issue.  Note
that it is chopping off the dialstring after sofia (should be sofia/gateway/Tex/5551212
and just shows as sofia) and the “leg_timeout” appears to disappear
too.  If I remove the leg timeouts, I do see it bridge “sofia/external/5551212”. 
Any other ideas?</span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;color:#1F497D"> </span></p>

<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">

<p class="MsoNormal"><b><span style="font-size:10.0pt">From:</span></b><span style="font-size:10.0pt">
<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a>
[mailto:<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org" target="_blank">freeswitch-users-bounces@lists.freeswitch.org</a>] <b>On Behalf Of </b>Michael
Collins<br>
<b>Sent:</b> Wednesday, April 28, 2010 7:00 PM<br>
<b>To:</b> <a href="mailto:freeswitch-users@lists.freeswitch.org" target="_blank">freeswitch-users@lists.freeswitch.org</a><br>
<b>Subject:</b> Re: [Freeswitch-users] Dial Timeout Issue</span></p>

</div><div><div></div><div class="h5">

<p class="MsoNormal"> </p>

<p class="MsoNormal" style="margin-bottom:12.0pt">Is it failing because gateway1
is not responding at all? If so then I&#39;d say you&#39;d need to use leg_timeout or
leg_media_timeout on each leg as needed:<br>
<br>
&lt;action application=&quot;bridge&quot;
data=&quot;[leg_timeout=4]${lcr_route_1}|[leg_timeout=6]${lcr_route_2}&quot;/&gt;<br>
<br>
Check these variables:<br>
<a href="http://wiki.freeswitch.org/wiki/Channel_Variables#leg_timeout" target="_blank">http://wiki.freeswitch.org/wiki/Channel_Variables#leg_timeout</a><br>
<br>
Test it out and let us know.<br>
-MC</p>

<div>

<p class="MsoNormal">On Wed, Apr 28, 2010 at 2:17 PM, Peder &lt;<a href="mailto:peder@networkoblivion.com" target="_blank">peder@networkoblivion.com</a>&gt;
wrote:</p>

<p class="MsoNormal">I&#39;m having an issue where originate_timeout doesn&#39;t seem to
be working as I<br>
think it would.  I am using lcr to get the gateways.  I can bridge to
either<br>
gateway1 or 2 just fine.  Then I set it up with bridge using both gateways<br>
for failover and it worked fine.  I decided to change gateway1 to a fake
IP<br>
to test failover and it works, but it takes 30 seconds to timeout.  I then<br>
found originate_timeout and set it to 4 seconds, but it doesn&#39;t timeout.
 It<br>
still takes 30 seconds.<br>
<br>
<br>
Here is the snippet from my dialplan:<br>
<br>
&lt;action application=&quot;set&quot;
data=&quot;originate_timeout=4&quot;/&gt;<br>
&lt;action application=&quot;bridge&quot;
data=&quot;${lcr_route_1}|${lcr_route_2}&quot;/&gt;<br>
<br>
<br>
Here is the debug that shows it is being set:<br>
<br>
EXECUTE sofia/internal/<a href="mailto:1111@192.168.1.108" target="_blank">1111@192.168.1.108</a>
set(originate_timeout=4)<br>
2010-04-28 16:06:28.265187 [DEBUG] mod_dptools.c:818<br>
sofia/internal/<a href="mailto:1111@192.168.1.108" target="_blank">1111@192.168.1.108</a> SET
[originate_timeout]=[4]<br>
EXECUTE sofia/internal/<a href="mailto:1111@192.168.1.108" target="_blank">1111@192.168.1.108</a><br>
bridge([lcr_carrier=tex,lcr_rate=0.01900]sofia/gateway/Tex/5551212|[lcr_carr<br>
ier=tel,lcr_rate=0.03000]sofia/gateway/Tel/5551212)<br>
<br>
Then I get this:<br>
2010-04-28 16:07:00.273156 [NOTICE] sofia.c:4547 Hangup<br>
sofia/external/5551212 [CS_CONSUME_MEDIA] [RECOVERY_ON_TIMER_EXPIRE]<br>
<br>
<br>
And it successfully goes out gateway2, but it is 30 seconds later, not 4 as<br>
I would guess.  Am I using the timeout wrong?  Or is there some other<br>
setting I need instead?<br>
<br>
<br>
_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">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></p>

</div>

<p class="MsoNormal"> </p>

</div></div></div>

</div>


<br>_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">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><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>-Rupa<br>