Installing FreePBX 14 on CentOS 7
READ FIRST
Manual installations of FreePBX is considered an EXPERTS ONLY exercise. This method of installation is enough to get CORE functionality of FreePBX. Non-commercial modules may not function as expected or detailed in the Wiki's. Certain modules and features may require additional software to be installed and configured on the server.
**** COMMERCIAL MODULES CANNOT BE INSTALLED ON THIS OS ****
For Asterisk 16 you must enable app_macro in make menuselect
- 1 Install Centos 7
- 1.1 Initial System Setup
- 1.1.1 Disable selinux
- 1.1.2 Update Your System
- 1.1.3 Add the Asterisk User
- 1.1.4 Firewalld Basic Configuration
- 1.1.5 Install Additional Required Dependencies
- 1.1.6 Install php 5.6 repositories
- 1.1.7 Install php5.6w
- 1.1.8 Install nodejs
- 1.1.9 Enable and Start MariaDB
- 1.1.10 Enable and Start Apache
- 1.1.11 Install Legacy Pear requirements
- 1.2 Install and Configure Asterisk
- 1.3 Compile and Install jansson
- 1.4 Compile and install Asterisk
- 1.5 Install and Configure FreePBX
- 1.6 Automatic Startup
- 1.1 Initial System Setup
Install Centos 7
Initial System Setup
You MUST run all of these commands as the root user!
You MUST disable selinux. selinux can cause strange behavior during the install
Disable selinux
In /etc/sysconfig/selinux , change the following lines:
sed -i 's/\(^SELINUX=\).*/\SELINUX=disabled/' /etc/sysconfig/selinux
sed -i 's/\(^SELINUX=\).*/\SELINUX=disabled/' /etc/selinux/config |
reboot, and verify the selinux status by running 'sestatus'. It should say:
SELinux status: disabled |
Update Your System
yum -y update
yum -y groupinstall core base "Development Tools" |
Add the Asterisk User
Firewalld Basic Configuration
You must open port 80 so that you can access the administration interface
Install Additional Required Dependencies
Install php 5.6 repositories
Install php5.6w
Install nodejs
Enable and Start MariaDB
You must have MariaDB running for freepbx to operate normally. It must start automatically, and be running continuously.
Now that our MariaDB database is running, we want to run a simple security script that will remove some dangerous defaults and lock down access to our database system a little bit
The prompt will ask you for your current root password. Since you just installed MySQL, you most likely won’t have one, so leave it blank by pressing enter. Then the prompt will ask you if you want to set a root password. Do not set a root password. We secure the database automatically, as part of the install script. Apart from that you can chose yes for the rest. This will remove some sample users and databases, disable remote root logins, and load these new rules so that MySQL immediately respects the changes we have made.
Enable and Start Apache
FreePBX uses the Apache web server, so this must be started and running.
Install Legacy Pear requirements
Install and Configure Asterisk
Download Asterisk source files.
Asterisk 15
Asterisk 16
Compile and install DAHDI
Compile and Install jansson
Compile and install Asterisk
You will be prompted at the point to pick which modules to build. Most of them will already be enabled, but if you want to have MP3 support (eg, for Music on Hold), you need to manually turn on 'format_mp3' on the first page.
After selecting 'Save & Exit' you can then continue
Set Asterisk ownership permissions.
Install and Configure FreePBX
A few small modifications to Apache.
Download and install FreePBX.
That's it!
You can now start using FreePBX. Open up your web browser and connect to the IP address or hostname of your new FreePBX server. You will see the Admin setup page, which is where you set your 'admin' account password, and configure an email address to receive update notifications.
We hope you enjoy using FreePBX 14!
Automatic Startup
Please note you need to set up FreePBX to start asterisk (and it's associated services) on bootup. You can view an example systemd startup script here.