Сделал всё как написано на официальном сайте
http://abills.net.ua/wiki/doku.php/abills:docs:asterisk
Сначала прописал в extensions.conf:
exten => _N.,1,DeadAGI(/usr/abills/Abills/modules/Voip/agi_rad.pl)
exten => _N.,2,Hangup()
exten => _600.,1,Dial(SIP/6000)
Попробовал позвонить на 6000 молчит, после чего говорит что-то т и в панели администратора, так же ни чего не показывает.
После прописал:
exten => _N.,1,AGI(/usr/abills/Abills/modules/Voip/agi_rad.pl)
exten => _N.,1,Dial(SIP/6000)
exten => _N.,2,Hangup()
_________________________
Короче экспериментирую.
Может кто объяснит что должно выполняться после agi_rad.pl
Просто экспериментировать, не зная даже как это всё работает - по моему пустая трата времени.
abills*CLI>
<--- SIP read from UDP:XXX.XXX.160.6:40010 --->
INVITE sip:6000@XXX.XXX.160.170 SIP/2.0
Via: SIP/2.0/UDP XXX.XXX.160.6:40010;branch=z9hG4bK-d8754z-895eec48c59bf76d-1---d8754z-;rport
Max-Forwards: 70
Contact: <sip:6001@XXX.XXX.160.6:40010>
To: <sip:6000@XXX.XXX.160.170>
From: "6001"<sip:6001@XXX.XXX.160.168>;tag=7985c20c
Call-ID: MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
CSeq: 1 INVITE
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
Content-Type: application/sdp
Supported: replaces
User-Agent: X-Lite 4 release 4.0 stamp 58832
Content-Length: 408
v=0
o=- 12940182803040559 1 IN IP4 XXX.XXX.160.6
s=CounterPath X-Lite 4.0
c=IN IP4 XXX.XXX.160.6
t=0 0
a=ice-ufrag:9c9cb9
a=ice-pwd:136f1bee02050d12af5a7863ed4dc2c5
m=audio 62084 RTP/AVP 107 0 8 101
a=rtpmap:107 BV32/16000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv
a=candidate:1 1 UDP 659136 192.168.51.254 62084 typ host
a=candidate:1 2 UDP 659134 192.168.51.254 62085 typ host
<------------->
--- (13 headers 14 lines) ---
Sending to XXX.XXX.160.6 : 40010 (no NAT)
Using INVITE request as basis request - MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
Found peer '6001' for '6001' from XXX.XXX.160.6:40010
<--- Reliably Transmitting (no NAT) to XXX.XXX.160.6:40010 --->
SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP XXX.XXX.160.6:40010;branch=z9hG4bK-d8754z-895eec48c59bf76d-1---d8754z-;received=XXX.XXX.160.6;rport=40010
From: "6001"<sip:6001@XXX.XXX.160.168>;tag=7985c20c
To: <sip:6000@XXX.XXX.160.170>;tag=as3ab9ec76
Call-ID: MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
CSeq: 1 INVITE
Server: Asterisk PBX 1.6.2.7-1ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="asterisk", nonce="3868f167"
Content-Length: 0
<------------>
Scheduling destruction of SIP dialog 'MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.' in 32000 ms (Method: INVITE)
abills*CLI>
<--- SIP read from UDP:XXX.XXX.160.6:40010 --->
ACK sip:6000@XXX.XXX.160.170 SIP/2.0
Via: SIP/2.0/UDP XXX.XXX.160.6:40010;branch=z9hG4bK-d8754z-895eec48c59bf76d-1---d8754z-;rport
Max-Forwards: 70
To: <sip:6000@XXX.XXX.160.170>;tag=as3ab9ec76
From: "6001"<sip:6001@XXX.XXX.160.168>;tag=7985c20c
Call-ID: MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
CSeq: 1 ACK
Content-Length: 0
<------------->
--- (8 headers 0 lines) ---
abills*CLI>
<--- SIP read from UDP:XXX.XXX.160.6:40010 --->
INVITE sip:6000@XXX.XXX.160.170 SIP/2.0
Via: SIP/2.0/UDP XXX.XXX.160.6:40010;branch=z9hG4bK-d8754z-7dbf3123337b6bc5-1---d8754z-;rport
Max-Forwards: 70
Contact: <sip:6001@XXX.XXX.160.6:40010>
To: <sip:6000@XXX.XXX.160.170>
From: "6001"<sip:6001@XXX.XXX.160.168>;tag=7985c20c
Call-ID: MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
CSeq: 2 INVITE
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
Content-Type: application/sdp
Supported: replaces
User-Agent: X-Lite 4 release 4.0 stamp 58832
Authorization: Digest username="6001",realm="asterisk",nonce="3868f167",uri="sip:6000@XXX.XXX.160.170",response="48b859a510ed4ef866c75a80f790774d",algorithm=MD5
Content-Length: 408
v=0
o=- 12940182803040559 1 IN IP4 XXX.XXX.160.6
s=CounterPath X-Lite 4.0
c=IN IP4 XXX.XXX.160.6
t=0 0
a=ice-ufrag:9c9cb9
a=ice-pwd:136f1bee02050d12af5a7863ed4dc2c5
m=audio 62084 RTP/AVP 107 0 8 101
a=rtpmap:107 BV32/16000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv
a=candidate:1 1 UDP 659136 192.168.51.254 62084 typ host
a=candidate:1 2 UDP 659134 192.168.51.254 62085 typ host
<------------->
--- (14 headers 14 lines) ---
Sending to XXX.XXX.160.6 : 40010 (no NAT)
Using INVITE request as basis request - MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
Found peer '6001' for '6001' from XXX.XXX.160.6:40010
Found RTP audio format 107
Found RTP audio format 0
Found RTP audio format 8
Found RTP audio format 101
Found audio description format BV32 for ID 107
Found audio description format telephone-event for ID 101
Capabilities: us - 0x4 (ulaw), peer - audio=0xc (ulaw|alaw)/video=0x0 (nothing)/text=0x0 (nothing), combined - 0x4 (ulaw)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event), peer - 0x1 (telephone-event), combined - 0x1 (telephone-event)
Peer audio RTP is at port XXX.XXX.160.6:62084
Looking for 6000 in default (domain XXX.XXX.160.170)
list_route: hop: <sip:6001@XXX.XXX.160.6:40010>
<--- Transmitting (no NAT) to XXX.XXX.160.6:40010 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP XXX.XXX.160.6:40010;branch=z9hG4bK-d8754z-7dbf3123337b6bc5-1---d8754z-;received=XXX.XXX.160.6;rport=40010
From: "6001"<sip:6001@XXX.XXX.160.168>;tag=7985c20c
To: <sip:6000@XXX.XXX.160.170>
Call-ID: MTQ1ZWQ4MjUwM2FkOWI5NDA2Mzk1OTllYWUyYzFlOTA.
CSeq: 2 INVITE
Server: Asterisk PBX 1.6.2.7-1ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Contact: <sip:6000@XXX.XXX.160.168>
Content-Length: 0