Tony Mountifield
2013-Nov-08 15:39 UTC
[asterisk-users] 11.5.0 - SIP registration not retrying after failures
I had a SIP problem on an 11.5.0 system that I look after. It registers with a SIP trunk provider, and at one point the provider had an issue that caused registration to fail. The problem was that Asterisk did not keep retrying, and it was not until it was restarted that registration was re-established. Here are the entries in the full log: [Nov 5 21:19:12] NOTICE[3248] chan_sip.c: -- Registration for 'username at nn.nn.nnn.nn' timed out, trying again (Attempt #1) [Nov 5 21:19:32] NOTICE[3248] chan_sip.c: -- Registration for 'username at nn.nn.nnn.nn' timed out, trying again (Attempt #1) [Nov 5 21:19:52] NOTICE[3248] chan_sip.c: -- Registration for 'username at nn.nn.nnn.nn' timed out, trying again (Attempt #1) [Nov 5 21:19:56] WARNING[3248] chan_sip.c: Forbidden - wrong password on authentication for REGISTER for 'username' to 'nn.nn.nnn.nn' The output of "sip show registry" was as follows: CLI> sip show registry Host dnsmgr Username Refresh State Reg.Time nn.nn.nnn.nn:5060 N username 23 No Authentication Tue, 05 Nov 2013 21:18:28 1 SIP registrations. There was evidently a temporary authentication problem at the provider. Does a Forbidden response cause Asterisk to decide never to retry? Even if it is a rare situation, is it possible to configure Asterisk to recover from it automatically by retrying? I checked sip.conf, and registerattempts was left unset (defaults to 0=forever). I couldn't see any other relevant settings. Cheers Tony -- Tony Mountifield Work: tony at softins.co.uk - http://www.softins.co.uk Play: tony at mountifield.org - http://tony.mountifield.org
Michael L. Young
2013-Nov-08 15:52 UTC
[asterisk-users] 11.5.0 - SIP registration not retrying after failures
> From: "Tony Mountifield" <tony at softins.co.uk> > To: asterisk-users at lists.digium.com > Sent: Friday, November 8, 2013 10:39:25 AM > Subject: [asterisk-users] 11.5.0 - SIP registration not retrying after failures > > I had a SIP problem on an 11.5.0 system that I look after. It > registers > with a SIP trunk provider, and at one point the provider had an issue > that > caused registration to fail. > > The problem was that Asterisk did not keep retrying, and it was not > until > it was restarted that registration was re-established.A fix for this was actually just committed and will be in 11.7. There is a release candidate available if you want to try it out. You want to look for the "register_retry_403" option that was added to the sip.conf file. Michael