FreePBX looses connection with Trunk

Hey guys, i am currently updating a clients FreePBX software to the latest stable version. However after about forty minutes to an hour FreePBX will loose the connection. All calls incoming will get routed to his cell phone (set up through trunk service in case of VOIP failure) all out going calls will get the message that all circuits are busy now. I have added the Freepbx box to the routers dmz and forwarded ports 5060-5065. I have tried to copy every setting the same as his older freePBX setup is over ten years old. Researching i read that i may need to change the sip connection setting to insecure=port,invite as it is set to insecure=very. Beyond this i cant think of or find anything that different in the system. I have noticed that if the connection loss occurs i can regain connection by either rebooting the server or by selecting submit from the web GUI and apply config on any page. Im not sure why the later one works though. I AM NOT VERY FAMILIAR CONFIGURING FreePBX, i have copied a part of the log file below please let me know if you need anything additional and if so how to generate it. I printed out the below logfile and took it home just for research its a lot to key in so today i will stop by the office and get a softcopy of it to add below.

[2012-06-20 21:52:27] WARNING[3351] chan_sip.c: Retransmission timeout reached on transission [email protected]:5060 for seqno 102
((Critical Request)) – See
https://wiki.asterisk.org/wiki/xxxxxxxxx

The Freepbx system has a static IP as well as the cable modem.

Do you have a firewall between the FreePBX and the cable modem? Looks like your NAT translation is timing out.

Yes on the modem but i placed it behind the DMZ. I have a feeling it might be connecting to a Windows Server 2003 machine for dns. Could this explain the issue?

No

Not at all, the DMZ is still a NAT process.

I rechecked the settings i did not have a gateway specified. I changed it to the routers IP to make sure the connection was going to the right place. That Windows server 2003 handles IP assignments and is a gateway for the office computers. I will try the new configuration tomorrow to see if that works. Im hoping this will resolve this issue, this will be my first FreePBX configuration so far I like the software. **
Should the phones also be connecting to the gateway of the router? In the current and old configuration they connect to the 2003 server which has an ip of 192.168.0.7 but the routers is the standard of 192.168.0.1 could this be also causing the issue?

If the phones are on the same LAN as the phone server they don’t need a gateway at all.

I double checked the setting, i ensured the dns had 127.0.0.1 listed. Made sure i had the correct gateway address set, and changed the insecure=very to insecure=port,invite. The system has been up for three days now. :slight_smile: