PJSIP extensions unable to register after converting from chan_sip using Bulk Handler

Hello,

I am currently working to migrate our production server to a server that is running a newer firmware. I initially performed a mass import using Bulk Handler and got all migrated properly, all extensions were configured as chan_sip. I converted a few test extensions to PJSIP to hammer out all the kinks with the new driver. Got all my hard phones and soft phone clients working and registered on PJSIP. I then performed a Mass Edit using Bulk Handler of those extensions to convert them to PJSIP. The conversion looked successful, but now I am unable to register any extension, even with known good extensions I had no problems registering. I receive a Failed to Authenticate error on each registration attempt, be it hard or soft phone.

I have PJSIP as the default driver and ports configured properly for UDP (5060) and TLS (5061) while chan_sip is on UDP (5160) and TLS (5161). I have confirmed traffic is coming in on the correct port through tcpdumps and PJSIP traces. I have even tried to create a fresh PJSIP extension from the GUI, but experience the same Failed to Authenticate error. Would like to note that all extensions register without issue on chan_sip.

I’m wondering if anyone has experienced this same behavior as I hit a wall with trying to solve this. I have attached an Asterisk reload trail log and a PJSIP log when a registration is attempted from both hard and soft phones. I have de-identified sensitive information. Hoping to find a resolution for this.

FreePBX version: FreePBX 14.0.3.10
PBX Firmware: 12.7.5-1807-1.sng7
Operating System: Sangoma Linux release 7.5.1805 (Core)
Asterisk version: Asterisk 13.22.0
Soft Phone: Bria Stretto from Counterpath
Hard Phone: Grandstream GXP1450

Please let me know if anyone requires additional logs or information. Thank you.

Softphone Registration Attempt

[2018-08-01 13:49:32] NOTICE[16354]: res_pjsip/pjsip_distributor.c:649 log_failed_request: Request ‘REGISTER’ from ‘’ failed for ‘phoneIP:60002’ (callid: [email protected]) - Failed to authenticate

<— Received SIP request (567 bytes) from TLS:_:18974 —>
REGISTER sip:_SIP/2.0
Via: SIP/2.0/TLS _;branch=z9hG4bK-524287-1—66a8661dda8bd77d;rport
Max-Forwards: 70
Contact: <sip_address;rinstance=b7b95d33a5c027c0;transport=tls>
To: “Oscar Santos”<sip_address>
From: “Oscar Santos”<sip_address>;tag=38200b7e
Call-ID: 93186MzZkYTQyYWExMDJiZjllY2FjYmRkZDU2NDMwNjM3OWI
CSeq: 1 REGISTER
Expires: 3600
Allow: SUBSCRIBE, NOTIFY, INVITE, ACK, CANCEL, BYE, REFER, INFO, OPTIONS, MESSAGE
User-Agent: Bria Stretto release 5.3.4 stamp 93186
Content-Length: 0

<— Transmitting SIP response (564 bytes) to TLS:_:18974 —>
SIP/2.0 401 Unauthorized
Via: SIP/2.0/TLS ;rport=18974;received=;branch=z9hG4bK-524287-1—66a8661dda8bd77d
Call-ID: 93186MzZkYTQyYWExMDJiZjllY2FjYmRkZDU2NDMwNjM3OWI
From: “Oscar Santos” <sip_address>;tag=38200b7e
To: “Oscar Santos” <sip_address>;tag=z9hG4bK-524287-1—66a8661dda8bd77d
CSeq: 1 REGISTER
WWW-Authenticate: Digest realm=“asterisk”,nonce=“1533141792/e9438f21617d9ee07e3b67197b9cf324”,opaque=“40d3fc2f2171bbea”,algorithm=md5,qop=“auth”
Server: FPBX-14.0.3.10(13.22.0)
Content-Length: 0

<— Received SIP request (847 bytes) from TLS:_:18974 —>
REGISTER sip:_SIP/2.0
Via: SIP/2.0/TLS ;branch=z9hG4bK-524287-1—2939ec3cf926e87f;rport
Max-Forwards: 70
Contact: <sip_address;rinstance=b7b95d33a5c027c0;transport=tls>
To: “Oscar Santos”<sip_address>
From: “Oscar Santos”<sip_address>;tag=38200b7e
Call-ID: 93186MzZkYTQyYWExMDJiZjllY2FjYmRkZDU2NDMwNjM3OWI
CSeq: 2 REGISTER
Expires: 3600
Allow: SUBSCRIBE, NOTIFY, INVITE, ACK, CANCEL, BYE, REFER, INFO, OPTIONS, MESSAGE
User-Agent: Bria Stretto release 5.3.4 stamp 93186
Authorization: Digest username=“114”,realm=“asterisk”,nonce=“1533141792/e9438f21617d9ee07e3b67197b9cf324”,uri="sip:
",response=“83057d3c3a61ba2a5e4df1c9407e57d8”,cnonce=“d769d1ecb03c76d797aab5311373ae00”,nc=00000001,qop=auth,algorithm=md5,opaque=“40d3fc2f2171bbea”
Content-Length: 0

[2018-08-01 12:43:12] NOTICE[7123]: res_pjsip/pjsip_distributor.c:649 log_failed_request: Request ‘REGISTER’ from ‘“Oscar Santos” <sip_address>’ failed for ':18974’ (callid: 93186MzZkYTQyYWExMDJiZjllY2FjYmRkZDU2NDMwNjM3OWI) - Failed to authenticate
<— Transmitting SIP response (564 bytes) to TLS:
:18974 —>
SIP/2.0 401 Unauthorized
Via: SIP/2.0/TLS ;rport=18974;received=;branch=z9hG4bK-524287-1—2939ec3cf926e87f
Call-ID: 93186MzZkYTQyYWExMDJiZjllY2FjYmRkZDU2NDMwNjM3OWI
From: “Oscar Santos” <sip_address_>;tag=38200b7e
To: “Oscar Santos” <sip_address>;tag=z9hG4bK-524287-1—2939ec3cf926e87f
CSeq: 2 REGISTER
WWW-Authenticate: Digest realm=“asterisk”,nonce=“1533141792/e9438f21617d9ee07e3b67197b9cf324”,opaque=“3d9961546d2243d6”,algorithm=md5,qop=“auth”
Server: FPBX-14.0.3.10(13.22.0)
Content-Length: 0

Asterisk Reload

[2018-08-01 12:40:40] ERROR[6531]: config_options.c:708 aco_process_config: Unable to load config file ‘acl.conf’
[2018-08-01 12:40:40] WARNING[6531]: named_acl.c:413 ast_named_acl_reload: Could not reload ACL config
[2018-08-01 12:40:40] NOTICE[6531]: cdr.c:4459 cdr_toggle_runtime_options: CDR simple logging enabled.
– CEL logging enabled.
Bound HTTP server to address [::]:0
== TLS/SSL ECDH initialized (automatic), faster PFS ciphers enabled
== TLS/SSL certificate ok
– Setting default indication country to ‘us’
Asterisk Queue Logger restarted
– Reloading module ‘res_odbc.so’ (ODBC resource)
[2018-08-01 12:40:41] NOTICE[6531]: res_odbc.c:616 load_odbc_config: Registered ODBC class ‘asteriskcdrdb’ dsn->[MySQL-asteriskcdrdb]
– Reloading module ‘res_config_odbc.so’ (Realtime ODBC configuration)
– Reloading module ‘cdr_adaptive_odbc.so’ (Adaptive ODBC CDR backend)
– Found adaptive CDR table [email protected]
– Found alias start for column calldate in [email protected]
> Found calldate column with type 93 with len 19, octetlen 19, and numlen (0,10)
> Found clid column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found src column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found dst column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found dcontext column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found channel column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found dstchannel column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found lastapp column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found lastdata column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found duration column with type 4 with len 10, octetlen 10, and numlen (0,10)
> Found billsec column with type 4 with len 10, octetlen 10, and numlen (0,10)
> Found disposition column with type -9 with len 45, octetlen 540, and numlen (0,0)
> Found amaflags column with type 4 with len 10, octetlen 10, and numlen (0,10)
> Found accountcode column with type -9 with len 20, octetlen 240, and numlen (0,0)
> Found uniqueid column with type -9 with len 32, octetlen 384, and numlen (0,0)
> Found userfield column with type -9 with len 255, octetlen 3060, and numlen (0,0)
> Found did column with type -9 with len 50, octetlen 600, and numlen (0,0)
> Found recordingfile column with type -9 with len 255, octetlen 3060, and numlen (0,0)
> Found cnum column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found cnam column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found outbound_cnum column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found outbound_cnam column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found dst_cnam column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found linkedid column with type -9 with len 32, octetlen 384, and numlen (0,0)
> Found peeraccount column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found sequence column with type 4 with len 10, octetlen 10, and numlen (0,10)
– Reloading module ‘pbx_config.so’ (Text Extension Configuration)
== Setting global variable ‘CFDEVSTATE’ to ‘TRUE’
== Setting global variable ‘MIXMON_BEEP’ to ‘’
== Setting global variable ‘DYNAMIC_FEATURES’ to ‘pauserecord,apprecord’
== Setting global variable ‘DNDDEVSTATE’ to ‘TRUE’
== Setting global variable ‘FMDEVSTATE’ to ‘TRUE’
== Setting global variable ‘QUEDEVSTATE’ to ‘TRUE’
== Setting global variable ‘QUEUETOGGLE’ to ‘*45’
== Setting global variable ‘QUEUEPAUSETOGGLE’ to ‘*46’
== Setting global variable ‘QUEUECALLERS’ to ‘*47’
== Setting global variable ‘INTERCOMCODE’ to ‘*80’
== Setting global variable ‘ASTETCDIR’ to ‘/etc/asterisk’
== Setting global variable ‘ASTMODDIR’ to ‘/usr/lib64/asterisk/modules’
== Setting global variable ‘ASTVARLIBDIR’ to ‘/var/lib/asterisk’
== Setting global variable ‘ASTAGIDIR’ to ‘/var/lib/asterisk/agi-bin’
== Setting global variable ‘ASTSPOOLDIR’ to ‘/var/spool/asterisk’
== Setting global variable ‘ASTRUNDIR’ to ‘/var/run/asterisk’
== Setting global variable ‘ASTLOGDIR’ to ‘/var/log/asterisk’
== Setting global variable ‘CWINUSEBUSY’ to ‘1’
== Setting global variable ‘AMPMGRUSER’ to ‘admin’
== Setting global variable ‘AMPMGRPASS’ to ‘22664359c15d1d67a24d1891fea6544d’
== Setting global variable ‘ASTMANAGERHOST’ to ‘localhost’
== Setting global variable ‘AMPDBENGINE’ to ‘mysql’
== Setting global variable ‘AMPDBHOST’ to ‘localhost’
== Setting global variable ‘AMPDBNAME’ to ‘asterisk’
== Setting global variable ‘AMPDBUSER’ to ‘freepbxuser’
== Setting global variable ‘AMPDBPASS’ to ‘1d1c2c3eb18bf18c89e11c9b19b7ffb5’
== Setting global variable ‘AMPBIN’ to ‘/var/lib/asterisk/bin’
== Setting global variable ‘VMX_CONTEXT’ to ‘from-internal’
== Setting global variable ‘VMX_PRI’ to ‘1’
== Setting global variable ‘VMX_TIMEDEST_CONTEXT’ to ‘’
== Setting global variable ‘VMX_TIMEDEST_EXT’ to ‘dovm’
== Setting global variable ‘VMX_TIMEDEST_PRI’ to ‘1’
== Setting global variable ‘VMX_LOOPDEST_CONTEXT’ to ‘’
== Setting global variable ‘VMX_LOOPDEST_EXT’ to ‘dovm’
== Setting global variable ‘VMX_LOOPDEST_PRI’ to ‘1’
== Setting global variable ‘MIXMON_DIR’ to ‘’
== Setting global variable ‘MIXMON_POST’ to ‘’
== Setting global variable ‘DIAL_OPTIONS’ to ‘twW’
== Setting global variable ‘TRUNK_OPTIONS’ to ‘TwrW’
== Setting global variable ‘TRUNK_RING_TIMER’ to ‘300’
== Setting global variable ‘MIXMON_FORMAT’ to ‘wav’
== Setting global variable ‘REC_POLICY’ to ‘caller’
== Setting global variable ‘RINGTIMER_DEFAULT’ to ‘20’
== Setting global variable ‘TRANSFER_CONTEXT’ to ‘from-internal-xfer’
== Setting global variable ‘ASTVERSION’ to ‘13.22.0’
== Setting global variable ‘ASTCHANDAHDI’ to ‘1’
== Setting global variable ‘NULL’ to ‘""’
== Setting global variable ‘OUT_1’ to ‘SIP/fpbx-1-4F8F7ODMkmkJ’
== Setting global variable ‘OUTCID_1’ to ‘9092599299’
== Setting global variable ‘OUTMAXCHANS_1’ to ‘’
== Setting global variable ‘OUTFAIL_1’ to ‘’
== Setting global variable ‘OUTPREFIX_1’ to ‘’
== Setting global variable ‘OUTDISABLE_1’ to ‘off’
== Setting global variable ‘OUTKEEPCID_1’ to ‘off’
== Setting global variable ‘FORCEDOUTCID_1’ to ‘’
== Setting global variable ‘PREFIX_TRUNK_1’ to ‘20’
== Setting global variable ‘OUT_2’ to ‘SIP/fpbx-2-4F8F7ODMkmkJ’
== Setting global variable ‘OUTCID_2’ to ‘9092599299’
== Setting global variable ‘OUTMAXCHANS_2’ to ‘’
== Setting global variable ‘OUTFAIL_2’ to ‘’
== Setting global variable ‘OUTPREFIX_2’ to ‘’
== Setting global variable ‘OUTDISABLE_2’ to ‘off’
== Setting global variable ‘OUTKEEPCID_2’ to ‘off’
== Setting global variable ‘FORCEDOUTCID_2’ to ‘’
== Setting global variable ‘PREFIX_TRUNK_2’ to ‘18’
== Setting global variable ‘ALLOW_SIP_ANON’ to ‘no’
== Setting global variable ‘SIPLANG’ to ‘en’
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of ‘_.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 1102 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 1103 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 4395 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 4396 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 4397 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 4398 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 4399 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7841 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7842 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7843 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7844 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7850 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7851 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7883 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 7884 of /etc/asterisk/extensions_additional.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 127 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 128 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 129 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 130 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 131 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 132 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 133 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 172 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 173 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 174 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 186 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘X.’ instead at line 187 of extensions.conf
[2018-08-01 12:40:41] WARNING[6531]: pbx_config.c:1843 pbx_load_config: The use of '
.’ for an extension is strongly discouraged and can have unexpected behavior. Please use ‘_X.’ instead at line 188 of extensions.conf
– Time to scan old dialplan and merge leftovers back into the new: 0.001331 sec
– Time to restore hints and swap in new dialplan: 0.000384 sec
– Time to delete the old dialplan: 0.001750 sec
– Total time merge_contexts_delete: 0.003465 sec
– pbx_config successfully loaded 195 contexts (enable debug for details).
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘from-internal-xfer’ tries to include nonexistent context ‘from-internal-custom’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘from-internal-noxfer’ tries to include nonexistent context ‘from-internal-noxfer-custom’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘from-pstn’ tries to include nonexistent context ‘from-pstn-custom’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘from-internal-additional’ tries to include nonexistent context ‘app-recordings’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-11’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-9’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-4’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-3’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-2’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
[2018-08-01 12:40:41] WARNING[6531]: pbx.c:8547 ast_context_verify_includes: Context ‘ivr-1’ tries to include nonexistent context ‘from-ivr-directory-Disabled’
– Reloading module ‘res_pjproject.so’ (PJPROJECT Log and Utility Support)
[2018-08-01 12:40:41] ERROR[6531]: res_sorcery_config.c:261 sorcery_config_internal_load: Unable to load config file ‘pjproject.conf’
– Reloading module ‘res_pjsip.so’ (Basic SIP resource)
[2018-08-01 12:40:41] NOTICE[6279]: sorcery.c:1253 sorcery_object_load: Type ‘system’ is not reloadable, maintaining previous values
– Reloading module ‘res_crypto.so’ (Cryptographic Digital Signatures)
– Reloading module ‘res_pjsip_outbound_publish.so’ (PJSIP Outbound Publish Support)
– Reloading module ‘res_fax.so’ (Generic FAX Applications)
– Reloading module ‘res_ari.so’ (Asterisk RESTful Interface)
– Reloading module ‘res_parking.so’ (Call Parking Resource)
– Remove parkedcalls/71/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/72/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/73/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/74/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/75/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/76/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/77/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/78/1, registrar=res_parking/default; con=((nil)); con->root=(nil)
– Remove parkedcalls/70/1, registrar=res_parking; con=((nil)); con->root=(nil)
– Reloading module ‘res_config_curl.so’ (Realtime Curl configuration)
– Reloading module ‘res_config_mysql.so’ (MySQL RealTime Configuration Driver)
== MySQL RealTime reloaded.
– Reloading module ‘res_pjsip_authenticator_digest.so’ (PJSIP authentication resource)
– Reloading module ‘res_pjsip_endpoint_identifier_ip.so’ (PJSIP IP endpoint identifier)
– Reloading module ‘res_musiconhold.so’ (Music On Hold Resource)
– Reloading module ‘res_rtp_asterisk.so’ (Asterisk RTP Stack)
== RTP Allocating from port range 10000 -> 40000
– Reloading module ‘res_pjsip_publish_asterisk.so’ (PJSIP Asterisk Event PUBLISH Support)
– Reloading module ‘res_pjsip_mwi.so’ (PJSIP MWI resource)
– Reloading module ‘chan_iax2.so’ (Inter Asterisk eXchange (Ver 2))
[2018-08-01 12:40:41] WARNING[6531]: iax2/firmware.c:237 iax_firmware_reload: Error opening firmware directory ‘/var/lib/asterisk/firmware/iax’: No such file or directory
[2018-08-01 12:40:41] NOTICE[6531]: iax2/provision.c:562 iax_provision_reload: No IAX provisioning configuration found, IAX provisioning disabled.
– Reloading module ‘chan_sip.so’ (Session Initiation Protocol (SIP))
Reloading SIP
– Reloading module ‘chan_dahdi.so’ (DAHDI Telephony w/PRI & SS7 & MFC/R2)
– Reloading module ‘res_pjsip_notify.so’ (CLI/AMI PJSIP NOTIFY Support)
– Reloading module ‘res_adsi.so’ (ADSI Resource)
– Reloading module ‘res_pjsip_outbound_registration.so’ (PJSIP Outbound Registration Support)
– Reloading module ‘app_meetme.so’ (MeetMe conference bridge)
– Reloading module ‘app_confbridge.so’ (Conference Bridge Application)
== Using SIP TOS bits 96
== Using SIP CoS mark 4
[2018-08-01 12:40:41] NOTICE[6531]: confbridge/conf_config_parser.c:2089 verify_default_profiles: Adding default_menu menu to app_confbridge
– Reloading module ‘cel_odbc.so’ (ODBC CEL backend)
– Found CEL table [email protected]
> Found id column with type 4 with len 10, octetlen 10, and numlen (0,10)
> Found eventtype column with type -9 with len 30, octetlen 360, and numlen (0,0)
> Found eventtime column with type 93 with len 19, octetlen 19, and numlen (0,10)
> Found cid_name column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found cid_num column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found cid_ani column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found cid_rdnis column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found cid_dnid column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found exten column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found context column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found channame column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found appname column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found appdata column with type -9 with len 255, octetlen 3060, and numlen (0,0)
> Found amaflags column with type 4 with len 10, octetlen 10, and numlen (0,10)
> Found accountcode column with type -9 with len 20, octetlen 240, and numlen (0,0)
> Found uniqueid column with type -9 with len 32, octetlen 384, and numlen (0,0)
> Found linkedid column with type -9 with len 32, octetlen 384, and numlen (0,0)
> Found peer column with type -9 with len 80, octetlen 960, and numlen (0,0)
> Found userdeftype column with type -9 with len 255, octetlen 3060, and numlen (0,0)
> Found extra column with type -9 with len 512, octetlen 6144, and numlen (0,0)
– Reloading module ‘cel_manager.so’ (Asterisk Manager Interface CEL Backend)
– Reloading module ‘app_voicemail.so’ (Comedian Mail (Voicemail System))
[2018-08-01 12:40:41] WARNING[6531]: app_voicemail.c:13872 actual_load_config: maxsilence should be less than minsecs or you may get empty messages
– Reloading module ‘app_playback.so’ (Sound File Playback Application)
– Reloading module ‘codec_dahdi.so’ (Generic DAHDI Transcoder Codec Translator)
– Reloading module ‘app_flite.so’ (Flite TTS Interface)
[2018-08-01 12:40:41] WARNING[6531]: app_flite.c:76 read_config: Flite: Unable to read config file flite.conf. Using default settings
– Reloading module ‘app_queue.so’ (True Call Queueing)
[2018-08-01 12:40:41] NOTICE[6531]: app_queue.c:8848 reload_queue_rules: queuerules.conf has not changed since it was last loaded. Not taking any action.
– Remote UNIX connection disconnected
== TLS/SSL ECDH initialized (automatic), faster PFS ciphers enabled
== TLS/SSL certificate ok

Have you tried an Asterisk restart?

I have seen a few kinks when converting pjsip to chansip and vice versa, such as options qualify messages still being sent to the former port, etc and other things.
An Asterisk restart has fixed those for me for the most part.

Hello avayax,

Yes, I have tried restarting Asterisk using fwconsole restart, rebooting server, verifying database entries, and even looked into Sorcery (thinking something was still cached), but no luck. i couldn’t confirm whether Sorcery is enabled on FreePBX, but I researched it anyway. It does seem like there are lingering configs that can not be purged and I can’t figure out where else to look.

Thanks for the reply.

I had a similar issue. The trick was exporting your config and compare the pjsip to the sip ext. I then copied the settings to all the other etc. I believe the one issue was the RFC setting. Also, once you do convert them, I’ve also opened them up in Ext manager, click to change them back to chan_sip, click submit, then click to convert to chan_pjsip, click Submit, and then click Apply. If you change, but don’t hit submit, I’ve run into issues.

Try running service iptables stop from the command line and seeing if the phone register. Then you can turn ip tables back on

Hello Chris,

Thank you for the reply. I have tried to convert it back to chan_sip then back to pjsip, but no dice. Can you elaborate on your statement:

When I did the conversion, I removed all chan_sip specific settings and only populated PJSIP settings. From your statement, it seems I should leave the chan_sip stuff in? It does include port number, etc. Weird thing is, now when I create a new PJSIP extension from scratch; that can’t even register now.

Tried this, but issue persists. Thank you for the reply.

When I did a bulk import before, when I changed from sip -> pjsip, I only changed 1 field, and they all dropped off and wouldn’t register. My solution at the time was to do what I described previously:

  • Extensions
  • Switch to chan sip, click Submit
  • Switch to pjsip, click Submit
  • Click apply
    At that point, they started working.

Another option would be to try changing the password, maybe delete a couple of characters and then have Endpoint manager (if using Sangoma phones) rebuild the config and reboot the phone and see if it helps.

In my case, all my phones are Sangoma phones.

Also, you could try changing your transport to UDP (under Advanced) and see if that helps as well. I also had to do that with a few extensions as well.

Restored database backup from before the extensions were imported. Attempted converting a chan_sip extension to PJSIP and same Failed to Authenticate error is flagging. Could PJSIP be in a bad state? Chan_sip is working without issue.

This is the point a lot of people miss.

You HAVE to press submit again after converting.

Chris,

I think your suggestion did the trick, however, I spammed switching the driver like a mad man! At first, I switched back and forth as you suggested, but same issue. Attempted it a few more times and it registered! I would like to know what might be going on here?

But thank you Chris for the suggestion! I will attempt this on my other problematic extensions.

I think PitzKey did point out the one key. If you don’t click Submit, it won’t work and will mess things up.

Glad you made progress.

Chris

1 Like

Looks like only 1 extension was able to resolve, by using the same method discussed of switching the drivers, is not working for the others. Currently looking through the configs to see what the difference between the known good extension and the others, but if anyone else has a suggestion; I would greatly appreciate it. Can provide logs when requested.

What type of provisioning are you using to program the phones?

Hey Chris,

The softphone is provisioned through a central portal that has some static configurations such as SIP port (5061) and other SSO settings, but other settings like SIP username, secret, and SIP server are configurable. So, the important settings with registering an extension are configurable and the static settings wouldn’t be conflicting. Besides, prior to this mass edit using Bulk Handler, my registrations were solid. The hardphones are simply provisioned through the web UI of the phone and those are unable to register anymore on PJSIP as well. Everything still works with chan_sip, which is the annoying part of all this.

Attempting to reload just the res_pjsip module prompts with this notice:

*CLI> module reload res_pjsip.so
Module ‘res_pjsip.so’ reloaded successfully.
– Reloading module ‘res_pjsip.so’ (Basic SIP resource)
[2018-08-02 12:46:34] NOTICE[23623]: sorcery.c:1253 sorcery_object_load: Type ‘system’ is not reloadable, maintaining previous values

I investigated sorcery before, but couldn’t find too much information on it or even confirm whether it is running on FreePBX. Could this be a possible cause to my PJSIP issues? Thanks.

Well, in my setup, if I change from chan_sip to pjsip, I have to use a different port, since they can’t be on the same port. I have pjsip defaulting to 5060 and chan_sip to 5160.

After you convert the extension from chan_sip to pjsip, do you update the port on your central portal?

Ah ok, that’s what you meant.

I have pjsip as the default driver set to UDP (5060) and TLS (5061) and chan_sip set to UDP (5160) and TLS (5161). The central portal has a profile that sets the registration port to 5061.

To remove all those factors, I have reverted to testing just on a hard phone so we can concentrate on that scenario. This morning results mirror that of yesterday; chan_sip registers fine and only 1 extension can register on PJSIP. I have matched settings between known good extension and bad testing extension.

Do you happen to know how to purge data from the Sorcery Cache? I have a weird feeling it might be that, but haven’t been able to find the right CLI commands to purge registration cache.

I don’t know about clearing the Sorcery Cache. I do know that you have to be precise with the pjsip settings; otherwise, it won’t load at all.

Do you have any extensions working with pjsip?

And in terms of registration, have you tried not using TLS and just have it register on port 5060?

Are the chan_sip extensions registering on the same port? Or on 5161?

Chris,

I had one extension working, but I just recently changed the secret at the extension level and that broke it too. Makes me think it is related and will try to re-import with Bulk Handler and try the REGEN option, maybe it’ll clear something.

The extensions register in every other scenario possible; UDP over sip and pjsip, TLS on chan_sip, etc. Chan_sip registers on 5161 no problem. Thanks again.