[Resolved] Suddenly all sip trunks and sip/sccp phones lost connectivity

Found my problem fairly quickly, but thought I’d post for others who may end up in the same situation:

Suddenly all my Sip trunks and phones lost connectivity (I get a txt msg to my phone from munin monitoring my sip peers… :slight_smile: ) and I wondered what happened!!
So, I started troubleshooting, and googlin…

I tried asterisk -rv, and sip show peers, and got an error that SIP wasn’t there, and Freepbx was getting errors trying to reload config’s! What??

So, I amportal Killed, and restarted, and Nuttin, nada

Looked in command line “show modules like sip”, and chan_sip was there, tried unload/load’ing it, and that worked just fine

Compared recent backup to current configs, they were all idential (diff’s), checked mysql, it looked fine.

Rebooted machine, nuthin, still doesn’t work
Checked for rootkits, nuthing (expected, the box is pretty darned secure)

Tried a manual nslookup, Failed
VOILA!

–Log tracing would have led me to: acl.c: Unable to lookup ‘outbound1.vitelity.net’ (didn’t see this till after I found the problem though)–

I was using 4.2.2.2 as the DNS server, and there is apparently something wrong there today

The problem was a DNS server issue. I changed my DNS server, killed and started asterisk, everything came up perfectly as expected

SOOO… for those of you troubleshooting something that just randomly breaks on a server, when NOTHING was changed on your end, do not forget to check your DNS server (by manually running nslookups, etc) or possibly change your DNS server, just to be sure that isn’t the problem

Enjoy!

This is a known issue that has plagued Asterisk since the early days. What I do is install BIND on the phone server and set the cache to expire in a week. Then I change resolv.conf to have the first line:

nameserver 127.0.0.1

When you set up BIND, list at least 2 upstream DNS servers for exterior lookups. When Asterisk/SIP looses DNS, it goes bonkers. It will work ok if can resolve names so the one week cache provides that for a while.