On a fresh install of FreePBX the port configuration is
chansip 5160 / 5161
pjsip 5060 / 5061
If you leave it like that, and then log into the ATA device, leave the ATAs LOCAL sip port field set to 5060 and set it to register to xyz@IP:5160
It should then register as a chan_sip device, atleast both my HT802 and PAP2T work like this.
After changing those settings, you may have to actually power cycle the ATA devices, before they will behave with the new settings. Its either that or make sure the old connections completely expire so they will attempt to re-register, otherwise the stale connection to the old port hangs on and things dont work.
PJsip and chan_sip cannot both have 5060 AND have udp enabled, its the reason chan_sip was moved to 5160/5161 (the port is bound, atleast that was my understanding of bound ports, once you bind a port only one thing is using it.)
You didnāt restart Asterisk after changing the PJSIP ports. Disabling UDP had no effect apart from telling you to restart asterisk - which you did - which solved the problem 8)
The better solution is just to leave pjsip on 5060 and chansip on 5160.
Is this working still? It seems I am unable to resolve the IP for obihai.sip.google.com. On some of my workstations it is cached but on others it is gone, reporting: server canāt find obihai.sip.google.com: NXDOMAIN with nslookup. Even pointing nslookup to use cloudflare or google dns servers doesnāt work.
Using Dig: On FreePBX server:
; <<>> DiG 9.11.3-1ubuntu1.1-Ubuntu <<>> obihai.sip.google.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 33468
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 65494
;; QUESTION SECTION:
;obihai.sip.google.com. IN A
EDIT:
Ok, I replaced the nameserver 127.0.0.53 with my routerās IP in /etc/resolv.conf and it seems to now resolve. It is weird because other domains would resolve and this one would not, not even once. I have no clue as I havenāt seen this before.
That is exactly how my dig info looks on my Freepbx box as well, and yet my google voice phone still works. I suspect its some sort of DNS cache built into the newer Ubuntu, and so DIG is not reporting correctly, your āother workstationā that shows the dig info, also shows an older version of DIG.
Just wanted to chime in letting you know that mine looks exactly like yours, and the phone still works
If you are having any trouble with your phone, did your Public IP address change? I have not tested this in an environment where the connection has a dynamic IP. Our ISP only changes our IP if the home routerās mac address changes, or if they are replacing hardware at the ISP which has only happened once in the last 8 years
I prefer to stick with the change I made as I had expected FreePBX to use the DNS from my router and which it got from DHCP. Not sure what 18.04 is doing but it seems to have put in a local dns server to cache perhaps. Everything works now. Before I was able to get incoming but not do outgoing but now it all seems to work with using the routerās IP as the dns server.
Hello,
This is my first post.
I get an error on this step:
sudo chown asterisk:asterisk /var/run/asterisk
chown: cannot access ā/var/run/asteriskā: no such file or directory.
I checked and ā/var/runā directories are there but no āasteriskā
that file will only exist if asterisk is running (or was but crashed) it will always be owned by the user that started asterusk, if it isnāt asterisk, then you need to fix that, asterisk/freepbx requires that asterisk runs as asterisk:asterisk
the directory is generally always there, its a linux thing, any file in that directory will usually contain the pid ( process identification as reflected by ps -aux ) of the process that shares that name, and there might be more than one pid in it (not a good thing for asterisk though) the ownership of the file will reflect who initiated thay process and changing its ownership will NOT change that fact (wrong rabbit hole )
Do you know offhand which step makes the asterisk file (or directory) in /var/run/. Then Iāll check if I messed up.
Update: I continued on as suggested and after the āā¦ asterisk stopā command I checked if the /var/run/asterisk file existed. It did so I then ran the āchown asterisk:asterisk /var/run/asteriskā with success.
you miss the point of that files existance, if you think you stopped asterisk and it is still there, you didnt, it crashed , changing its ownership is a red herring hiding in a rabbit hole.
Iām in the freepbx screen trying to load the Superfecta and Phonebook and it whoops soon after I click on āconfirmā. I tried two computers on the same LAN.
I can see on the left No such file or directory, which means the file maybe did not download, which would likely only happen if you have incorrect file/directory permissions.
Now that you have had some practice, I would stick the ubuntu thumb drive in again, format, and start over. If you follow the guide carefully those errors should not happen, I just setup a system for a friend only a couple days ago.
If the intent of the above two lines in pjsip_custom_post.conf is that they be added to the existing FreePBX generated global section, then I recommend it be changed to:
[global](+)
; debug=true ; uncomment for debug
keep_alive_interval=90
Both will work, but this has a greater likelihood of surviving any future reorganization of the include files. Confirm the settings stick with āpjsip show settingsā after a reload.