ВидеоКонф(ВКС)  ::   Чат  ::   FAQ  ::   Поиск  ::   Регистрация  ::   Вход

Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Новичком считается только что прочитавший «Астериск - будущее телефонии»
http://asterisk.ru/knowledgebase/books
и пытающийся сделать большее

Модератор: april22

Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение zaken » 21 дек 2021, 13:36

Приветствую вас, коллеги!

Приходят в здание медные линии от Ростелекома, нужно их задействовать и преобразовать в SIP. Приобрел голосовой шлюз Grandstream GXW4108, произвел настройки согласно инструкций к оборудованию. Поднял Asterisk, произвел начальные настройки.

Местные внутренние звонки работают.
Входящий на медный городской номер работают (звонят местные внутренние телефоны).
Не получается настроить исходящий вызов через медный номер (на мобильный\городской номер и т.д.).
Прошу помощи разобраться в чём проблема.

tcpdump host IP-adress Grandstream GXW4108:
[Показать] Спойлер:
09:01:48.118868 IP asterisk.sip > 10.XXX.XXX.194.sip: SIP: CANCEL sip:89003336666@10.XXX.XXX.194 SIP/2.0
09:01:48.120542 IP 10.XXX.XXX.194.sip > asterisk.sip: SIP: SIP/2.0 200 OK
09:01:48.120878 IP 10.XXX.XXX.194.sip > asterisk.sip: SIP: SIP/2.0 487 Request Cancelled
09:01:48.121169 IP asterisk.sip > 10.XXX.XXX.194.sip: SIP: ACK sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
09:01:53.236439 ARP, Request who-has 10.XXX.XXX.194 tell asterisk, length 28
09:01:53.236841 ARP, Reply 10.XXX.XXX.194 is-at 00:0b:82:e9:da:cf (oui Unknown), length 50


sip set debug on (при первом исходящем звонке):
[Показать] Спойлер:
<------------>
-- Executing [89003336666@lc:1] Dial("SIP/32101-00000000", "SIP/89003336666@101") in new stack
Audio is at 11524
Adding codec ulaw to SDP
Adding codec alaw to SDP
Adding codec gsm to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (no NAT) to 10.XXX.XXX.194:5060:
INVITE sip:89003336666@10.XXX.XXX.194 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK779d4c7c
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Date: Tue, 21 Dec 2021 08:55:35 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 302

v=0
o=root 1345826106 1345826106 IN IP4 10.XXX.XXX.193
s=Asterisk PBX 16.2.1~dfsg-2ubuntu1
c=IN IP4 10.XXX.XXX.193
t=0 0
m=audio 11524 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=maxptime:150
a=sendrecv

---
-- Called SIP/89003336666@101

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK779d4c7c
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:0) 1.4.1.5
Content-Length: 0

<------------->
--- (8 headers 0 lines) ---

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK779d4c7c
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:0) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Length: 0

<------------->
--- (10 headers 0 lines) ---
sip_route_dump: route/path hop: <sip:101@10.XXX.XXX.194:5060;transport=udp>
-- SIP/101-00000001 is ringing

<--- Transmitting (no NAT) to 10.XXX.XXX.201:5060 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.XXX.XXX.201:5060;branch=z9hG4bK3406374704;received=10.XXX.XXX.201
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=2567120686
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7ac1f850
Call-ID: 0_4268566319@10.XXX.XXX.201
CSeq: 2 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Contact: <sip:89003336666@10.XXX.XXX.193:5060>
Content-Length: 0


<------------>

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK779d4c7c
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:0) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Type: application/sdp
Supported: replaces, timer, 100rel, path
Content-Length: 219

v=0
o=101 8000 8000 IN IP4 10.XXX.XXX.194
s=SIP Call
c=IN IP4 10.XXX.XXX.194
t=0 0
m=audio 5004 RTP/AVP 0 18 4 3 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
<------------->
--- (12 headers 11 lines) ---
Found RTP audio format 0
Found RTP audio format 18
Found RTP audio format 4
Found RTP audio format 3
Found RTP audio format 101
Found audio description format PCMU for ID 0
Found audio description format telephone-event for ID 101
Capabilities: us - (ulaw|alaw|gsm|h263), peer - audio=(ulaw|gsm|g723|g729)/video=(nothing)/text=(nothing), combined - (ulaw|gsm)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
> 0x7f7f1400be40 -- Strict RTP learning after remote address set to: 10.XXX.XXX.194:5004
Peer audio RTP is at port 10.XXX.XXX.194:5004
sip_route_dump: route/path hop: <sip:101@10.XXX.XXX.194:5060;transport=udp>
set_destination: Parsing <sip:101@10.XXX.XXX.194:5060;transport=udp> for address/port to send to
set_destination: set destination to 10.XXX.XXX.194:5060
Transmitting (no NAT) to 10.XXX.XXX.194:5060:
ACK sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK2acb36e2
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0


---
-- SIP/101-00000001 answered SIP/32101-00000000
Audio is at 12592
Adding codec ulaw to SDP
Adding codec alaw to SDP
Adding non-codec 0x1 (telephone-event) to SDP

<--- Reliably Transmitting (no NAT) to 10.XXX.XXX.201:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.201:5060;branch=z9hG4bK3406374704;received=10.XXX.XXX.201
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=2567120686
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7ac1f850
Call-ID: 0_4268566319@10.XXX.XXX.201
CSeq: 2 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Contact: <sip:89003336666@10.XXX.XXX.193:5060>
Content-Type: application/sdp
Content-Length: 279

v=0
o=root 1809326997 1809326997 IN IP4 10.XXX.XXX.193
s=Asterisk PBX 16.2.1~dfsg-2ubuntu1
c=IN IP4 10.XXX.XXX.193
t=0 0
m=audio 12592 RTP/AVP 0 8 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=maxptime:150
a=sendrecv

<------------>

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK779d4c7c
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:0) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Type: application/sdp
Supported: replaces, timer, 100rel, path
Content-Length: 219

v=0
o=101 8000 8001 IN IP4 10.XXX.XXX.194
s=SIP Call
c=IN IP4 10.XXX.XXX.194
t=0 0
m=audio 5004 RTP/AVP 0 18 4 3 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
<------------->
--- (12 headers 11 lines) ---
set_destination: Parsing <sip:101@10.XXX.XXX.194:5060;transport=udp> for address/port to send to
set_destination: set destination to 10.XXX.XXX.194:5060
Transmitting (no NAT) to 10.XXX.XXX.194:5060:
ACK sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK236072f0
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0


---
-- Channel SIP/101-00000001 joined 'simple_bridge' basic-bridge <0b846018-1076-4269-bcd7-7833cf57082a>
-- Channel SIP/32101-00000000 joined 'simple_bridge' basic-bridge <0b846018-1076-4269-bcd7-7833cf57082a>
> Bridge 0b846018-1076-4269-bcd7-7833cf57082a: switching from simple_bridge technology to native_rtp
> Locally RTP bridged 'SIP/32101-00000000' and 'SIP/101-00000001' in stack

<--- SIP read from UDP:10.XXX.XXX.201:5060 --->
ACK sip:89003336666@10.XXX.XXX.193:5060 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.201:5060;branch=z9hG4bK867051314
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=2567120686
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7ac1f850
Call-ID: 0_4268566319@10.XXX.XXX.201
CSeq: 2 ACK
Contact: <sip:32101@10.XXX.XXX.201:5060>
Max-Forwards: 70
User-Agent: Yealink SIP-T46U 108.85.14.1
Content-Length: 0

<------------->
--- (10 headers 0 lines) ---
> 0x7f7f1400be40 -- Strict RTP switching to RTP target address 10.XXX.XXX.194:5004 as source
> 0x7f7f2000ec30 -- Strict RTP switching to RTP target address 10.XXX.XXX.201:12588 as source

<--- SIP read from UDP:10.XXX.XXX.200:5060 --->


<------------->
> 0x7f7f2000ec30 -- Strict RTP learning complete - Locking on source address 10.XXX.XXX.201:12588
> 0x7f7f1400be40 -- Strict RTP learning complete - Locking on source address 10.XXX.XXX.194:5004

<--- SIP read from UDP:10.XXX.XXX.201:5060 --->
BYE sip:89003336666@10.XXX.XXX.193:5060 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.201:5060;branch=z9hG4bK3855820595
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=2567120686
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7ac1f850
Call-ID: 0_4268566319@10.XXX.XXX.201
CSeq: 3 BYE
Contact: <sip:32101@10.XXX.XXX.201:5060>
Authorization: Digest username="32101", realm="asterisk", nonce="76cf0304", uri="sip:89003336666@10.XXX.XXX.193:5060", response="a904e75a6d23a87c5ea3f32a0701696f", algorithm=MD5
Max-Forwards: 70
User-Agent: Yealink SIP-T46U 108.85.14.1
Content-Length: 0

<------------->
--- (11 headers 0 lines) ---
Sending to 10.XXX.XXX.201:5060 (no NAT)
Scheduling destruction of SIP dialog '0_4268566319@10.XXX.XXX.201' in 32000 ms (Method: BYE)

<--- Transmitting (no NAT) to 10.XXX.XXX.201:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.201:5060;branch=z9hG4bK3855820595;received=10.XXX.XXX.201
From: "Николашина Е. > ▒." <sip:32101@10.XXX.XXX.193:5060>;tag=2567120686
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7ac1f850
Call-ID: 0_4268566319@10.XXX.XXX.201
CSeq: 3 BYE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0


<------------>
-- Channel SIP/32101-00000000 left 'native_rtp' basic-bridge <0b846018-1076-4269-bcd7-7833cf57082a>
== Spawn extension (lc, 89003336666, 1) exited non-zero on 'SIP/32101-00000000'
-- Channel SIP/101-00000001 left 'native_rtp' basic-bridge <0b846018-1076-4269-bcd7-7833cf57082a>
Scheduling destruction of SIP dialog '465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060' in 6400 ms (Method: INVITE)
set_destination: Parsing <sip:101@10.XXX.XXX.194:5060;transport=udp> for address/port to send to
set_destination: set destination to 10.XXX.XXX.194:5060
Reliably Transmitting (no NAT) to 10.XXX.XXX.194:5060:
BYE sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK5fc4ecb4
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 103 BYE
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
X-Asterisk-HangupCause: Normal Clearing
X-Asterisk-HangupCauseCode: 16
Content-Length: 0


---

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK5fc4ecb4
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as46568a44
To: <sip:89003336666@10.XXX.XXX.194>;tag=bf11b244d5449ac2
Call-ID: 465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060
CSeq: 103 BYE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:0) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Supported: replaces, timer, 100rel, path
Content-Length: 0

<------------->
--- (11 headers 0 lines) ---
Really destroying SIP dialog '465e09057c3774f73bdf5468095de1d5@10.XXX.XXX.193:5060' Method: INVITE


sip set debug on (последующие исходящие звонки):
[Показать] Спойлер:
-- Executing [89003336666@lc:1] Dial("SIP/32101-00000002", "SIP/89003336666@101") in new stack
Audio is at 17196
Adding codec ulaw to SDP
Adding codec alaw to SDP
Adding codec gsm to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (no NAT) to 10.XXX.XXX.194:5060:
INVITE sip:89003336666@10.XXX.XXX.194 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Date: Tue, 21 Dec 2021 08:57:06 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 302

v=0
o=root 1444045914 1444045914 IN IP4 10.XXX.XXX.193
s=Asterisk PBX 16.2.1~dfsg-2ubuntu1
c=IN IP4 10.XXX.XXX.193
t=0 0
m=audio 17196 RTP/AVP 0 8 3 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=maxptime:150
a=sendrecv

---
-- Called SIP/89003336666@101

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:1) 1.4.1.5
Content-Length: 0

<------------->
--- (8 headers 0 lines) ---

<--- SIP read from UDP:10.XXX.XXX.200:5060 --->


<------------->

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>;tag=e877289379a60462
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:1) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Length: 0

<------------->
--- (10 headers 0 lines) ---
sip_route_dump: route/path hop: <sip:101@10.XXX.XXX.194:5060;transport=udp>
-- SIP/101-00000003 is ringing

<--- Transmitting (no NAT) to 10.XXX.XXX:5060 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.XXX.XXX:5060;branch=z9hG4bK1200629558;received=10.XXX.XXX
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=1464084276
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7d61f5bd
Call-ID: 0_1525229365@10.XXX.XXX
CSeq: 2 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Contact: <sip:89003336666@10.XXX.XXX.193:5060>
Content-Length: 0


<------------>
Reliably Transmitting (no NAT) to 10.XXX.XXX.194:5060:
OPTIONS sip:10.XXX.XXX.194 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK3e529daa
Max-Forwards: 70
From: "asterisk" <sip:asterisk@10.XXX.XXX.193>;tag=as4244d2c4
To: <sip:10.XXX.XXX.194>
Contact: <sip:asterisk@10.XXX.XXX.193:5060>
Call-ID: 5943a336767f6d5c434f4caf70bd0508@10.XXX.XXX.193:5060
CSeq: 102 OPTIONS
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Date: Tue, 21 Dec 2021 08:57:28 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0


---

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK3e529daa
From: "asterisk" <sip:asterisk@10.XXX.XXX.193>;tag=as4244d2c4
To: <sip:10.XXX.XXX.194>;tag=205303b5bf736317
Call-ID: 5943a336767f6d5c434f4caf70bd0508@10.XXX.XXX.193:5060
CSeq: 102 OPTIONS
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:8) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Supported: replaces, timer, 100rel, path
Content-Length: 0

<------------->
--- (11 headers 0 lines) ---
Really destroying SIP dialog '5943a336767f6d5c434f4caf70bd0508@10.XXX.XXX.193:5060' Method: OPTIONS

<--- SIP read from UDP:10.XXX.XXX.202:5060 --->


<------------->

<--- SIP read from UDP:10.XXX.XXX:5060 --->


<------------->

<--- SIP read from UDP:10.XXX.XXX.203:5060 --->


<------------->

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>;tag=e877289379a60462
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:1) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Type: application/sdp
Supported: replaces, timer, 100rel, path
Content-Length: 219

v=0
o=101 8001 8000 IN IP4 10.XXX.XXX.194
s=SIP Call
c=IN IP4 10.XXX.XXX.194
t=0 0
m=audio 5008 RTP/AVP 0 18 4 3 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
<------------->
--- (12 headers 11 lines) ---
Found RTP audio format 0
Found RTP audio format 18
Found RTP audio format 4
Found RTP audio format 3
Found RTP audio format 101
Found audio description format PCMU for ID 0
Found audio description format telephone-event for ID 101
Capabilities: us - (ulaw|alaw|gsm|h263), peer - audio=(ulaw|gsm|g723|g729)/video=(nothing)/text=(nothing), combined - (ulaw|gsm)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
> 0x55a390518430 -- Strict RTP learning after remote address set to: 10.XXX.XXX.194:5008
Peer audio RTP is at port 10.XXX.XXX.194:5008
sip_route_dump: route/path hop: <sip:101@10.XXX.XXX.194:5060;transport=udp>
set_destination: Parsing <sip:101@10.XXX.XXX.194:5060;transport=udp> for address/port to send to
set_destination: set destination to 10.XXX.XXX.194:5060
Transmitting (no NAT) to 10.XXX.XXX.194:5060:
ACK sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK47a1024d
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>;tag=e877289379a60462
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0


---

<--- SIP read from UDP:10.XXX.XXX.194:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>;tag=e877289379a60462
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 INVITE
User-Agent: Grandstream GXW4108 (HW 2.3, Ch:1) 1.4.1.5
Contact: <sip:101@10.XXX.XXX.194:5060;transport=udp>
Allow: INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK
Content-Type: application/sdp
Supported: replaces, timer, 100rel, path
Content-Length: 219

v=0
o=101 8001 8001 IN IP4 10.XXX.XXX.194
s=SIP Call
c=IN IP4 10.XXX.XXX.194
t=0 0
m=audio 5008 RTP/AVP 0 18 4 3 101
a=sendrecv
a=rtpmap:0 PCMU/8000
a=ptime:20
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-11
<------------->
--- (12 headers 11 lines) ---
set_destination: Parsing <sip:101@10.XXX.XXX.194:5060;transport=udp> for address/port to send to
set_destination: set destination to 10.XXX.XXX.194:5060
Transmitting (no NAT) to 10.XXX.XXX.194:5060:
ACK sip:101@10.XXX.XXX.194:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK272b0373
Max-Forwards: 70
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>;tag=as550f5b0c
To: <sip:89003336666@10.XXX.XXX.194>;tag=e877289379a60462
Contact: <sip:414141@10.XXX.XXX.193:5060>
Call-ID: 71cd2209169f05e118890923048871da@10.XXX.XXX.193:5060
CSeq: 102 ACK
User-Agent: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Content-Length: 0


---
-- SIP/101-00000003 answered SIP/32101-00000002
Audio is at 17560
Adding codec ulaw to SDP
Adding codec alaw to SDP
Adding non-codec 0x1 (telephone-event) to SDP

<--- Reliably Transmitting (no NAT) to 10.XXX.XXX:5060 --->
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.XXX.XXX:5060;branch=z9hG4bK1200629558;received=10.XXX.XXX
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=1464084276
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7d61f5bd
Call-ID: 0_1525229365@10.XXX.XXX
CSeq: 2 INVITE
Server: Asterisk PBX 16.2.1~dfsg-2ubuntu1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Contact: <sip:89003336666@10.XXX.XXX.193:5060>
Content-Type: application/sdp
Content-Length: 275

v=0
o=root 67928948 67928948 IN IP4 10.XXX.XXX.193
s=Asterisk PBX 16.2.1~dfsg-2ubuntu1
c=IN IP4 10.XXX.XXX.193
t=0 0
m=audio 17560 RTP/AVP 0 8 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=maxptime:150
a=sendrecv

<------------>
-- Channel SIP/101-00000003 joined 'simple_bridge' basic-bridge <dca56c65-fcc6-4741-91ba-e730bc8171c4>
-- Channel SIP/32101-00000002 joined 'simple_bridge' basic-bridge <dca56c65-fcc6-4741-91ba-e730bc8171c4>
> Bridge dca56c65-fcc6-4741-91ba-e730bc8171c4: switching from simple_bridge technology to native_rtp
> Locally RTP bridged 'SIP/32101-00000002' and 'SIP/101-00000003' in stack

<--- SIP read from UDP:10.XXX.XXX:5060 --->
ACK sip:89003336666@10.XXX.XXX.193:5060 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX:5060;branch=z9hG4bK2115774264
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>;tag=1464084276
To: <sip:89003336666@10.XXX.XXX.193:5060>;tag=as7d61f5bd
Call-ID: 0_1525229365@10.XXX.XXX
CSeq: 2 ACK
Contact: <sip:32101@10.XXX.XXX:5060>
Max-Forwards: 70
User-Agent: Yealink SIP-T46U 108.85.14.1
Content-Length: 0

<------------->
--- (10 headers 0 lines) ---
> 0x55a390518430 -- Strict RTP switching to RTP target address 10.XXX.XXX.194:5008 as source
> 0x7f7f2000ec30 -- Strict RTP switching to RTP target address 10.XXX.XXX:12590 as source
> 0x7f7f2000ec30 -- Strict RTP learning complete - Locking on source address 10.XXX.XXX:12590

<--- SIP read from UDP:10.XXX.XXX.200:5060 --->


extensions.conf:
[Показать] Спойлер:
[from-trunk]
exten => _xxxxx,1,Dial(SIP/${EXTEN},,m)
exten => _8xxxxxxxxxx,1,Dial(SIP/${EXTEN}@101)

[lc]
exten => _xxxxx,1,Dial(SIP/${EXTEN},,m)
exten => _8xxxxxxxxxx,1,Dial(SIP/${EXTEN}@101)


sip.conf:
[Показать] Спойлер:
[101]
type=friend
host=10.XXX.XXX.194
username=101
secret=101
qualify=yes
insecure=port
context=from-trunk
canreinvite=no
dtmfmode=rfc2833


Сильно не бейте, опыта 0, пытаюсь разобраться самостоятельно... Направьте в нужное русло пожалуйста!
zaken
 
Сообщений: 3
Зарегистрирован: 17 дек 2021, 17:23

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение sasa » 22 дек 2021, 16:11

Нету лога о том что там ходит по медным проводам в шлюзе
sasa
 
Сообщений: 119
Зарегистрирован: 22 янв 2019, 15:41

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение zaken » 22 дек 2021, 16:15

подскажите пожалуйста как собрать данный лог?
zaken
 
Сообщений: 3
Зарегистрирован: 17 дек 2021, 17:23

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение zaken » 22 дек 2021, 16:20

Ещё дополнение, на шлюзе не могу добиться чтобы было "Yes" в разделе Status-Account Status- Sip Registration "No". В Account 1 прописаны настройки и User Account введены данные Sip User ID\Authenticate ID\Password.

System Info
Product Model: GXW4108
Hardware Revision: 2.3 Rev A
Part Number: 966-00002-23A

Program : 1.4.1.5
Loader : 1.1.3.4
Boot : 1.1.3.2
zaken
 
Сообщений: 3
Зарегистрирован: 17 дек 2021, 17:23

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение Zavr2008 » 24 дек 2021, 13:51

Настройки не те малость.

Скорее не type=friend, а type=peer. insecure убрать.
username параметр устарел - есть defaultuser и fromuser. canreinvite тоже устарел, использовать directmedia=no

Еще прилетает в from_trunk, там есть
Код: выделить все
exten => _8xxxxxxxxxx,1,Dial(SIP/${EXTEN}@101)

У Вас транзит, при желании можно донабрать с входящего во весь открытый мир..

Есть книжка - Астериск Будущее Телефонии, Вам бы примеры оттуда поделать и поднавтыкаться, потом уже на продакшен.
Еще можно FreePBX :)
Российские шлюзы E1 Alvis-GW. Voip-Модернизация УПАТС, FreePBX, CRM. Продолжаем работать, импортозамещаем!
Аватар пользователя
Zavr2008
 
Сообщений: 1933
Зарегистрирован: 27 янв 2011, 01:35

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение ded » 24 дек 2021, 13:58

Тут и
From: "Пользователь 1" <sip:32101@10.XXX.XXX.193:5060>
и одновременно
From: "Polzovatel 1" <sip:414141@10.XXX.XXX.193>

Сумбур. Что есть что?

И для чего .XXX.XXX?
INVITE sip:89003336666@10.XXX.XXX.194 SIP/2.0
Via: SIP/2.0/UDP 10.XXX.XXX.193:5060;branch=z9hG4bK363e2167
Скрывать внутренние адреса - какая цель? Чтобы не взломали с другого внкутреннего адреса 192.168.1.12?
ded
 
Сообщений: 15239
Зарегистрирован: 26 авг 2010, 19:00

Re: Asterisk 16.2.1 [ubuntu-20.04.3] + Grandstream GXW4108

Сообщение Zavr2008 » 24 дек 2021, 14:38

Тем не менее с подобного все мы так и начинали. Постепенно начинает доходить суть, через какое-то время начинаешь смотреть на диалплан свой как на сами знаете что. И это - нормально!
Главное терпения и не подрубать всё в прод - в песочнице на виртуалке сначала, чтобы Сомали и прочее не накернили..
Российские шлюзы E1 Alvis-GW. Voip-Модернизация УПАТС, FreePBX, CRM. Продолжаем работать, импортозамещаем!
Аватар пользователя
Zavr2008
 
Сообщений: 1933
Зарегистрирован: 27 янв 2011, 01:35


Вернуться в Вопросы новичков

Кто сейчас на форуме

Сейчас этот форум просматривают: нет зарегистрированных пользователей и гости: 15

© 2008 — 2022 Asterisk.ru
Digium, Asterisk and AsteriskNOW are registered trademarks of Digium, Inc.
Design and development by PostMet-Netzwerk GmbH