Would you like to learn how to install Asterisk on Ubuntu Linux? In this tutorial, we are going to show you how to install and configure the VoIP server Asterisk on Ubuntu Linux version 16.
Ubuntu 17 was not able to compile the required packages.
Hardware List:
The following section presents the list of equipment used to create this Asterisk tutorial.
Every piece of hardware listed above can be found at Amazon website.
Asterisk Playlist:
On this page, we offer quick access to a list of videos related to Ubuntu Linux.
Don’t forget to subscribe to our youtube channel named FKIT.
Asterisk Related Tutorial:
On this page, we offer quick access to a list of tutorials related to Asterisk.
Tutorial – Asterisk on Ubuntu Linux
On the Linux console, use the following commands to set the correct timezone.
# dpkg-reconfigure tzdata
Install the Ntpdate package and set the correct date and time immediately.
# apt-get install ntpdate
# ntpdate pool.ntp.br
In our example, the Ntpdate command was used to set the correct date and time using the Brazilian server pool.ntp.br
Let’s install the NTP service.
# apt-get install ntp
NTP is the service that will keep our server updated.
Use the command date to check the date and time configured on your Ubuntu Linux.
# date
If the system showed the correct date and time, this means that you followed all the steps correctly.
Use the following commands to install the required packages.
# apt-get update
# apt-get install linux-headers-`uname -r`
# apt-get install build-essential
Download, compile and install the DAHDI package.
# mkdir /downloads
# cd /downloads
# wget http://downloads.asterisk.org/pub/telephony/dahdi-linux-complete/dahdi-linux-complete-current.tar.gz
# tar -zxvf dahdi-linux-complete-current.tar.gz
# cd dahdi-linux-complete-2.11.1+2.11.1/
# make all
# make install
Download, compile and install the LIBPRI package.
# cd /downloads
# wget http://downloads.asterisk.org/pub/telephony/libpri/libpri-current.tar.gz
# tar -zxvf libpri-current.tar.gz
# cd libpri-1.6.0
# make all
# make install
Download the Asterisk software and install the required packages.
# cd /downloads
# wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-15-current.tar.gz
# tar -zxvf asterisk-15-current.tar.gz
# cd asterisk-15.4.0/contrib/scripts/
# ./install_prereq install
Compile and install the ASTERISK software.
# cd /downloads/asterisk-15.4.0
# ./configure
# make menuselect
# make
# make install
The make menuselect command will open a menu where you can select modules that should be installed.
If you don’t know what to do, leave default modules and click on the Save and Exit button.
Use the following commands to install configuration files samples:
# make samples
Use the following commands to install the configuration files:
# make config
# make install-logrotate
Use the following commands to start the asterisk service:
# /etc/init.d/asterisk start