[Asterisk-Users] dialparties.agi is returning no extensions to dial

Robert G. Ristroph rristroph at airlinksystems.com
Fri Sep 2 07:18:49 MST 2005


Hi,

I figured it out.

The problem was that I was using examples of how to use the rg-group macro from
an older asterisk, and it looks like they changed that macro.  It used to take
arguments set in variables, now it takes them normally.  If I define my
ringgroups like this it works:

exten => 2,1,Macro(rg-group,30,Operator,108-101-102) ; 30 sec wait, CID prefix
"Operator:", rings x108,x101,x102
exten => 2,2,Macro(vm,108,1)            ; goes to 108's voice mail if no-one
picks up

Maybe this post will help someone else.

--Rob

Quoting "Robert G. Ristroph" <rristroph at airlinksystems.com>:

> 
> Hi,
> 
>     I set up a ring group.  I would like for people who select a certain
> voice
> menu option to ring a list of extensions (I have just one extension in there
> at
> the moment) and if it doesn't answer to go to an extension's voice mail.  I
> am
> using a version of asterisk from CVS, last updated a couple of weeks ago.
> 
> This line in extensions_addtional.conf sends the call to ringgroup 3 if they
> press "1" :
> 
> exten => 1,1,Goto(ext-group,3,1)        ; goto ringgroup 3, the sales group
> 
> In [ext-group] I have these lines in [ext-group] to define the sales
> ringgroup:
> 
> exten => 3,1,Setvar(GROUP=103)          ; the "Sales" group is group 3 --
> only
> Dick is in for now
> exten => 3,2,Setvar(RINGTIMER=30)       ; rings for 30 seconds max
> exten => 3,3,Setvar(PRE=Sales)          ; called id has "Sales:" pre-pended
> exten => 3,4,Macro(rg-group)            ; rings the group
> exten => 3,5,Macro(vm,103,1)            ; goes to Dick's voice mail if
> no-one
> picks up
> 
> I believe that this should cause extension 103 to ring, and then if it isn't
> picked up it will go to 103's voicemail  ( eventually I will add other
> extensions to the group, but leave the fall-through to go to 103's vm).
> 
> What happens when I call in from the outside is that the call goes directly
> to
> the voicemail of 103.  Here are some logs from the *CLI> prompt and from the
> /var/log/asterisk/full file:
> 
> from the *CLI>
> Don't know what to do if second ROSE component is of type 0x6
>     -- Accepting call from '512xxxxxxx' to '5126xxxxxxx' on channel 0/1, span
> 1
>     -- Executing Goto("Zap/1-1", "aa_default|s|1") in new stack
>     -- Goto (aa_default,s,1)
>     -- Executing GotoIf("Zap/1-1", "0?4") in new stack
>     -- Executing Answer("Zap/1-1", "") in new stack
>     -- Executing Wait("Zap/1-1", "1") in new stack
>     -- Executing SetVar("Zap/1-1", "DIR-CONTEXT=ext-local") in new stack
>     -- Executing DigitTimeout("Zap/1-1", "3") in new stack
>     -- Set Digit Timeout to 3
>     -- Executing ResponseTimeout("Zap/1-1", "7") in new stack
>     -- Set Response Timeout to 7
>     -- Executing BackGround("Zap/1-1", "custom/aa_default") in new stack
>     -- Playing 'custom/aa_default' (language 'en')
>   == CDR updated on Zap/1-1
>     -- Executing Goto("Zap/1-1", "ext-group|3|1") in new stack
>     -- Goto (ext-group,3,1)
>     -- Executing SetVar("Zap/1-1", "GROUP=103") in new stack
>     -- Executing SetVar("Zap/1-1", "RINGTIMER=30") in new stack
>     -- Executing SetVar("Zap/1-1", "PRE=Sales") in new stack
>     -- Executing Macro("Zap/1-1", "rg-group") in new stack
>     -- Executing GotoIf("Zap/1-1", "0?3:2") in new stack
>     -- Goto (macro-rg-group,s,2)
>     -- Executing SetCIDName("Zap/1-1", "AIRLINK SYSTEMS") in new stack
>     -- Executing SetVar("Zap/1-1", "RGPREFIX=") in new stack
>     -- Executing SetCIDName("Zap/1-1", "AIRLINK SYSTEMS") in new stack
>     -- Executing SetVar("Zap/1-1", "RecordMethod=Group") in new stack
>     -- Executing Macro("Zap/1-1", "record-enable|3|Group") in new stack
>     -- Executing GotoIf("Zap/1-1", "0 > 0?2:4") in new stack
>     -- Goto (macro-record-enable,s,4)
>     -- Executing GotoIf("Zap/1-1", "0?5:8") in new stack
>     -- Goto (macro-record-enable,s,8)
>     -- Executing GotoIf("Zap/1-1", "1?9:12") in new stack
>     -- Goto (macro-record-enable,s,9)
>     -- Executing AGI("Zap/1-1", "recordingcheck") in new stack
>     -- Launched AGI Script /var/lib/asterisk/agi-bin/recordingcheck
>   recordingcheck: Extension List not set -- nothing to do
>     -- AGI Script recordingcheck completed, returning 0
>     -- Executing SetVar("Zap/1-1",
> "CALLFILENAME=g3-20050901-115459-1125593688.105") in new stack
>     -- Executing Goto("Zap/1-1", "s|14") in new stack
>     -- Goto (macro-record-enable,s,14)
>     -- Executing GotoIf("Zap/1-1", "0?15:99") in new stack
>     -- Goto (macro-record-enable,s,99)
>     -- Executing NoOp("Zap/1-1", "NO RECORDING NEEDED") in new stack
>     -- Executing Macro("Zap/1-1", "dial||tr|") in new stack
>     -- Executing GotoIf("Zap/1-1", "1?4:2") in new stack
>     -- Goto (macro-dial,s,4)
>     -- Executing AGI("Zap/1-1", "dialparties.agi") in new stack
>     -- Launched AGI Script /var/lib/asterisk/agi-bin/dialparties.agi
>     --  dialparties.agi: priority = 4
>     --  dialparties.agi: callingani2 = 0
>     --  dialparties.agi: accountcode = 
>     --  dialparties.agi: channel = Zap/1-1
>     --  dialparties.agi: callerid = 5122311245
>     --  dialparties.agi: context = macro-dial
>     --  dialparties.agi: callington = 33
>     --  dialparties.agi: dnid = 5126873305
>     --  dialparties.agi: request = dialparties.agi
>     --  dialparties.agi: calleridname = AIRLINK SYSTEMS
>     --  dialparties.agi: extension = s
>     --  dialparties.agi: language = en
>     --  dialparties.agi: uniqueid = 1125593688.105
>     --  dialparties.agi: callingpres = 3
>     --  dialparties.agi: type = Zap
>     --  dialparties.agi: rdnis = unknown
>     --  dialparties.agi: callingtns = 0
>     --  dialparties.agi: enhanced = 0.0
>   dialparties.agi: Caller ID name and number are '5122311245'
>   == Parsing '/etc/asterisk/manager.conf': Found
>   == Parsing '/etc/asterisk/manager_custom.conf': Not found (No such file or
> directory)
>   == Manager 'admin' logged on from 127.0.0.1
>   == Manager 'admin' logged off from 127.0.0.1
>     -- AGI Script Executing Application: (NoOp) Options: ()
>     -- AGI Script dialparties.agi completed, returning 0
>     -- Executing NoOp("Zap/1-1", "Returned from dialparties with no
> extensions
> to call") in new stack
> 
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> above this line is where the dialparties *SHOULD* be returning 103, I think
> 
>     -- Executing SetVar("Zap/1-1", "DIALSTATUS=BUSY") in new stack
>     -- Executing Macro("Zap/1-1", "vm|103|1") in new stack
>     -- Executing Goto("Zap/1-1", "s-1|1") in new stack
>     -- Goto (macro-vm,s-1,1)
>     -- Executing VoiceMail("Zap/1-1", "u103") in new stack
>     -- Playing 'vm-theperson' (language 'en')
>     -- Playing 'digits/1' (language 'en')
>     -- Playing 'digits/0' (language 'en')
>     -- Playing 'digits/3' (language 'en')
>     -- Playing 'vm-isunavail' (language 'en')
>     -- Playing 'vm-intro' (language 'en')
>     -- Channel 0/1, span 1 got hangup request
>   == Spawn extension (macro-vm, s-1, 1) exited non-zero on 'Zap/1-1' in
> macro
> 'vm'
>   == Spawn extension (ext-group, 3, 5) exited non-zero on 'Zap/1-1'
>     -- Hungup 'Zap/1-1'
> linux40*CLI>
> 
> Here is the relative logs from /var/log/asterisk/full:
> 
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Accepting call from
> '5122311245'
> to '5126873305' on channel 0/1, span 1
> Sep  1 11:54:48 DEBUG[29945] chan_zap.c: No echo cancellation requested
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Executing Goto("Zap/1-1",
> "aa_default|s|1") in new stack
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Goto (aa_default,s,1)
> Sep  1 11:54:48 WARNING[29945] ast_expr.y: ast_yyerror(): syntax error:
> syntax
> error; Input:
>  = ANSWER
> 
>    ^
> Sep  1 11:54:48 DEBUG[29945] pbx.c: Expression is '0'
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "0?4") in new stack
> Sep  1 11:54:48 DEBUG[29945] pbx.c: Not taking any branch
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Executing Answer("Zap/1-1",
> "")
> in new stack
> Sep  1 11:54:48 VERBOSE[29945] logger.c:     -- Executing Wait("Zap/1-1",
> "1")
> in new stack
> Sep  1 11:54:49 DEBUG[29945] chan_zap.c: No echo cancellation requested
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "DIR-CONTEXT=ext-local") in new stack
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Executing
> DigitTimeout("Zap/1-1", "3") in new stack
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Set Digit Timeout to 3
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Executing
> ResponseTimeout("Zap/1-1", "7") in new stack
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Set Response Timeout to 7
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Executing
> BackGround("Zap/1-1",
> "custom/aa_default") in new stack
> Sep  1 11:54:49 DEBUG[29945] channel.c: Scheduling timer at 160 sample
> intervals
> Sep  1 11:54:49 VERBOSE[29945] logger.c:     -- Playing 'custom/aa_default'
> (language 'en')
> Sep  1 11:54:55 DEBUG[29945] chan_zap.c: DTMF digit: 1 on Zap/1-1
> Sep  1 11:54:55 DEBUG[29945] channel.c: Scheduling timer at 0 sample
> intervals
> Sep  1 11:54:55 DEBUG[29945] pbx.c: Oooh, got something to jump out with
> ('1')!
> Sep  1 11:54:58 VERBOSE[29945] logger.c:   == CDR updated on Zap/1-1
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing Goto("Zap/1-1",
> "ext-group|3|1") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Goto (ext-group,3,1)
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "GROUP=103") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "RINGTIMER=30") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "PRE=Sales") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing Macro("Zap/1-1",
> "rg-group") in new stack
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Function result is '0'
> Sep  1 11:54:58 WARNING[29945] ast_expr.y: ast_yyerror(): syntax error:
> syntax
> error; Input:
>  != 
> 
>     ^
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Expression is '0'
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "0?3:2") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Goto (macro-rg-group,s,2)
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Function result is '0'
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing
> SetCIDName("Zap/1-1",
> "AIRLINK SYSTEMS") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "RGPREFIX=") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing
> SetCIDName("Zap/1-1",
> "AIRLINK SYSTEMS") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "RecordMethod=Group") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing Macro("Zap/1-1",
> "record-enable|3|Group") in new stack
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Function result is '0'
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "0 >
> 0?2:4") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Goto
> (macro-record-enable,s,4)
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Expression is '0'
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "0?5:8") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Goto
> (macro-record-enable,s,8)
> Sep  1 11:54:58 DEBUG[29945] pbx.c: Expression is '1'
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "1?9:12") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Goto
> (macro-record-enable,s,9)
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Executing AGI("Zap/1-1",
> "recordingcheck") in new stack
> Sep  1 11:54:58 VERBOSE[29945] logger.c:     -- Launched AGI Script
> /var/lib/asterisk/agi-bin/recordingcheck
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   recordingcheck: Extension List
> not
> set -- nothing to do
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- AGI Script recordingcheck
> completed, returning 0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "CALLFILENAME=g3-20050901-115459-1125593688.105") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing Goto("Zap/1-1",
> "s|14") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Goto
> (macro-record-enable,s,14)
> Sep  1 11:54:59 DEBUG[29945] pbx.c: Expression is '0'
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "0?15:99") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Goto
> (macro-record-enable,s,99)
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing NoOp("Zap/1-1",
> "NO
> RECORDING NEEDED") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing Macro("Zap/1-1",
> "dial||tr|") in new stack
> Sep  1 11:54:59 DEBUG[29945] pbx.c: Expression is '1'
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing GotoIf("Zap/1-1",
> "1?4:2") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Goto (macro-dial,s,4)
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing AGI("Zap/1-1",
> "dialparties.agi") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Launched AGI Script
> /var/lib/asterisk/agi-bin/dialparties.agi
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: priority =
> 4
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: callingani2
> =
> 0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: accountcode
> =
> 
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: channel =
> Zap/1-1
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: callerid =
> 5122311245
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: context =
> macro-dial
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: callington
> =
> 33
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: dnid =
> 5126873305
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: request =
> dialparties.agi
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi:
> calleridname =
> AIRLINK SYSTEMS
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: extension =
> s
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: language =
> en
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: uniqueid =
> 1125593688.105
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: callingpres
> =
> 3
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: type = Zap
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: rdnis =
> unknown
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: callingtns
> =
> 0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     --  dialparties.agi: enhanced =
> 0.0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   dialparties.agi: Caller ID name
> and
> number are '5122311245'
> Sep  1 11:54:59 DEBUG[29945] manager.c: Manager received command 'Login'
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   == Parsing
> '/etc/asterisk/manager.conf': Sep  1 11:54:59 VERBOSE[29945] logger.c:   ==
> Parsing '/etc/asterisk/manager.conf': Found
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   == Parsing
> '/etc/asterisk/manager_custom.conf': Sep  1 11:54:59 VERBOSE[29945] logger.c:
>  
> == Parsing '/etc/asterisk/manager_custom.conf': Not found (No such file or
> directory)
> Sep  1 11:54:59 DEBUG[29945] acl.c: 0.0.0.0/0.0.0.0/0.0.0.0 appended to acl
> for
> peer
> Sep  1 11:54:59 DEBUG[29945] acl.c: 127.0.0.1/255.255.255.0/255.255.255.0
> appended to acl for peer
> Sep  1 11:54:59 DEBUG[29945] acl.c: ##### Testing 127.0.0.1 with 0.0.0.0
> Sep  1 11:54:59 DEBUG[29945] acl.c: ##### Testing 127.0.0.1 with 127.0.0.0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   == Manager 'admin' logged on from
> 127.0.0.1
> Sep  1 11:54:59 DEBUG[29945] manager.c: Manager received command 'command'
> Sep  1 11:54:59 DEBUG[29945] manager.c: Manager received command ''
> Sep  1 11:54:59 DEBUG[29945] manager.c: Manager received command 'Logoff'
> Sep  1 11:54:59 VERBOSE[29945] logger.c:   == Manager 'admin' logged off
> from
> 127.0.0.1
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- AGI Script Executing
> Application: (NoOp) Options: ()
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- AGI Script dialparties.agi
> completed, returning 0
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing NoOp("Zap/1-1",
> "Returned from dialparties with no extensions to call") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing SetVar("Zap/1-1",
> "DIALSTATUS=BUSY") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing Macro("Zap/1-1",
> "vm|103|1") in new stack
> Sep  1 11:54:59 VERBOSE[29945] logger.c:     -- Executing Goto("Zap/1-1",
> "s-1|1") in new stack
> 
> Any suggestions as to how to make this work would be appreciated.  I suppose
> I
> could replace the call in macro-rg-group to dialparties with a simple call
> to
> Dial() with several extensions listed, but I presume there is a reason why
> dialparties is used.
> 
> Thanks in advance,
> 
> Rob
> 
> 
> 
> 
> -- 
> Robert G. Ristroph
> Airlink Systems
> rristroph at airlinksystems.com
> (512) 231-1240 x103
> 
> 
> 
> 
> 
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
> _______________________________________________
> --Bandwidth and Colocation sponsored by Easynews.com --
> 
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
> 


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



More information about the asterisk-users mailing list