Asterisk PBX installation tutorial - Ubuntu/Debian

This is a step by step Asterisk installation guide. It is compatible with Ubuntu, Debian and Debian-based distributions.

Download Asterisk Packages

There are quite a few packages Ubuntu will require in order to complete the installation of Asterisk successfully.

Note: if packages fail to install try separating the packages and installing them individually.

First, install the dependencies required:
sudo apt-get install cvs build-essential automake autoconf bison flex libtool libncurses5-dev libssl-dev libgsm1 libgsm1-dev

Switch to /usr/src/ directory:
cd /usr/src/

Type the following to get the current version of DAHDI, libpri and Asterisk:


Extract the files from the tarballs
tar zxvf libpri*
tar zxvf asterisk*

Install libpri

cd /usr/src/libpri*
make && make install

Install Asterisk
Select your options when the menuselect command runs. Then select “Save & Exit” and the installation will continue.

cd /usr/src/asterisk*
./configure && make menuselect && make && make install && make config && make samples

Start Asterisk

Now you are ready to go. Just run:
/etc/init.d/asterisk start

Congratulations! Asterisk is now installed.

More tutorials