[asterisk-users] NAT problem: "Retransmission timeout reached on transmission … for seqno 2 (Critical Response)"

Jeremy Malcolm Jeremy at Malcolm.id.au
Sun May 27 07:48:14 CDT 2012


I can't receive an incoming call from a DID provider to my NATted Asterisk box.  I'm testing this by dialling my DID with Skype, since I can't dial it from my mobile phone (as it's an iNum).  I specified the public IP to Asterisk using "externhost" but also tried "externip", and it didn't help.  I can receive calls directly over SIP that don't use my DID.  The phone rings, but the call won't complete, and the error I get is:

Retransmission timeout reached on transmission MDVkZWU1YzcxNTBhNzU0OTZhNDJjODMxMGM4ZTBmMmI. for seqno 2 (Critical Response) -- See https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions
Packet timed out after 32000ms with no response

Here is what I get when I turn on SIP debugging (the Asterisk box's private IP is shown as 192.168.15.200, its external IP is shown as 60.70.80.90, the handset that Asterisk rings is shown as 192.168.15.122, the other IPs are presumably from the DID provider and/or Skype):

<--- SIP read from UDP:212.8.163.67:5061 --->
INVITE sip:883510001288388 at servalan.malcolm.id.au SIP/2.0
Record-Route: <sip:212.8.163.67:5061;r2=on;lr;ftag=5ba33723>
Record-Route: <sip:192.168.34.151:5061;r2=on;lr;ftag=5ba33723>
Via: SIP/2.0/UDP 212.8.163.67:5061;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-
Via: SIP/2.0/UDP 192.168.34.202:16000;received=192.168.34.202;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-;rport=16000
Max-Forwards: 70
Contact: <sip:0000123456 at 192.168.34.202:16000>
To: <sip:883510001288388 at 60.70.80.90:5060>
From: "skypeusername"<sip:0000123456 at 192.168.34.202>;tag=5ba33723
Call-ID: MzJiYmI0M2RmNThmNWM2NDk3OWY0OGVmNjFkNTJkNGI.
CSeq: 2 INVITE
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE
Content-Type: application/sdp
User-Agent: SipGW 8
Privacy: id
P-Asserted-Identity: "skypeusername"<sip:0000123456 at 192.168.34.202>
Remote-Party-ID: "skypeusername"<sip:0000123456 at 192.168.34.202>;party=calling;screen=yes;privacy=full
Content-Length: 463

v=0
o=0000123456 1338117946 1338117946 IN IP4 213.19.129.6
s=Skype call
c=IN IP4 213.19.129.6
t=0 0
m=audio 35336 RTP/AVP 18 0 8 104 102 103 117 116 124 101
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:104 SILK_WB_V3/16000
a=rtpmap:102 SILK_MB_V3/12000
a=rtpmap:103 SILK_NB_V3/8000
a=rtpmap:117 NWC/16000
a=rtpmap:116 UNCODEDWB/16000
a=rtpmap:124 UNCODEDSWB/24000
a=rtpmap:101 telephone-event/8000
<------------->
--- (18 headers 17 lines) ---
Sending to 212.8.163.67:5061 (NAT)
Using INVITE request as basis request - MzJiYmI0M2RmNThmNWM2NDk3OWY0OGVmNjFkNTJkNGI.
No matching peer for '0000123456' from '212.8.163.67:5061'
Found RTP audio format 18
Found RTP audio format 0
Found RTP audio format 8
Found RTP audio format 104
Found RTP audio format 102
Found RTP audio format 103
Found RTP audio format 117
Found RTP audio format 116
Found RTP audio format 124
Found RTP audio format 101
Found audio description format G729 for ID 18
Found audio description format PCMU for ID 0
Found audio description format PCMA for ID 8
Found unknown media description format SILK_WB_V3 for ID 104
Found unknown media description format SILK_MB_V3 for ID 102
Found unknown media description format SILK_NB_V3 for ID 103
Found unknown media description format NWC for ID 117
Found unknown media description format UNCODEDWB for ID 116
Found unknown media description format UNCODEDSWB for ID 124
Found audio description format telephone-event for ID 101
Capabilities: us - 0x10c (ulaw|alaw|g729), peer - audio=0x10c (ulaw|alaw|g729)/video=0x0 (nothing)/text=0x0 (nothing), combined - 0x10c (ulaw|alaw|g729)
Non-codec capabilities (dtmf): us - 0x1 (telephone-event|), peer - 0x1 (telephone-event|), combined - 0x1 (telephone-event|)
Peer audio RTP is at port 213.19.129.6:35336
Looking for 883510001288388 in default (domain servalan.malcolm.id.au)
list_route: hop: <sip:212.8.163.67:5061;r2=on;lr;ftag=5ba33723>
list_route: hop: <sip:192.168.34.151:5061;r2=on;lr;ftag=5ba33723>

<--- Transmitting (NAT) to 212.8.163.67:5061 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 212.8.163.67:5061;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-;received=212.8.163.67;rport=5061
Via: SIP/2.0/UDP 192.168.34.202:16000;received=192.168.34.202;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-;rport=16000
Record-Route: <sip:212.8.163.67:5061;r2=on;lr;ftag=5ba33723>
Record-Route: <sip:192.168.34.151:5061;r2=on;lr;ftag=5ba33723>
From: "skypeusername"<sip:0000123456 at 192.168.34.202>;tag=5ba33723
To: <sip:883510001288388 at 60.70.80.90:5060>
Call-ID: MzJiYmI0M2RmNThmNWM2NDk3OWY0OGVmNjFkNTJkNGI.
CSeq: 2 INVITE
Server: Asterisk PBX 1.8.11.1~dfsg-1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: <sip:883510001288388 at 118.107.224.38:5060>
Content-Length: 0


<------------>
Audio is at 10226
Adding codec 0x4 (ulaw) to SDP
Adding codec 0x8 (alaw) to SDP
Adding non-codec 0x1 (telephone-event) to SDP
Reliably Transmitting (NAT) to 192.168.15.122:5060:
INVITE sip:asteriskuser at 192.168.15.122:5060;transport=udp SIP/2.0
Via: SIP/2.0/UDP 192.168.15.200:5060;branch=z9hG4bK790bbf2d;rport
Max-Forwards: 70
From: "skypeusername" <sip:0000123456 at 192.168.15.200>;tag=as7dd03556
To: <sip:asteriskuser at 192.168.15.122:5060;transport=udp>
Contact: <sip:0000123456 at 192.168.15.200:5060>
Call-ID: 7b11ceb203c45a3b7787a93d6350a450 at 192.168.15.200:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX 1.8.11.1~dfsg-1
Date: Sun, 27 May 2012 11:22:18 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Content-Type: application/sdp
Content-Length: 272

v=0
o=root 1143664880 1143664880 IN IP4 192.168.15.200
s=Asterisk PBX 1.8.11.1~dfsg-1
c=IN IP4 192.168.15.200
t=0 0
m=audio 10226 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=sendrecv

---
Really destroying SIP dialog '1dbc4dd3009eba6a4bc7572400dbd7bc@[2001:470:35:20d::2]:5060' Method: INVITE
[May 27 19:22:18] WARNING[6455]: app_dial.c:2218 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown)
Really destroying SIP dialog '55fb002b4f6c6fe245f6a5aa049d63dc@[2001:470:35:20d::2]:5060' Method: INVITE
[May 27 19:22:18] WARNING[6455]: app_dial.c:2218 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Unknown)

<--- SIP read from UDP:192.168.15.122:5060 --->
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.15.200:5060;branch=z9hG4bK790bbf2d;rport
From: "skypeusername" <sip:0000123456 at 192.168.15.200>;tag=as7dd03556
To: <sip:asteriskuser at 192.168.15.122:5060;transport=udp>;tag=1417376788
Call-ID: 7b11ceb203c45a3b7787a93d6350a450 at 192.168.15.200:5060
CSeq: 102 INVITE
Server: Cisco-CP7905/1.01-030807A
Allow: ACK, BYE, CANCEL, INVITE, NOTIFY, OPTIONS, REFER, REGISTER
Content-Length: 0

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

<--- SIP read from UDP:192.168.15.122:5060 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 192.168.15.200:5060;branch=z9hG4bK790bbf2d;rport
From: "skypeusername" <sip:0000123456 at 192.168.15.200>;tag=as7dd03556
To: <sip:asteriskuser at 192.168.15.122:5060;transport=udp>;tag=1417376788
Call-ID: 7b11ceb203c45a3b7787a93d6350a450 at 192.168.15.200:5060
CSeq: 102 INVITE
Server: Cisco-CP7905/1.01-030807A
Allow: ACK, BYE, CANCEL, INVITE, NOTIFY, OPTIONS, REFER, REGISTER
Content-Length: 0

<------------->
--- (9 headers 0 lines) ---
list_route: no route

<--- Transmitting (NAT) to 212.8.163.67:5061 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 212.8.163.67:5061;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-;received=212.8.163.67;rport=5061
Via: SIP/2.0/UDP 192.168.34.202:16000;received=192.168.34.202;branch=z9hG4bK-d8754z-b37c8438ea03411d-1---d8754z-;rport=16000
Record-Route: <sip:212.8.163.67:5061;r2=on;lr;ftag=5ba33723>
Record-Route: <sip:192.168.34.151:5061;r2=on;lr;ftag=5ba33723>
From: "skypeusername"<sip:0000123456 at 192.168.34.202>;tag=5ba33723
To: <sip:883510001288388 at 60.70.80.90:5060>;tag=as5be8cd91
Call-ID: MzJiYmI0M2RmNThmNWM2NDk3OWY0OGVmNjFkNTJkNGI.
CSeq: 2 INVITE
Server: Asterisk PBX 1.8.11.1~dfsg-1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH
Supported: replaces, timer
Contact: <sip:883510001288388 at 118.107.224.38:5060>
Content-Length: 0

I'm assuming it probably doesn't make any difference, but in case it does, the DID provider is not establishing the call directly to my Asterisk box.  It's establishing it to an OpenSIPS box with a permanent public IP, which is performing a 302 redirect to send it to the Asterisk box (which has a static IP only).  After that though, the OpenSIPS box should be out of the picture.

Any tips on debugging this gratefully appreciated!

--
Jeremy Malcolm PhD LLB (Hons) B Com
Internet and Open Source lawyer, consumer advocate and geek
host -t NAPTR 5.9.8.5.2.8.2.2.1.0.6.e164.org|awk -F! '{print $3}






More information about the asterisk-users mailing list