SIP registration drops almost daily and fails to reconnect (Distro 2.11)

Hi,

I’m seeing a weird problem with our FreePBX Distro 2.11 system and I can’t seem to get enough information to pin down the cause.

Can anyone help me with some clues about this, or perhaps suggest how to get additional debug info when it happens, please?

We have two SIP providers, VOIPfone and SIPgate. Each is set up for both inbound and outbound calls, although SIPgate is used mainly inbound to a simple IVR.

Several times last week, the system lost its connection to both providers, some time between the last call made and the early hours of the morning. It then tried to re-register with both providers repeatedly but never succeeded. Eventually, I spotted the problem in the morning and restarted things.

VOIPfone re-registers as soon as I tell Asterisk to “sip reload”. SIPgate doesn’t - that requires a reboot of the whole machine, not even “core restart” fixes it!

Both providers’ SIP hosts are set up in my local router’s DNS to avoid the known problems with Asterisk dropping SIP extensions in the event that the internet connection drops. SIP & RTP traffic coming in from either provider is forwarded by the router to the PBX system.

I also tried, yesterday, disabling the SIPgate trunk to see whether that provider was causing both to fail. Seems not - still failed overnight and didn’t re-register with VOIPfone until I reloaded SIP this morning.

Excerpts from the logs over the last couple of days and the VOIPfone trunk definition below.

Any help appreciated!

Thanks,

Jeff


May 20th
[2013-05-20 03:15:58] NOTICE[1662] chan_sip.c: – Registration for ‘1685***@sipgate.co.uk’ timed out, trying again (Attempt #5856)
[2013-05-20 03:15:58] NOTICE[1662] chan_sip.c: – Registration for ‘1685***@sipgate.co.uk’ timed out, trying again (Attempt #5856)
[2013-05-20 03:16:01] VERBOSE[1605] asterisk.c: – Remote UNIX connection


May 21st
[2013-05-20 14:42:33] VERBOSE[3523][C-00000002] app_macro.c: == Spawn extension (macro-dialout-trunk, s, 22) exited non-zero on ‘SIP/405-00000008’ in macro ‘dialout-trunk’
[2013-05-20 14:42:33] VERBOSE[3523][C-00000002] pbx.c: == Spawn extension (from-internal, 0800365100, 5) exited non-zero on ‘SIP/405-00000008’
[2013-05-20 14:42:33] VERBOSE[3523][C-00000002] pbx.c: == Spawn extension (from-internal, 0800365100, 5) exited non-zero on ‘SIP/405-00000008’
… registration failed, attempts 1-16
[2013-05-21 00:58:10] NOTICE[1663] chan_sip.c: – Registration for ‘30160***@sip.voipfone.net’ timed out, trying again (Attempt #17)
[2013-05-21 00:58:10] NOTICE[1663] chan_sip.c: – Registration for ‘30160***@sip.voipfone.net’ timed out, trying again (Attempt #17)
[2013-05-21 00:58:10] WARNING[1663] chan_sip.c: Forbidden - wrong password on authentication for REGISTER for ‘30160***’ to ‘sip.voipfone.net
[2013-05-21 00:58:10] WARNING[1663] chan_sip.c: Forbidden - wrong password on authentication for REGISTER for ‘30160***’ to ‘sip.voipfone.net
[2013-05-21 03:41:01] VERBOSE[1608] asterisk.c: – Remote UNIX connection

The password is correct and re-registered first time when I reloaded SIP at 07:20.


VOIPFone trunk peer info:
type=friend
secret=******
username=30160***
fromuser=30160***
fromdomain=sip.voipfone.net
host=sip.voipfone.net
insecure=very
dtmfmode=rfc2833
deny=0.0.0.0/0.0.0.0
permit=195.189.173.27/255.255.255.255
allow=all