So I have the following setup…
Router, GoIP4 GSM Gateway which is my trunk, server computer running FreePBX in a VMWare Workstation setting.
GoIP4 gateway communicates with the FreePBX fine but I have no audio.
I am using chan_sip with port 8560 because I could not use port forwarding for 5060 on my router.
I have port 8560 forwarded to the FreePBX server as well as 10000-20000 for RTP. I have a connection, I dial fine from my softphone app on my phone, it gets to the GSM gateway but I have no audio. Also, for outgoing calls, the call hangs up automatically after 10-11 seconds.
Can someone help me out?
Assuming that your VM is using bridged networking (it should) and that the VMWare host, the GoIP4 and the softphone are on the same LAN subnet, calls should not be going over the internet at all and your router should not be involved. (You may still want port forwarding to accommodate external extensions and/or SIP trunks.)
In Asterisk SIP Settings, confirm that Local Networks and External Address are correctly set. If you change these, after Submit and Apply Config you must restart Asterisk.
If no luck, find the simplest thing that fails. Does *43 (echo test) work? If so, set up a second extension e.g. a softphone on the VMWare host and confirm that calls between extensions work properly. If so but calls via the GoIP4 still fail, at the Asterisk command prompt type
sip set debug on
make a failing call, paste the Asterisk log for the call at pastebin.freepbx.org and post the link here.
Thanks for the reply. So, yes, the VM is using bridged networking and there is no issue with the communication between the VM with FreePBX and the GoIP4. I can connect to the FreePBX from my softphone app on my iPhone while on 4G and I try making a call, I see that the call is going through on the GoIP4, same thing with incoming calls. Now, it did work a couple of days ago, I received a call and it was fine but then it stopped again. Not sure why, have not been able to get the outgoing calls working at all though, no audio and it drops after 10-11 seconds.
In the Asterisk SIP settings, under the external network, I have the DDNS address of FreePBX, XXXXXX.deployments.pbxact.com. Under local networks, I have the address 192.168.100.0/24. My router’s IP is 192.168.100.1. I have nothing else here. Is this correct?
By the way, just want to let you know I had this same FreePBX configuration working before for a long time on an install on Amazon AWS but I had to have my GoIP4 connect to it through a separate router with a VPN set up to connect to the FreePBX VPN so that is why I wanted to do it locally now. Configuration is the same except the addresses etc. so not sure where I am going wrong here.
I tried the *43 echo test, it did not work. Call ends immediately.
Here is the log:
Here is another log:
Sorry, it took a while till I masked all the IPs and other private details.
There are no calls in either log. Make a test call to *43 and post what gets added to the log as a result. If nothing, perhaps there is a useful error message from the softphone.
Or, try something simpler such as with the iPhone on Wi-Fi connecting directly to the PBX. Or, try a softphone on the VMWare host or on another PC on your LAN.
Sorry about that, I think I didn’t copy enoiugh upwards because of the auto scroll.
Check this one please:
The original INVITE is still not present, but I’ll try with what you posted.
32563 <--- Reliably Transmitting (NAT) to 188.8.131.52:8272 --->
32564 SIP/2.0 200 OK
32565 Via: SIP/2.0/UDP 192.168.5.26:8272;branch=z9hG4bKP7wPxB7RFZ4OUtcN;received=184.108.40.206;rport=8272
Bizarre – INVITE apparently received from 220.127.116.11 (US) but reply sent to 18.104.22.168 (Armenia)
32581 c=IN IP4 192.168.100.19
It should be showing your public address. In Asterisk SIP settings, confirm that External Address and Local Networks are correctly set. Also on the NAT settings on the chan_sip tab. If at all possible, use pjsip, because chan_sip has a lot of quirks with regard to NAT.
Ok so here is my settings in Asterisk SIP
Is this correct how they are set up? the 192.168.100.19 is my FreePBX IP.
Not sure how to set up pjsip.
Possibly a DNS issue. Test by putting your current numeric public IP address in External Address and setting up IP Configuration as Static IP. After Submit and Apply Config, you must restart Asterisk (or the whole server). If no luck, paste a new log (including the initial INVITE).
I will try that now.
This is what I have under DNS in System Admin. Is it correct?
Even more bizarre is that the first re-transmission swaps over the discrepancy, and subsequent ones settle on 38…, for both. Either there is a machine fault somewhere, or there has been a faulty attempt at redaction.
So that worked. I changed the External IP Address in General SIP settings to my IP address and then in chan_sip same thing and set it to Static IP. The call did not hang up and I had audio.
Here is the log:
Can you let me know if it looks good?
Also, I do not have a static IP from my ISP which is why I am using DDNS on my FreePBX. With it setup the way it is now, will it work when my IP changes?