Remote end audio goes silent on INVITE from provide for ongoing call

Hi all,

I am facing an issue for few calls running on my asterisk server (18) where after round 14 or 15 mins I am receiving an INVITE message from provider and when it receives ACK on it the RTP from provider stops abruptly.

Can someone help me understand why this could happen or how can I handle this situation by config in asterisk.

Please refer below screenshot of SIP message flow,

Also I am pastiing below 200 OK on 1st INVITE and incoming INVITE withing ongoing call.

INVITE sip:XXXXXXXXXX@XX.XX.XX.XX:5060;user=phone SIP/2.0
Via: SIP/2.0/UDP 10.10.38.12:5060;rport;branch=z9hG4bKPjdf19ffc6-362c-4203-a16d-0650d8b8e555
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>
Contact: <sip:asterisk@10.10.38.12:5060>
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21150 INVITE
Allow: OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
Supported: 100rel, timer, replaces, norefersub, histinfo
Session-Expires: 1800
Min-SE: 90
Max-Forwards: 70
User-Agent: Asterisk PBX 18.16.0
Content-Type: application/sdp
Content-Length:   257

v=0
o=- 472505607 472505607 IN IP4 10.10.38.12
s=Asterisk
c=IN IP4 10.10.38.12
t=0 0
m=audio 60216 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=ptime:20
a=maxptime:150
a=sendrecv


SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 10.10.38.12:5060;rport=5060;branch=z9hG4bKPjdf19ffc6-362c-4203-a16d-0650d8b8e555;received=20.161.15.73
Record-Route: <sip:XX.XX.XX.XX;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K46BYXA____.i
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21150 INVITE
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
Server: PortaSIP
WWW-Authenticate: Digest realm="XX.XX.XX.XX",nonce="1690818200:842a7f01b70e3b0b228bf49789bcd75b6a6b384b"
Content-Length: 0

ACK sip:XXXXXXXXXX@XX.XX.XX.XX:5060;user=phone SIP/2.0
Via: SIP/2.0/UDP 10.10.38.12:5060;rport;branch=z9hG4bKPjdf19ffc6-362c-4203-a16d-0650d8b8e555
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K46BYXA____.i
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21150 ACK
Max-Forwards: 70
User-Agent: Asterisk PBX 18.16.0
Content-Length:  0

INVITE sip:XXXXXXXXXX@XX.XX.XX.XX:5060;user=phone SIP/2.0
Via: SIP/2.0/UDP 10.10.38.12:5060;rport;branch=z9hG4bKPjd4959cb6-629f-4a35-899c-638c36a7f85f
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>
Contact: <sip:asterisk@10.10.38.12:5060>
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21151 INVITE
Allow: OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
Supported: 100rel, timer, replaces, norefersub, histinfo
Session-Expires: 1800
Min-SE: 90
Max-Forwards: 70
User-Agent: Asterisk PBX 18.16.0
Authorization: Digest username="40201001", realm="XX.XX.XX.XX", nonce="1690818200:842a7f01b70e3b0b228bf49789bcd75b6a6b384b", uri="sip:XXXXXXXXXX@XX.XX.XX.XX:5060;user=phone", response="4ccca11f19283a415628c0ab24878467"
Content-Type: application/sdp
Content-Length:   257

v=0
o=- 472505607 472505607 IN IP4 10.10.38.12
s=Asterisk
c=IN IP4 10.10.38.12
t=0 0
m=audio 60216 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=ptime:20
a=maxptime:150
a=sendrecv


SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.10.38.12:5060;rport=5060;branch=z9hG4bKPjd4959cb6-629f-4a35-899c-638c36a7f85f;received=20.161.15.73
Record-Route: <sip:XX.XX.XX.XX;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21151 INVITE
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS, UPDATE
Server: PortaSIP
Content-Length: 0


SIP/2.0 183 Session Progress
Via: SIP/2.0/UDP 10.10.38.12:5060;rport=5060;branch=z9hG4bKPjd4959cb6-629f-4a35-899c-638c36a7f85f;received=20.161.15.73
Record-Route: <sip:XX.XX.XX.XX;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
Contact: sip:YY.YY.YY.YY:5071
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21151 INVITE
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS, UPDATE
Content-Type: application/sdp
Server: PortaSIP
Content-Length: 236

v=0
o=PortaSIP 3411106069884160858 1 IN IP4 YY.YY.YY.YY
s=SBCSIPUAS SIP STACK v1.0
t=0 0
m=audio 45762 RTP/AVP 0 101
c=IN IP4 YY.YY.YY.YY
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv


SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.10.38.12:5060;rport=5060;branch=z9hG4bKPjd4959cb6-629f-4a35-899c-638c36a7f85f;received=20.161.15.73
Record-Route: <sip:XX.XX.XX.XX;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
Contact: sip:YY.YY.YY.YY:5071
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21151 INVITE
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS, UPDATE
Content-Type: application/sdp
Server: PortaSIP
Content-Length: 236

v=0
o=PortaSIP 3411106069884160858 1 IN IP4 YY.YY.YY.YY
s=SBCSIPUAS SIP STACK v1.0
t=0 0
m=audio 45762 RTP/AVP 0 101
c=IN IP4 YY.YY.YY.YY
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv

ACK sip:YY.YY.YY.YY:5071 SIP/2.0
Via: SIP/2.0/UDP 10.10.38.12:5060;rport;branch=z9hG4bKPjedcbac66-3913-4981-82dd-96ff59ca1150
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21151 ACK
Route: <sip:XX.XX.XX.XX:5060;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
Max-Forwards: 70
User-Agent: Asterisk PBX 18.16.0
Content-Length:  0



INVITE sip:asterisk@10.10.38.12:5060 SIP/2.0
Via: SIP/2.0/UDP XX.XX.XX.XX:5060;branch=z9hG4bK-524287-1---7f6335257210048510b866741c094fdb;rport
Via: SIP/2.0/UDP YY.YY.YY.YY:5071;rport=5071;branch=z9hG4bK-i3qwugpbc6453hkh
Max-Forwards: 69
Contact: sip:YY.YY.YY.YY:5071
To: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
From: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 517 INVITE
Expires: 300
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS, UPDATE
Content-Disposition: session
Content-Type: application/sdp
User-Agent: PortaSIP
h323-conf-id: 2427876100-105759659-1071331209-1542045015
cisco-GUID: 2427876100-105759659-1071331209-1542045015
Content-Length: 236

v=0
o=PortaSIP 3411106069884160858 1 IN IP4 YY.YY.YY.YY
s=SBCSIPUAS SIP STACK v1.0
t=0 0
m=audio 45762 RTP/AVP 0 101
c=IN IP4 YY.YY.YY.YY
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv


SIP/2.0 200 OK
Via: SIP/2.0/UDP XX.XX.XX.XX:5060;rport=5060;received=XX.XX.XX.XX;branch=z9hG4bK-524287-1---7f6335257210048510b866741c094fdb
Via: SIP/2.0/UDP YY.YY.YY.YY:5071;rport=5071;branch=z9hG4bK-i3qwugpbc6453hkh
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
From: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
To: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
CSeq: 517 INVITE
Contact: <sip:asterisk@10.10.38.12:5060>
Allow: OPTIONS, REGISTER, SUBSCRIBE, NOTIFY, PUBLISH, INVITE, ACK, BYE, CANCEL, UPDATE, PRACK, MESSAGE, REFER
Supported: 100rel, timer, replaces, norefersub
Server: Asterisk PBX 18.16.0
Content-Type: application/sdp
Content-Length:   233

v=0
o=- 472505607 472505608 IN IP4 10.10.38.12
s=Asterisk
c=IN IP4 10.10.38.12
t=0 0
m=audio 60216 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=maxptime:150
a=sendrecv


ACK sip:asterisk@10.10.38.12:5060 SIP/2.0
Via: SIP/2.0/UDP XX.XX.XX.XX:5060;branch=z9hG4bK-524287-1---feb62cf378a551bf1abdc23321c2df20;rport
Via: SIP/2.0/UDP YY.YY.YY.YY:5071;rport=5071;branch=z9hG4bK-sw27qw5dxvogvotv
Max-Forwards: 69
Contact: sip:YY.YY.YY.YY:5071
To: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
From: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 517 ACK
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
User-Agent: PortaSIP
Content-Length: 0


BYE sip:YY.YY.YY.YY:5071 SIP/2.0
Via: SIP/2.0/UDP 10.10.38.12:5060;rport;branch=z9hG4bKPjbd1477a1-83e4-4ebb-a5ed-b919fad08582
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21152 BYE
Route: <sip:XX.XX.XX.XX:5060;lr;ep;pinhole=UDP:20.161.15.73:59991;ipnt=8j0umvkwtn3>
Reason: Q.850;cause=16
Max-Forwards: 70
User-Agent: Asterisk PBX 18.16.0
Content-Length:  0



SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.10.38.12:5060;rport=5060;branch=z9hG4bKPjbd1477a1-83e4-4ebb-a5ed-b919fad08582;received=20.161.15.73
To: <sip:XXXXXXXXXX@XX.XX.XX.XX;user=phone>;tag=NGPPDRA4T5VJ5K467CFA____.i
From: "14699833569" <sip:14699833569@10.10.38.12;user=phone>;tag=1021521d-be4b-4056-a6b4-e9ae979a0f08
Call-ID: dd1efdf8-c1c1-4c5e-8939-9024eb795988
CSeq: 21152 BYE
Allow: INVITE, ACK, BYE, CANCEL, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS, UPDATE
Server: PortaSIP
Content-Length: 0


Log is incomplete.

As i mentioned i pasted only 2 SIP messages of 200 ok and INVITE message coming from provider while on call.

can you help me what all logs will be required.

Your description mentions an ACK, so I expect to see that in the log.

The OK and the INVITE are in the wrong order, which is because they relate to two different transactions, the first from Asterisk, and the second from PortaSIP.

I will repaste the complete sip logs as per the screenshot

I now provided complete call logs. Kindly suggest if more information is required. Thanks.

hi are your asterisk behind NAT and do you have the posibility to do some portforward

you may want to play around with these options

; For the NAT transport example, be aware that the options starting with
; the prefix "external_" will only apply to communication with addresses
; outside the range set with "local_net=".
;
;disable_direct_media_on_nat=no ; Disable direct media session refreshes when
                                ; NAT obstructs the media session (default:
                                ; "no")
;ice_support=no ; Enable the ICE mechanism to help traverse NAT (default: "no")
;external_media_address=        ; External IP address to use in RTP handling
                                ; (default: "")
;external_signaling_address=    ; External address for SIP signalling (default:
                                ; "")
;external_signaling_port=0      ; External port for SIP signalling (default:
                                ; "0")
;local_net=     ; Network to consider local used for NAT purposes (default: "")

The re-INVITE will be for session timers. Whilst Asterisk is sending updated SDP, that SDP isn’t really updated, and the previous SDP worked, with the same settings. I’d say the provider was broken.

Whilst, ideally, the SDP serial number should not have changed, I can’t see that a change would make any real difference.

Not sure about the exact problem but the carrier change at provider end resolved this issue. But, I would really want to understand what was wrong with the INVITE coming for ongoing call.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.