FreePBX

How I connected a network_mode: host container to its database container

I have setup my FreePBX to use network_mode: 'host' but faced issues when it couldn’t connect to the MariaDB container which was not using network_mode: 'host'.

I fixed this by:

  • Setting the MariaDB container to network_mode: 'host'
  • Setting the FreePBX container to connect to 127.0.0.1 (DB_HOST=127.0.0.1). Setting it to localhost did NOT allow FreePBX to connect to MariaDB!
Posted by Uli Köhler in Docker, FreePBX, Networking

How to run Asterisk command from shell

Use

asterisk -rx "[command]"

to run an Asterisk command (-x) in an already running Asterisk server (-r), for example:

asterisk -rx "core restart now"

 

Posted by Uli Köhler in FreePBX

How to restart Asterisk in FreePBX

This tutorial will show how to restart the Asterisk service in FreePBX.

First, you need to install the Asterisk CLI module. In order to do that, login to your FreePBX admin panel and click at the Admin -> Module Admin menu entry.

After the module is installed, open Admin -> Asterisk CLI

Now enter one of the following commands

  • If you just want to restart Asterisk immediately, even if that stops ongoing calls, enter
    core restart now

    This is typically used while setting up the PBX

  • If you don’t want to interrupt ongoing calls but you don’t want to admit new calls, use
    core restart gracefully

    Asterisk will restart when all ongoing calls have been finished

  • In case you don’t want to interrupt ongoing calls but still admit new calls to the system, use
    core restart when convenient

    Asterisk will restart at the first opportunity when no calls are in progress

Posted by Uli Köhler in FreePBX

How to change SIP port in FreePBX

In order to change the SIP port for chan_pjsip from the default port 5060 to a custom value first go to Settings => Asterisk SIP Settings

Then go to the SIP settings [chan_pjsip] tab:

Now scroll down to the bottom of the page and look for

Change it to the desired port, e.g. 15060

click Submit on the bottom right

After that, don’t forget to click Apply Config on the top right

You also need to Restart Asterisk after the change.

Posted by Uli Köhler in FreePBX

How to fix FreePBX 15 The Module Named “manager” is required.

Problem:

When trying to install a FreePBX 15 module like Asterisk REST Interface Users you see the error message

The Module Named "manager" is required.

but you can’t find the manager module in the module list

Solution:

As you can see in module.xml in manager’s GitHub repository (which you can find easily by just googling FreePBX manager), the module is called

Asterisk API

Note that you can just click on the The Module Named "arimanager" is required. message if you disable your AdBlocker.

Posted by Uli Köhler in FreePBX

How to fix FreePBX 15 The Module Named “arimanager” is required.

Problem:

When trying to install a FreePBX 15 module like Asterisk Info you see the error message

The Module Named "arimanager" is required.

but you can’t find the arimanager module in the list of available modules.

Solution:

As you can see in module.xml in arimanager’s GitHub repository (which you can find easily by just googling arimanager), the module is called

Asterisk REST Interface Users

In order to install it, you also need the manager module which is called

Asterisk API

Note that you can just click on the The Module Named "arimanager" is required. message if you disable your AdBlocker.

Posted by Uli Köhler in FreePBX