[asterisk-dev] SIP Registration with short Expire fails systematically
Timo Teräs
timo.teras at iki.fi
Tue Oct 12 03:47:26 CDT 2010
On 10/12/2010 11:22 AM, Olle E. Johansson wrote:
> 12 okt 2010 kl. 09.35 skrev Timo Teräs:
>> Now what happens at this point is that Asterisk fails to re-register
>> after the first 20 second Expire has been received. I have debug logs
>> from it.
>>
>> My guess is that the following happens:
>> 1. Asterisk register succesfully, 20s Expiry -> reregister in 15s
>> 2. When reregister triggers:
>> - sip_registry->call is NULL, because of successful registration
>> - transmit_register builds new sip_pvt with same call ID as #1
>> 3. Server replies
>> 4. Asterisk rejects registration reply because:
>> - the sip_pvt from #1 has not been yet destroyed
>>
> Please file a bug report in the issue tracker :-)
>
> I think it clearly has to do with the t1 timer for #1. It propaply hangs around for more than 20 secs. We should set max
> T1 for registry transactions to be the expiry time minus some small unit.
Filed as:
https://issues.asterisk.org/view.php?id=18119
sip_scheddestroy() probably needs then additional "clip ms" parameter.
Since we likely want to do "ms = min(p->timer_t1 * 64, expires_ms)".
Or should we just use expired_ms (minus some safety) as the timeout
always? Then we could get away by just changing the sip_scheddestroy()
call in handle_response_register().
- Timo
More information about the asterisk-dev
mailing list