Ive had asterisk running on Ubuntu for a few years. It’s been set and forget. But in late December all my registration attempts suddenly started failing:
[Jan 11 12:52:10] NOTICE[2829] chan_sip.c: -- Registration for '09xxxxxx@sip01.mynetfone.com.au' timed out, trying again (Attempt #108)
This was about the same time my cable broadband provider gave me a new gateway modem. It’s easy to conclude the gateway is blocking registration/Sip requests or replies.
However, using wifi from my phone and a SIP application (csipsimple) I can both register and make calls. To me this means it cannot possibly be the gateway.
Its also tempting to conclude its the VOIP provider that is not responding to my requests. But I use two completely independent VOIP providers. Both (mynetphone and clickncall) now fail with registration timeout.
I therefore conclude it must be something to do with asterisk. However the last change I made to asterisk was a minor extension.conf change on 7th December. The system worked fine up to the 20th December.
I did finally realise the host IP address had changed with the installation of the new gateway. So I updated EXTERNADDRESS and HOST in sip.conf. This made no difference.
So in trying to diagnose the problem:
-
I can ping the sip urls of both providers from the machine I host asterisk on.
-
traceroute shows the requests leaving the gateway, reaching my ISP and for one provider reaching their servers, for the other the last 15 hops or so are all * * * (presumably showing the request is being sent.
-
tcpdump agrees the requests are going out. Whether they are valid or not is a different matter.
12:58:38.794201 IP (tos 0x0, ttl 64, id 53587, offset 0, flags [none], proto UDP (17), length 461)
192.168.4.80.5060 > 125.213.xxx.xx.5060: [bad udp cksum 0xe4e9 -> 0xc347!] SIP, length: 433
REGISTER sip:sip01.mynetfone.com.au SIP/2.0
Via: SIP/2.0/UDP 58.173.112.144:5060;branch=z9hG4bK66b69844;rport
Max-Forwards: 70
From: <sip:09466676@sip01.mynetfone.com.au>;tag=as262c4b53
To: <sip:09xxxxxx@sip01.mynetfone.com.au>
Call-ID: 5cbace9c294d43193dd2710b50939d78@127.0.0.1
CSeq: 228 REGISTER
User-Agent: Asterisk PBX 11.7.0~dfsg-1ubuntu1
Expires: 120
Contact: <sip:09xxxxxx@58.173.xxxxxxxx:5060>
Content-Length: 0
So Im a bit stumped. Each explanation I think of I can discount as follows:
- The responses are blocked by the gateway and never reach asterisk. But my VOIP app would fail if this were the case.
2.The VOIP provider has changed something. But for two different providers to do this at the same time is implausible. Again its unlikely my SIP app would still be OK and asterisk not.
- asterisk is suddenly sending invalid registration information. But the registration credentials have not changed in asterisk. For good measure I set up my VOIP app again with the credentials from asterisk and it works just fine (through the same gateway and internet connections).
Its almost as if Ive got a new asterisk installation and Ive messed up the config. Except the system is not new, and has been running fine since 2013. Obviously something has changed somewhere.
Does anyone have any plausible ideas, given the analysis I’ve done above?