PJSIP Trunk Setup

Late to the party here, but we want to move to PJSIP for our trunks. We have been unsuccessful thus far. Our current infrastructure is that FreePBX is trunked to our Avaya Session Manager via ChanSIP with the following configuration:


Can anyone help with how to translate the above peer trunk to a PJSIP friendly format? Thanks in advance for any insights!

Registration: None, Authentication: None, SIP Server: SessionManagerIPAddress, Context: from-pstn-e164-us, Qualify Frequency: 30

If no luck, at the Asterisk command prompt type
pjsip set logger on
make a failing call, paste the Asterisk log for the call at pastebin.freepbx.org and post the link here. If both incoming and outgoing calls fail, paste one of each.

1 Like

Since you’re not using registration, it’s important that you config the provider portal to send calls to whatever port pjsip is bound to. You obviously also have to config any nat/firewall devices to forward this traffic.

1 Like

How do you set the port pjsip is bound to ?
Can CHAN_SIP and PJSIP both use 5060?

Asterisk SIP Settings → chan_pjsip tab → Port to Listen On

Only if they are on different NICs or different protocols (e.g. one UDP, the other TCP).

For Chan_SIP, I have:
Use Enable TCP = Yes

For PJSIP, I have:
udp - - All Yes
udp - x,x,x,x - eth0 Yes
tcp - - All No
tcp - x.x.x.x - eth0 No

5060 is assigned to Chan_SIP
Won’t let me assign 5060 to PJSIP

I see my SIP Server port selection in the Connectivity → Trunks section. Within the specific trunk, under the pjsip settings is the SIP Server port field.

Edit: Are you changing the port for a trunk or the extensions?

to change pjsip to 5060 you need to change Chan_SIP to something else… change Chan_SIP to 5062, then PJSIP to 5060, then Chan_SIP to 5061?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.