Atef Alqashqish wrote: > I am using Asterisk 1.4.23.1 between our two offices where an asterisk > box is installed in each office, we have a limited internet link between > the office and would like to limit the concurrent number of calls > between offices to 4. We are using IAX channel when a call is routed > from one asterisk box to another. > > Please advise how to do this
You want to use the GROUP() and GROUP_COUNT() functions in your dialplan. If you want to allow calls between each office, but only have 4 total calls (i.e. 3 in one direction, 1 in the other, 2 and 2, 1 and 3, or 0 and 4, etc...) then you may need to implement something like DUNDi which does a query, where the mapping includes a call to the GROUP_COUNT() function, and then you add up the number of calls the remote box is sending you. Actually, on second thought, that probably isn't necessary at all. Just run GROUP and GROUP_COUNT() on the incoming calls as well, and that should allow you to keep track of the number of incoming and outgoing calls in that same group, then limit the calls to 4 that way. Many solutions to the same issue, as always :) Leif Madsen. http://www.leifmadsen.com http://www.oreilly.com/catalog/asterisk _______________________________________________ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-doc mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-doc
