When Asterisk starts an AGI script, it feeds the channel variables to the script on standard input. The variable names are prefixed with "agi_" and are separated from their values by a colon and a space.
И это нормально и AMI тут вообще ни при чем.
EShara писал(а):Вот добавил опцию g
ну а:
virus_net писал(а):попробовать добавить перед AGI выполнение DumpChan и посмотреть что он покажет
?
мой SIP URI sip:virus_net@asterisk.ru bitname.ru - Домены .bit (namecoin) .emc .coin .lib .bazar (emercoin) ENUMER - звони бесплатно и напрямую.
Мы не на ты.
Вопрос "Как выполнить DumpChan? Подробнее, или тупо перед выполнение AGI ввести команду core show application DumpChan?"
убил наповал. Это недочитанная книга про будущее.
Хорошо не ты а вы.
Так и скажите что сами не знаете. И не надо тыкать мне в эту книгу, нет там ничего такого.
ubuntu*CLI> core show application DumpChan AGI
-= Info about application 'AGI' =-
[Synopsis]
Executes an AGI compliant application.
[Description]
Executes an Asterisk Gateway Interface compliant program on a channel. AGI
allows Asterisk to launch external programs written in any language to control
a telephony channel, play audio, read DTMF digits, etc. by communicating with
the AGI protocol on *stdin* and *stdout*. As of '1.6.0', this channel will
not stop dialplan execution on hangup inside of this application. Dialplan
execution will continue normally, even upon hangup until the AGI application
signals a desire to stop (either by exiting or, in the case of a net script,
by closing the connection). A locally executed AGI script will receive SIGHUP
on hangup from the channel except when using DeadAGI. A fast AGI server will
correspondingly receive a HANGUP inline with the command dialog. Both of theses
signals may be disabled by setting the ${AGISIGHUP} channel variable to 'no'
before executing the AGI application. Alternatively, if you would like the
AGI application to exit immediately after a channel hangup is detected, set
the ${AGIEXITONHANGUP} variable to 'yes'.
Use the CLI command 'agi show commands' to list available agi commands.
This application sets the following channel variable upon completion:
${AGISTATUS}: The status of the attempt to the run the AGI script text string,
one of:
SUCCESS
FAILURE
NOTFOUND
HANGUP
[Syntax]
AGI(command[,arg1[,arg2[,...]]])
[Arguments]
Not available
[See Also]
EAGI(), DeadAGI()
-= Info about application 'DumpChan' =-
[Synopsis]
Dump Info About The Calling Channel.
[Description]
Displays information on channel and listing of all channel variables. If
<level> is specified, output is only displayed when the verbose level is
currently set to that number or greater.
[Syntax]
DumpChan([level])
[Arguments]
level
Minimum verbose level
[See Also]
NoOp(), Verbose()
-- Attempting call on SIP/proton/8XXXXXXXXXXX for s@callback:1 (Retry 1)
== Using SIP RTP CoS mark 5
-- Called proton/8XXXXXXXXXXX
-- SIP/proton-0000000b is ringing
-- SIP/proton-0000000b answered
-- Executing [s@callback:1] BackGround("SIP/proton-0000000b", "agent-pass") in new stack
-- <SIP/proton-0000000b> Playing 'agent-pass.alaw' (language 'ru')
> 0xb6c31a78 -- Probation passed - setting RTP source address to XXX.XXX.XXX.14:7234
-- Executing [88888888@callback:1] AGI("SIP/proton-0000000b", "/etc/asterisk/agiscript/tipodisa.php, XXXXXXXXXXX") in new stack
-- Launched AGI Script /etc/asterisk/agiscript/tipodisa.php
-- AGI Script Executing Application: (Playback) Options: (digits/40)
-- <SIP/proton-0000000b> Playing 'digits/40.alaw' (language 'ru')
-- AGI Script Executing Application: (Playback) Options: (seconds)
-- <SIP/proton-0000000b> Playing 'seconds.alaw' (language 'ru')
-- AGI Script Executing Application: (Goto) Options: (trunkcall,s,1)
-- Goto (trunkcall,s,1)
-- <SIP/proton-0000000b>AGI Script /etc/asterisk/agiscript/tipodisa.php completed, returning 0
-- Executing [s@trunkcall:1] BackGround("SIP/proton-0000000b", "dial-exten") in new stack
[Aug 27 16:00:23] WARNING[30923][C-00000009]: file.c:758 ast_openstream_full: File dial-exten does not exist in any format
[Aug 27 16:00:23] WARNING[30923][C-00000009]: file.c:1077 ast_streamfile: Unable to open dial-exten (format (alaw)): No such file or directory
[Aug 27 16:00:23] WARNING[30923][C-00000009]: pbx.c:11236 pbx_builtin_background: ast_streamfile failed on SIP/proton-0000000b for dial-exten
-- Executing [s@trunkcall:2] WaitExten("SIP/proton-0000000b", "15") in new stack
-- Executing [9ZZZZZZ@trunkcall:1] Dial("SIP/proton-0000000b", "SIP/proton/ZZZZZZ,,tTCS(40)") in new stack
-- Setting call duration limit to 40.000 seconds.
== Using SIP RTP CoS mark 5
-- Called SIP/proton/ZZZZZZ
-- SIP/proton-0000000c is ringing
-- SIP/proton-0000000c answered SIP/proton-0000000b
-- Channel SIP/proton-0000000b joined 'simple_bridge' basic-bridge <bdbd9a26-bf40-4019-be25-ccbf95b8dfb7>
-- Channel SIP/proton-0000000c joined 'simple_bridge' basic-bridge <bdbd9a26-bf40-4019-be25-ccbf95b8dfb7>
> 0xb6c4d2a8 -- Probation passed - setting RTP source address to XXX.XXX.XXX.14:7238
-- Channel SIP/proton-0000000c left 'simple_bridge' basic-bridge <bdbd9a26-bf40-4019-be25-ccbf95b8dfb7>
-- Channel SIP/proton-0000000b left 'simple_bridge' basic-bridge <bdbd9a26-bf40-4019-be25-ccbf95b8dfb7>
== Spawn extension (trunkcall, 9ZZZZZZ, 1) exited non-zero on 'SIP/proton-0000000b'
-- Executing [h@trunkcall:1] AGI("SIP/proton-0000000b", "/etc/asterisk/agiscript/timesum.php, 0, XXXXXXXXXXX") in new stack
-- Launched AGI Script /etc/asterisk/agiscript/timesum.php
-- <SIP/proton-0000000b>AGI Script /etc/asterisk/agiscript/timesum.php completed, returning 0
[Aug 27 16:00:33] NOTICE[30922]: pbx_spool.c:402 attempt_thread: Call completed to SIP/proton/8XXXXXXXXXXX