On Fri, Sep 28, 2007 at 09:57:52AM +0100, Russell Brown wrote: > > I've a big problem with SIP forwarding back into 'ringing groups' > creating what can only be described as call storms :-( > > I have a 'ringing groups' of SIP phones with an effective dialplan (much > simplified) like so: > > ; Purchase ledger > [ptsn_inbound] > exten => _846061,1,Dial(Local/[EMAIL PROTECTED])
I am not sure why you are doing it like this but it seems awkward. Relying on handset diverts seems fraught with danger as you can't be sure what's going to happen from a dialplan perspective. Why don't you set up a queue in queues.conf strategy ringall: [purchase] ; Dynamic group for users logging on in London Office strategy = ringall maxlen = 1 retry = 1 timeout = 20 musiconhold = default joinempty = strict leavewhenempty = yes timeoutrestart = yes member => SIP/110 member => SIP/111 member => SIP/112 member => SIP/113 member => SIP/114 Then route calls to that queue from the dialplan:- exten => _846061,1,Queue(purchase|rn|||40) ... [...variety of options you can do here if there is no answer all busy in the queue etc, see variable ${QUEUESTATUS}. Here's what I've got:- exten => s,n,GotoIf($["${QUEUESTATUS}" = "UNKNOWN"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "BUSY"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "FULL"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "JOINUNAVAIL"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "LEAVEUNAVAIL"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "LEAVEEMPTY"]?200) exten => s,n,GotoIf($["${QUEUESTATUS}" = "TIMEOUT"]?200) ] Then you could set up some features in the dial plan to allow your users to go in and out of the group as required. Something like:- exten => _*71,2,Macro(togglegroup,${CALLERID(num)}) ( *71 will toggle in and out of group, so you could program a button on your phones for example, to set them in and out of group. This set of macros keeps track for each user in and out group state and toggles it in and out. It keeps track of it with a db variable.) [macro-outofgroup] exten => s,1,NoOp("macro-outofgroup reached: ${ARG1}") exten => s,n,NoOp( -- DND pausing queue member: Local/${ARG1} --- ) exten => s,n,PauseQueueMember(|Local/[EMAIL PROTECTED]) exten => s,n,Set(DB(${ARG1}/outofgroup)=1) exten => s,n,Answer exten => s,n,Playback(extras/dnd-out-of-group) exten => s,n,Hangup [macro-ingroup] exten => s,1,NoOp("macro-ingroup reached: ${ARG1}") exten => s,n,NoOp( -- DND unpausing queue member: Local/${ARG1} --- ) exten => s,n,UnPauseQueueMember(|Local/[EMAIL PROTECTED]) exten => s,n,DBdel(${ARG1}/outofgroup) exten => s,n,Answer exten => s,n,Playback(extras/dnd-now-in-group) exten => s,n,Hangup [macro-togglegroup] exten => s,1,NoOp("macro-togglegroup reached: ${ARG1}") exten => s,n,GotoIf($["${DB(${ARG1}/outofgroup)}" = ""]?900) exten => s,n,Macro(ingroup,${ARG1}) exten => s,n,Hangup exten => s,900,Macro(outofgroup,${ARG1}); exten => s,n,Hangup (I've got those sounds if you want them, let me know, if you don't mind plummy british accent we re-recorded all our sounds files in, plus a few custom ones, or you could just play a tone so the user knows the group action has been carried out.) Let me know if this is any use to you. Regards, Rob -- Robert Lister - London Internet Exchange - http://www.linx.net/ sip:[EMAIL PROTECTED] - inoc-dba:5459*710 - tel: +44 (0)20 7645 3510 _______________________________________________ Sign up now for AstriCon 2007! September 25-28th. http://www.astricon.net/ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users