How To Install Asterisk on Ubuntu Server

Asterisk is open source telephony platform and VOIP server. It can also be use fully functional private branch exchange (PBX). In fact most of the individuals, small businesses, large enterprises and governments worldwide use Asterisk. This tutorial will guide you through the steps required to install Asterisk on Ubuntu. All the step will be almost similar for Ubuntu 16.04, 18.04 and Asterisk 13.x, 15.x, 16.x


You must have super user privileges. 

You certainly update your Ubuntu system before starting asterisk installation. 

$ sudo apt update && sudo apt upgrade

Following step will install basic required packages 

$ sudo apt install wget build-essential subversion

Download Asterisk

We are going to install Asterisk from source. Download source code in /usr/src directory. Which is the common location to place source codes.

$ cd /usr/src

Current version of Asterisk is 16.4.0. But we are installing Certified Asterisk 13 LTS version. This installation method will be same for Asterisk 13,15 and 16.

Download latest version of Asterisk 15 using wget command.

$ sudo wget

Extract the tarball with using tar -xzvf command.

$ sudo tar –xzvf asterisk-13-current.tar.gz

Change directory to Asterisk source code directory.

$ cd asterisk-13*/

Installing Asterisk Dependencies

The following script will download the MP3 sources. Which are required to build the MP3 module and use MP3 files on Asterisk.

$sudo contrib/scripts/

install_prereq script will resolve the dependencies.

$ sudo ./contrib/scripts/install_prereq install

bootstrap script will install other dependencies if anything else is required.

$ sudo ./

Installing Asterisk

Configure script will checks all required dependencies on your system.

$ sudo ./configure

After successful completion, you will see following output.

Asterisk configuration

We need to start build process using make command.

$ sudo make

Once build process completed, following message will presented.

make install

As per above message you need to run make install command.

$ sudo make install

Make install

Finally, your Asterisk installation has been completed. Next step is to generate sample configuration files. As per above message you can create sample configuration file using make samples.

$ sudo make samples

You can also configure basic PBX using make basic-pbx command.

$ sudo make basic-pbx

You can also install startup/init script using make config command.

$ sudo make config

Start Asterisk Service

To enable Asterisk to start on boot use systemctl enable asterisk

$ sudo systemctl enable asterisk

Now to start Asterisk service use systemctl start asterisk

$ sudo systemctl start asterisk

Connect Asterisk command line interface (CLI)

$ sudo asterisk -r

Asteris CLI


We have shown you how to install Asterisk 13 LTS version from source on your Ubuntu server.

We recommend you check the Asterisk DocumentationIn fact, you should explore the world of IP telephony with Asterisk.

We are providing design, implementation and integration service many technologies. Contact us for more information. 

If you face any issue or have feedback, leave a comment below. We will be happy to help you.

Leave a Reply

Close Menu