Phones fail to make or receive calls

I am having a strange issue that I am not sure how to resolve. I have 4 phones (gxp1405) and every couple of weeks some of them sometimes 3 sometimes one, but so far not all 4, will stop making or receiving calls. If I power cycle to phones they go back to working normally for a while. It is never the exact same phones that have to problem. One time it might be the phones up front and in back, the next time it might be the one in my office and no others, still another time it might be the two other phones plus the one in my office, or the one up front, or any possible combination, there is no pattern that I can see. Has anyone else had this problem and how does one fix it?

FreePBX 13.0.190.19
PBX Firmware: 10.13.66-2
PBX Service Pack: 1.0.0.0

Logs - specifically /var/log/asterisk/full

Look for the extensions and see why they are unregistering.

Check your integrated firewall and make sure they aren’t triggering the fail2ban and make sure your local network is in the trusted zone.

I’m not sure what I’m looking for, but I did see the following about 5 times a second every second.

[2017-03-17 09:00:21] NOTICE[27582] chan_sip.c: Registration from ‘“EXT#” sip:ext#@myipaddress’ failed for ‘109.236.88.19:7138’ - Wrong password

when I looked fail2ban is running and is not blocking any ip’s. so I went in and manually blocked that ip with iptables and a couple others that were doing the same thing. Could it be that all that traffic was just knocking the phones off?

You have to make sure you are using the right sip protocol and the right ports on the phone. ex chan_ship uses 5060 and pjsip uses 5061. I came into this not too long ago, when I put my installation on a raspberry pi. Now a days newer phones should be using chan_sip if I am not mistaken.

Make sure that in advanced SIP settings on FPBX you have “allow anonymous SIP calls” set to OFF and on the Chan SIP tab of same area, make sure “Allow SIP Guests” set to OFF. Looks like you may be getting unwanted invites.