'fwconsole reload' failed, config not applied - Asterisk will crash if sip_server is blank!

Hello all…

Was attempting to configure PJSIP Trunks from Bandwidth and couldnt get them working so I deleted the trunk and ended up getting the error in the title.

I have since deleted all trunks on the system, have rebooted and nothing seems to clear the issue.

PBX Version: 16.0.10.42
PBX Distro: 12.7.8-2111-2.sng7
Asterisk Version: 16.20.0

[root@pbx ~]# fwconsole reload --verbose
Reload Started

In PJSip.class.php line 507:

  [Exception]
  Asterisk will crash if sip_server is blank!


Exception trace:
  at /var/www/html/admin/modules/core/functions.inc/drivers/PJSip.class.php:507
 FreePBX\modules\Core\Drivers\PJSip->genConfig() at /var/www/html/admin/modules/core/Core.class.php:300
 FreePBX\modules\Core->genConfig() at /var/www/html/admin/libraries/BMO/FileHooks.class.php:97
 FreePBX\FileHooks->processNewHooks() at /var/www/html/admin/libraries/BMO/FileHooks.class.php:26
 FreePBX\FileHooks->processFileHooks() at /var/www/html/admin/libraries/Console/Reload.class.php:335
 FreePBX\Console\Command\Reload->reload() at /var/www/html/admin/libraries/Console/Reload.class.php:91
 FreePBX\Console\Command\Reload->execute() at /var/www/html/admin/libraries/Composer/vendor/symfony/console/Command/Command.php:255
 Symfony\Component\Console\Command\Command->run() at /var/www/html/admin/libraries/Composer/vendor/symfony/console/Application.php:992
 Symfony\Component\Console\Application->doRunCommand() at /var/www/html/admin/libraries/Composer/vendor/symfony/console/Application.php:255
 Symfony\Component\Console\Application->doRun() at /var/www/html/admin/libraries/Composer/vendor/symfony/console/Application.php:148
 Symfony\Component\Console\Application->run() at /var/lib/asterisk/bin/fwconsole:163

reload [--json] [--dry-run] [--skip-registry-checks] [--dont-reload-asterisk]


I have submitted an Issues Ticket, but thought maybe I’d pop on here to see if anyone else has encountered this.

No, but it probably means there’s something left in the database even after you deleted trunks.

fwconsole mysql

then,

select * from pjsip;

Thank you Bill, I thought it might be something stuck in the database.

Your commands show exactly that, there is a Bandwidth trunk still in the database with “id 7”

Is there a safe way to delete that?

If that’s the only thing in the table: delete from pjsip;

1 Like

Thank you Bill, that fixed it!

You rock

If you can provide steps to repro this condition, please open a bug report. https://issues.freepbx.org/

I am also curious what problem you had with the trunk, which may be related.
I would expect a Bandwidth trunk to be very simple, with no registration or authentication.
What went wrong on incoming calls? On outgoing?

I will see if I can reproduce it

Thanks Lorne

I could not get inbound or outbound calls to work on the Bandwidth PJSIP trunk - very little documentation on Bandwidth PJSIP that I could find

There is no such thing as ‘Bandwidth PJSIP’, only Bandwidth requirements for SIP trunks… If you have chan_sip settings (that are working), post them here (mask phone numbers, account numbers, passwords and anything else you consider personal, but make it clear what each masked item represents) and we’ll try to give you the equivalents for pjsip.

Thank you Stewart1.

I will setup a Bandwidth.com SIP trunk and post the data. I figured since PJSIP was the standard moving forward I would set the trunks up that way.

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