FreePBX – Migration Towards PJSIP

Mohit Mishra

Mohit Mishra

Going back several versions, FreePBX has had options to configure SIP with either Asterisk’s chan_sip or chan_pjsip.

As mentioned in the blog post here, chan_sip is already deprecated in the Asterisk world, so it’s past time to start thinking about “Migration towards PJSIP” within FreePBX.

The FreePBX engineering team has been working in this direction to improve the functionality in various components in FreePBX, both in open-source modules and in commercial modules, our goal is to make FreePBX a much easier, user-friendly supporter of PJSIP.

Please see the following list of some of the key developments happening in the “Migration to PJSIP” direction:

Conversion Tool

Just capturing this point here to remind (for those who don’t know yet) , that we have an extension conversion tool available in FreePBX to convert all your chan_sip extensions to pjsip smoothly.

Please refer to our previous blog to find out more details. 

We have been fixing issues in this area to make sure we are preserving common configuration (chan_sip settings which will be applicable to chan_pjsip) during the conversion process.

Endpoint Manager Improvement – To auto-reboot / reprovision the phone

Anyone who has needed to convert a chan_sip extension to a PJSIP extension has probably learned (possibly the hard way) that it works best when you power down the phone, do the extension conversion, rebuild provisioning files, and then power up the phone again with the expectation that the device successfully re-provisions on boot with the new registration parameters. 

The real problem comes when there is no physical access to the endpoint;  common when you’re trying to make changes remotely during off-hours. In this situation, I’ve had limited success by triggering a reboot of the phone, doing the extension conversion, and rebuild of the provisioning files while the phone boots, and hope all is in place in time for the phone as it re-provisions. If your timing is off, you’re stuck with an unregistered device that you now have to touch to get working again.

Starting in Endpoint Manager versions 14.0.56 or, when you do a chan_sip to PJSIP conversion of an extension, and if the extension has an EPM extension mapping, a SIP NOTIFY is sent to the phone immediately prior to the conversion and config rebuild. FreePBX handles that step for you. If you’re doing a bulk conversion of extensions, you can do it safely knowing that the device gets rebooted when it’s needed to force a re-provision.

Endpoint Manager improvement –  Changing max contact to 1..n or n..1

PJSIP extensions are displayed in EPM Extension Mapping as <extension-x> where x is max contact in “endpoint manager ->extension mapping”. Now going forward, this will be valid even if you have max contact of 1 which means the endpoint will display the extension as <x-1>.

We have improved the Endpoint Manager module to handle changing the max contact value of a PJSIP extension from 1 to n or n to 1 and will not affect the existing configuration of that PJSIP extension in the endpoint manager.


Endpoint Manager Improvement – Extension Mapping – Show AOR button  

We have seen a few requests from the community and on our issue tracker about PJSIP endpoints not showing ip addresses properly in the extension mapping page.

Basically, there is no way to determine which EPM SIP account is mapped to which PJSIP contact. Hence we have added the “SHOW AOR” button in the extension mapping page, which will display a list of all AORs associated with that PJSIP endpoint.

PJSIP endpoints use ‘aor’ as a replacement for peer/user/account for chan sip. AOR is the address that resolves into destinations – or your registered phones. 

PBXact Wizard – By default, it now will create PJSIP extensions


We have also improved the PBXact setup wizard, previously by default we were creating chan_sip extensions but now we will create chan_pjsip extensions instead.



All are encouraged to provide feedback by either raising issues on the open-source bug tracking system for open source modules or open a commercial support ticket for commercial modules or submit feature requests or improvements.

Thank you for using FreePBX,

Mohit Mishra

Share this Blogpost

Start the Discussion

Sign up for our Newsletter

Scroll to Top