Here is Step-by-Step Guide to Installing Asterisk16 on CentOs7.
Before starting to install asterisk16 on CentOs7, make sure your all packages are updated in your system. To update all packages run the command :
yum update
yum update command will update all existing packages. next step is to disable the SELinux.to check if SELinux is enabled OR dishables, run the command :
sestatus
if is showing enables, you need to disable it first. To disable SELinux, edit the selinux file and change the status to disabled.
vim /etc/sysconfig/selinux
Ok, now we have changed the SELinux status. next, we will reboot the system. After the system restarted, we need to download the asterisk16 .gz file.
wget https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-16-current.tar.gz
once downloaded, decompress the downloaded file using the command :
tar -zxvf asterisk-16-current.tar.gz
We can delete the downloaded file.
rm -rf asterisk-16-current.tar.gz
Ok, next go to the extracted folder.
cd asterisk-16.28.0/
Install additional packages :
yum install epel-release
contrib/scripts/install_prereq install
./configure --with-jansson-bundled --with-project-bundled --libdir=/usr/lib64
Next, run the make menuselect command and select your required Asterisk features
make menuselect
Now, run the 'make' command
make
After running the make command, the Asterisk is built and ready to install the process. If you are getting any message like: install any packages based on your menuselect, run the command and install. next, run 'make install' command. it will finally install an asterisk.
make install
'make samples' command will put an asterisk's sample files. like: dialplan and configuration files.
make samples
Move the sample files into another folder. lets say: samplefiles
mkdir /etc/asterisk/samlefiles
mv /etc/asterisk/. /etc/asterisk/samlefiles/
Run 'make basic-pbx' command
make basic-pbx
Finally, run 'make config' and reboot the system.
make config
reboot
Congratulations, you have installed Asterisk16 on your CentOs7. to start the asterisk server :
asterisk
asterisk -r