[Home]

Summary:ASTERISK-06640: Registration time out after few minutes
Reporter:tootai (tootai)Labels:
Date Opened:2006-03-28 11:59:08.000-0600Date Closed:2006-03-28 19:02:05.000-0600
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Channels/chan_sip/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:Just upgraded two servers to 1.2 branch Rev 15381. They where in 1.2.4 before. After launching asterisk, all sip registration are going smooth and after 2mn, I get Registration timeout on all registrations. If I restart them, same behaviour: it's ok for 2 mn and then timeout. It seems to be after first renewal that problem appears.
Comments:By: Russell Bryant (russell) 2006-03-28 13:23:45.000-0600

please update to the latest code in the 1.2 branch to verify that the problem has been fixed

By: tootai (tootai) 2006-03-28 14:49:19.000-0600

Updated to 1.2-15743, no changes, same timeout

By: hypherion (hypherion) 2006-03-28 16:54:52.000-0600

I have just noticed this issue myself (in Olle's test-this-branch from today actually). Looking at a packet dump, the first SIP Register is sent correctly to the remote port of the proxy.  Re-register packets are however sent at some random port number (ie 50451).  Here is an example with Vonage:

Retransmitting #2 (no NAT) to 216.115.20.41:50451:
REGISTER sip:sphone.vopr.vonage.net SIP/2.0
Via: SIP/2.0/UDP MyIP:5075;branch=z9hG4bK2ca6dd1f;rport
From: <sip:MyNumber@sphone.vopr.vonage.net>;tag=as3054bc52
To: <sip:MyNumber@sphone.vopr.vonage.net>
Call-ID: 116ae40774e9d1f93b7ad24a63186fc2@MyIP
CSeq: 104 REGISTER
User-Agent: Asterisk
Max-Forwards: 70
Authorization: Digest username="MyNumber", realm="216.115.20.41", algorithm=MD5, uri="sip:216.115.20.41", nonce="1767927681", response="27ceb6512f89591425e9fde601cc19a3", opaque=""
Expires: 120
Contact: <sip:ASTZVXW-4ff0572c4afb335e5649eb803b5a8793@MyIP:5075>
Event: registration
Content-Length: 0

There is no port 50451 anywhere in the configuration files or in any SIP packet received from Vonage.

By: Olle Johansson (oej) 2006-03-28 18:26:05.000-0600

I do not see this problem with current 1.2 and vonage... It keeps re-registering.

Any more information you can give me?

By: Olle Johansson (oej) 2006-03-28 18:26:21.000-0600

Please check "sip show registry" to see current port.

By: Olle Johansson (oej) 2006-03-28 18:28:50.000-0600

I need a full SIP debug, verbose 5, debug 5, the first registration and the following registrations that fail.

By: Luigi Rizzo (rizzo) 2006-03-28 18:41:42.000-0600

ok i see something here... in my case the port number is registered as 50195
which is 0xc413 ... and 5060 is 0x13c4 so it must be a missing htons()
somewhere, maybe just in the printed page.

Can soneone tell when the problem started ? someone said SVN14141 but that
change seems totally unrelated.

By: hypherion (hypherion) 2006-03-28 18:44:50.000-0600

Actually, the Vonage one was just an example. I have another register going to a different proxy and that has the same issue with another random port in the 50xxx range.

diesel*CLI> sip show registry
Host                            Username       Refresh State              
provider1:50195               my username       105 Request Sent        
provider2:50451               my username         15 Request Sent

By: Olle Johansson (oej) 2006-03-28 19:01:23.000-0600

Fixed in svn 1.2 15898 and svn trunk 15905.

By: Olle Johansson (oej) 2006-03-28 19:01:49.000-0600

Thanks Rizzo for the hint about htons