Hello<br><br>OK I have tried this in my dialplan:<br><br><span id="_user_klaus.mailinglists@pernau.at" style="color: rgb(121, 6, 25);"></span>exten => _0262XXXXXX,1,Set(GROUP()=Reunion)<br>exten => _0262XXXXXX,2,GotoIf(${GROUP_COUNT(Reunion)} > 24 ? 500)<br>
exten => _0262XXXXXX,n,NoOp(This channel is member of group: ${GROUP()})<br>exten => _0262XXXXXX,n,NoOp(Number of channels is ${GROUP_COUNT(Reunion)})<br>exten => _0262XXXXXX,n,Set(SPYGROUP=1003)<br>exten => _0262XXXXXX,n,Dial(IAX2/dedibox-etang-sale/${EXTEN})<br>
exten => _0262XXXXXX,n,Congestion()<br>exten => _0262XXXXXX,500,NoOp(Total channels congested, retuning NOCAV)<br>exten => _0262XXXXXX,501,Congestion()<br><br>However here's what i see on the CLI:<br><br> -- IAX2/dedibox-etang-sale-34 is making progress passing it to SIP/5060-006edf50<br>
-- IAX2/dedibox-etang-sale-6 is making progress passing it to SIP/5060-007654f0<br> -- Executing [0262211459@route:1] Set("SIP/5060-0070b9d0", "GROUP()=Reunion") in new stack<br> -- Executing [0262211459@route:2] GotoIf("SIP/5060-0070b9d0", "21 > 24 ? 500") in new stack<br>
-- Goto (route,0262211459,500)<br> -- Executing [0262211459@route:500] NoOp("SIP/5060-0070b9d0", "Total channels congested| retuning NOCAV") in new stack<br> -- Executing [0262211459@route:501] Congestion("SIP/5060-0070b9d0", "") in new stack<br>
<br>I am *totally puzzled* with this:<br><br>GotoIf("SIP/5060-0070b9d0", "21 > 24 ? 500") in new stack<br>
-- Goto (route,0262211459,500)<br><br>What???? GotoIf 21 > 24 returns true????<br><br>Any ideas?<br><br>Cheers<br>Jean-Michel.<br><br><div><span class="gmail_quote">2009/2/26, Klaus Darilion <<a href="mailto:klaus.mailinglists@pernau.at">klaus.mailinglists@pernau.at</a>>:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I have no clue about IAX, but if IAX does not support it you can program<br> it yourself using the GROUP and GROUPCOUNT functions.<br> <br> regards<br> klaus<br> <br><br> Jean-Michel Hiver wrote:<br> > Hello,<br> ><br>
> I use asterisk to to IAX2 trunking between London POP & Reunion Island<br> > pop. I would like to know if it's possible to do a kind of call-limit<br> > (i.e. restrict to XX) channels but on a per dialcode and / or<br>
> destination basis.<br> ><br> ><br> > For example:<br> ><br> > [trunk]<br> > ; reunion proper, i want to send no more than 24 channels<br> > exten => _0262XXXXXX,1,Dial(IAX2/mytrunk/${EXTEN})<br>
><br> > ; reunion mobile, i want to send no more than 12 channels<br> > exten => _0692XXXXXX,1,Dial(IAX2/mytrunk/${EXTEN})<br> > exten => _0693XXXXXX,1,Dial(IAX2/mytrunk/${EXTEN})<br> ><br> ><br> > How would you go about it? Currently my IAX2 peer definition looks like<br>
> this:<br> ><br> > # machine in london<br> > [mytrunk]<br> > type=friend<br> > host=$reunion_ip<br> > trunk=yes<br> > qualify=yes<br> > context=route<br> ><br> > # machine in reunion island<br>
> [mytrunk]<br> > type=friend<br> > host=$london_ip<br> > trunk=yes<br> > qualify=yes<br> > context=route<br> ><br> > I use version Asterisk 1.4.11, production environment currently doing<br> > 25,000 minutes / day (that means if i want to upgrade i need to do it on<br>
> separate servers just in case something goes wrong).<br> ><br> ><br> > Cheers,<br> > Jean-Michel.<br> ><br> ><br> <br>> ------------------------------------------------------------------------<br>
><br> > _______________________________________________<br> > -- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com">http://www.api-digital.com</a> --<br> ><br> > asterisk-users mailing list<br>
> To UNSUBSCRIBE or update options visit:<br> > <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br> <br> <br> _______________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com">http://www.api-digital.com</a> --<br> <br> asterisk-users mailing list<br> To UNSUBSCRIBE or update options visit:<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>
<br> </blockquote></div><br><br clear="all"><br>-- <br>Jean-Michel Hiver - Synapse co-founder & CTO<br>GSM +262 692 828 070