Hello,
Please help with this challenge. I have an E1 card configured to pick calls. However, whenever the call comes it, the status immediately changes from LIVE to Hangup.
Here is my extensions.conf
exten => _X.,1,Answer
exten => _X.,n,AGI(agi-VDAD_ALL_inbound.agi,CIDLOOKUP-----LB----HCPs-----07098141858--------------------101-----234)
exten => _X.,n,Hangup()
Here is my chan_dahdi.conf
[trunkgroups]
[channels]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; General Information ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
musiconhold=default
language=en
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;Callerid Information Group ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
usecallerid=yes
callerid=asreceived
usecallerid=yes
hidecallerid=no
callwaitingcallerid=yes
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;Software Echo Management ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
echocancel=yes
echocancelwhenbridged=no
echotraining=800
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Call Management ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
threewaycalling=yes
transfer=yes
cancallforward=yes
callreturn=yes
callgroup=1
pickupgroup=1
immediate=no
callwaiting=yes
canpark=yes
immediate=no
;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Transmission Line ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;
rxgain=1.0
txgain=1.0
;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Miscellaneous ;
;;;;;;;;;;;;;;;;;;;;;;;;;;
;amaflags=default
hanguponpolarityswitch=yes
answeronpolarityswitch=yes
callprogress=yes
;busydetect=yes
;busycount=4
pridialplan=unknown
nationalprefix=0
internationalprefix=009
;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Signalling ;
;;;;;;;;;;;;;;;;;;;;;;;;;;
group=1
context=default
signalling=pri_cpe
switchtype=euroisdn
channel => 1-15,17-31
#include dahdi-channels.conf
Here is my dahdi-channels.conf
; Autogenerated by /usr/sbin/dahdi_genconf on Tue Mar 27 11:38:58 2012
; If you edit this file and execute /usr/sbin/dahdi_genconf again,
; your manual changes will be LOST.
; Dahdi Channels Configurations (chan_dahdi.conf)
;
; This is not intended to be a complete chan_dahdi.conf. Rather, it is intended
; to be #include-d by /etc/chan_dahdi.conf that will include the global settings
;
; Span 1: AX1D/0/1 "AX1D (E1|T1) Card 0 Span 1" (MASTER) HDB3/CCS/CRC4 RED
group=0,11
context=default
switchtype=euroisdn
signalling=pri_cpe
channel => 1-15,17-31
context=default
group=63
Here is my asterisk cli
[Jan 1 03:17:54] -- Accepting call from '0xxxxxxxxxx' to 'xxxxxxxx' on channel 0/2, span 1
[Jan 1 03:17:54] -- Executing [4482150@default:1] Answer("DAHDI/2-1", "") in new stack
[Jan 1 03:17:54] -- Executing [4482150@default:2] AGI("DAHDI/2-1", "agi-VDAD_ALL_inbound.agi|CIDLOOKUP-----LB-----HCPs-----07098141858--------------------101-----234") in new stack
[Jan 1 03:17:54] -- Launched AGI Script /var/lib/asterisk/agi-bin/agi-VDAD_ALL_inbound.agi
[Jan 1 03:17:55] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:17:55] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:17:57] -- Started music on hold, class 'default', on DAHDI/2-1
[Jan 1 03:18:01] -- Stopped music on hold on DAHDI/2-1
[Jan 1 03:18:01] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:01] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:01] == Parsing '/etc/asterisk/manager.conf': [Jan 1 03:18:01] Found
[Jan 1 03:18:01] == Manager 'sendcron' logged on from 127.0.0.1
[Jan 1 03:18:01] == Manager 'sendcron' logged off from 127.0.0.1
[Jan 1 03:18:01] == Parsing '/etc/asterisk/manager.conf': [Jan 1 03:18:01] Found
[Jan 1 03:18:01] == Manager 'sendcron' logged on from 127.0.0.1
[Jan 1 03:18:02] -- Playing 'generic_hold' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:02] -- Started music on hold, class 'default', on DAHDI/2-1
[Jan 1 03:18:06] == Parsing '/etc/asterisk/manager.conf': [Jan 1 03:18:06] Found
[Jan 1 03:18:06] == Manager 'sendcron' logged on from 127.0.0.1
[Jan 1 03:18:06] == Manager 'sendcron' logged off from 127.0.0.1
[Jan 1 03:18:07] == Manager 'sendcron' logged off from 127.0.0.1
[Jan 1 03:18:07] == Parsing '/etc/asterisk/manager.conf': [Jan 1 03:18:07] Found
[Jan 1 03:18:07] == Manager 'sendcron' logged on from 127.0.0.1
[Jan 1 03:18:07] -- Executing [192*168*019*230*78600051@default:1] Answer("Local/192*168*019*230*78600051@default-8a4c,2", "") in new stack
[Jan 1 03:18:07] -- Executing [192*168*019*230*78600051@default:2] AGI("Local/192*168*019*230*78600051@default-8a4c,2", "agi-VDAD_ALL_inbound.agi|CIDLOOKUP-----LB-----HCPs-----07098141858--------------------101-----234") in new stack
[Jan 1 03:18:07] > Channel Local/192*168*019*230*78600051@default-8a4c,1 was answered.
[Jan 1 03:18:07] -- Executing [83047777777777@vicidial-auto:1] Answer("Local/192*168*019*230*78600051@default-8a4c,1", "") in new stack
[Jan 1 03:18:07] -- Executing [83047777777777@vicidial-auto:2] Playback("Local/192*168*019*230*78600051@default-8a4c,1", "ding") in new stack
[Jan 1 03:18:07] -- Launched AGI Script /var/lib/asterisk/agi-bin/agi-VDAD_ALL_inbound.agi
[Jan 1 03:18:07] -- <Local/192*168*019*230*78600051@default-8a4c,1> Playing 'ding' (language 'en')
[Jan 1 03:18:07] WARNING[4997]: file.c:1292 waitstream_core: Unexpected control subclass '-1'
[Jan 1 03:18:07] -- Executing [83047777777777@vicidial-auto:3] Hangup("Local/192*168*019*230*78600051@default-8a4c,1", "") in new stack
[Jan 1 03:18:07] == Spawn extension (vicidial-auto, 83047777777777, 3) exited non-zero on 'Local/192*168*019*230*78600051@default-8a4c,1'
[Jan 1 03:18:07] -- Executing [h@vicidial-auto:1] DeadAGI("Local/192*168*019*230*78600051@default-8a4c,1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----16---------------") in new stack
[Jan 1 03:18:07] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Jan 1 03:18:07] == Spawn extension (default, 192*168*019*230*78600051, 2) exited non-zero on 'Local/192*168*019*230*78600051@default-8a4c,2'
[Jan 1 03:18:07] -- Executing [h@default:1] DeadAGI("Local/192*168*019*230*78600051@default-8a4c,2", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Jan 1 03:18:07] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Jan 1 03:18:08] -- Stopped music on hold on DAHDI/2-1
[Jan 1 03:18:08] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:08] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:08] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:08] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:08] ERROR[4916]: utils.c:966 ast_carefulwrite: write() returned error: Broken pipe
[Jan 1 03:18:08] -- AGI Script agi-VDAD_ALL_inbound.agi completed, returning 0
[Jan 1 03:18:08] -- Executing [192*168*019*230*8600051@default:1] Answer("DAHDI/2-1", "") in new stack
[Jan 1 03:18:08] -- Executing [192*168*019*230*8600051@default:2] AGI("DAHDI/2-1", "agi-VDAD_ALL_inbound.agi|CIDLOOKUP-----LB-----HCPs-----07098141858--------------------101-----234") in new stack
[Jan 1 03:18:08] -- Launched AGI Script /var/lib/asterisk/agi-bin/agi-VDAD_ALL_inbound.agi
[Jan 1 03:18:09] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:09] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:11] -- Started music on hold, class 'default', on DAHDI/2-1
[Jan 1 03:18:11] == Manager 'sendcron' logged off from 127.0.0.1
[Jan 1 03:18:15] -- Stopped music on hold on DAHDI/2-1
[Jan 1 03:18:15] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:15] -- Playing 'sip-silence' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:16] -- Playing 'generic_hold' (escape_digits=) (sample_offset 0)
[Jan 1 03:18:16] -- Started music on hold, class 'default', on DAHDI/2-1
Whereas when I use the following dial plan
exten=>_X.,1,playback(demo-instruct)
exten=>_X.,n,goto(1)
exten=>_X.,n,hangup()
This is the cli I got
-- Accepting call from 'xxxxxxxx' to 'xxxxx' on channel 0/4, span 1
-- Executing [4482150@default:1] Playback("DAHDI/4-1", "demo-instruct") in new stack
-- <DAHDI/4-1> Playing 'demo-instruct' (language 'en')
== Refreshing DNS lookups.
== Refreshing DNS lookups.
-- Channel 0/4, span 1 got hangup request, cause 111
== Spawn extension (default, 4482150, 1) exited non-zero on 'DAHDI/4-1'
-- Executing [h@default:1] DeadAGI("DAHDI/4-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----111---------------") in new stack
-- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
-- Hungup 'DAHDI/4-1'