Install FreePBX 13 on Centos 7

By on January 22nd, 2018

Install FreePBX 13 on Centos 7


FreePBX is an open source web-based Graphical-User interface which manages Asterisk, a voice over IP and telephony server and the FreePBX is licensed under GNU General Public License version 3. The FreePBX can be installed manually on our servers or it comes with a pre-configured FreePBX Distro that includes the system OS, Asterisk, FreePBX GUI and all the dependencies. The FreePBX can be installed as a stand-alone application on a server and it also includes the open source distributions such as The Official FreePBX Distro, AsteriskNOW, Elastix, and RasPBX.



First step is to disable SELinux feature on your server, to disable the SELinux please execute below commands.

# sed -i ‘s/\(^SELINUX=\).*/\SELINUX=disabled/’ /etc/sysconfig/selinux

# sed -i ‘s/\(^SELINUX=\).*/\SELINUX=disabled/’ /etc/selinux/config

The next step is to update your server and install Development tools and Additional dependencies on your server. You can achieve these by executing below commands.

# yum -y update

# yum -y groupinstall core base “Development Tools”

# yum -y install lynx mariadb-server mariadb php php-mysql php-mbstring tftp-server httpd ncurses-devel sendmail sendmail-cf sox newt-devel libxml2-devel libtiff-devel audiofile-devel gtk2-devel subversion kernel-devel git php-process crontabs cronie cronie-anacron wget vim php-xml uuid-devel sqlite-devel net-tools gnutls-devel php-pear unixODBC mysql-connector-odbc

Also we need to add a Asterisk user on our server by execute below command.

# adduser asterisk -M -c “Asterisk User”


1) After performing above steps we need to Install and configure Asterisk on our server, you can perform below commands to download the required source files.

# cd /usr/src

# wget

#wget -O jansson.tar.gz

# wget


2) Then we need to compile and install pjproject, jansson on our server. For that we can execute below commands. (First one is for pjproject and second is for jansson service)

# cd /usr/src

# tar -xjvf pjproject-2.4.tar.bz2

# cd pjproject-2.4

# CFLAGS=’-DPJ_HAS_IPV6=1′ ./configure –prefix=/usr –enable-shared

–disable-sound –disable-resample –disable-video –disable-opencore-amr –libdir=/usr/lib64

# make dep

# make

# make install

# cd /usr/src

# tar vxfz jansson.tar.gz

# cd jansson-*

# autoreconf -i

# ./configure –libdir=/usr/lib64

# make

# make install


3) After completing the installation of pjproject and jansson we need to install Asterisk by execute below command follow the steps.

# cd /usr/src

# tar xvfz asterisk-13-current.tar.gz

# cd asterisk-*

# contrib/scripts/install_prereq install

# ./configure –libdir=/usr/lib64

# contrib/scripts/

# make menuselect


At this stage it’ll prompt a menu on which we can select which modules to build, you don’t need to select any. Normally most of them will already be enabled automatically, but in case you need MP3 support, you can turn on “format_mp3” on the first page of the menu.


Once everything completed you can continue by click on “Save & Exit”. Then execute following commands to complete Asterisk installation.

# make

# make install

# make config

# ldconfig

# chkconfig asterisk off

Once it is completed we need to correct the Ownership of following directories as below.

# chown asterisk. /var/run/asterisk

# chown -R asterisk. /etc/asterisk

# chown -R asterisk. /var/{lib,log,spool}/asterisk

# chown -R asterisk. /usr/lib64/asterisk

# chown -R asterisk. /var/www/


4) Before Installing FreePBX on the server, we need to make few modifications on PHP configuration such as “Upload_max_filesize” set to 120M and change “AllowOverride None” to “AllowOverride All” on apache configuration file. After making these changes download and install FreePBX on your server.

# cd /usr/src

# wget

# tar xfz freepbx-13.0-latest.tgz

# cd freepbx

# ./start_asterisk start

# ./install -n



Please do reach our support department if you need any further help.


Leave a Reply