How to Install Asterisk 13 and PJSIP on CentOS 6

0 8 Comments

This post details step by step guide on How to install Asterisk 13 and PJSIP on CentOS 6 Linux distribution, which means prior to installing Asterisk (VOIP telephony); pjproject libraries needs to be installed first to meet the dependencies for Asterisk 13.

Step 1 – Update System

The first step is to install and update required dependencies Asterisk 13 requires to build the PJSIP libraries. We will be using CentOS yum package manager to update all currently installed packages to their latest version and then install some of the most common dependencies for Asterisk and PJSIP.

# yum update

Please note that kernel-devel package installed must match with the kernel installed in the system. You may receive errors or installation failures if you both kernels mismatch. Our main goal from is to learn how to install Asterisk 13 and PJSIP on CentOS 6 operating system.

yum update command above can handle the above process to update kernel but if you see any failures than please do check kernel-devel and kernel version running on the system. That is the main reason to run yum update first. If the kernel has been updated, be sure to reboot before moving forward. More information about the kernel-devel packages available for CentOS can be found here. The next is to run below command which will install several packages that are needed to compile and install PJSIP and Asterisk 13.

# yum install -y epel-release dmidecode gcc-c++ ncurses-devel libxml2-devel make wget openssl-devel newt-devel kernel-devel sqlite-devel libuuid-devel gtk2-devel jansson-devel binutils-devel

Next Step – Install pjproject before installing Asterisk

Please download and install the pjproject sip library directly from PJSIP website and change the directories to work in the /usr/src directory. We can download it under usr/src directory and un-tar the zip file using tar command.

# cd /usr/src

# wget

# tar -jxvf pjproject-2.3.tar.bz2

This will create the pjproject-2.3 directory. Change to this directory and run the following set of commands to build and install the pjproject sip library.

# cd pjproject-2.3

# ./configure CFLAGS=”-DNDEBUG -DPJ_HAS_IPV6=1″ –prefix=/usr –libdir=/usr/lib64 –enable-shared –disable-video –disable-sound –disable-opencore-amr

Please use -–libdir=/usr/lib64 option from the command if pjproject is installed on the 64 bit. You can just remove the above line command parameters if the system is 32 bit. Other options can be checked using ./configure –help command for detailed view of options disable or enable as per requirement.


Obtaining the latest pjproject from the svn repo:

Use  svn to install the latest version from

# svn co pjproject-trunk

After completion to above command please run below commands, if you ran into issues then please run distclean and change the parameters required for successful build process.

# make dep
# make
# make install
# ldconfig

And finally this next command will verify the pjsip libraries have been dynamically linked.

# ldconfig -p | grep pj

Your output should look something like this:

 (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/
   (libc6,x86-64) => /usr/lib/

Last step – Install Asterisk 13

Now we’ll follow the steps to download and install the certified-Asterisk 13.1 version from source under /usr/src directory

# cd /usr/src

Next step is to download using “wget” command to download the tarball from

# wget

Next the tar command will unpack the Asterisk source code into a new directory named certified-Asterisk-13.1.

# tar -zxvf certified-Asterisk-13.1-current.tar.gz

# cd certified-Asterisk-13.1-cert1

The next set of commands will build and install Asterisk. Remember to skip the -–libdir=/usr/lib64 option for 32-bit versions of CentOS. In that case just run the command 


# ./configure –libdir=/usr/lib64

Next you will run the make menuselect command. This step will verify if the pjsip channel driver dependencies have been successfully installed.

# make menuselect

Use the arrow keys to navigate to “Resource Modules” in the left column, about halfway down the list. Press the right arrow key and then scroll down until you see the list of modules beginning with “res_pjsip_”. If these modules have “XXX” to the left of their name then the dependencies have not been met. You’ll need to go back to the /usr/src/pjproject directory, run the “make distclean” command and start over carefully looking for any error messages and proceed from there. If you see [*] instead of XXX then the res_pjsip module’s dependencies have been met and you can proceed to the next steps. Your menuselect screen should look like this:


After exiting the menu, select screen the next set of commands will build and install Asterisk along with a set of sample configuration files.

# make

# make install

# make samples

If you want Asterisk to start at boot time use the following command to setup the Asterisk service.

# make config

And finally, run the command “service Asterisk start” to immediately begin the Asterisk service without the need to reboot first.

Hope this post helps if you plan to install Asterisk 13 with PJSIP on CentOS 6 operating system. if you would like to read some other posts than click on the blog link here to learn other posts. We will try our best to update the post with latest version of Asterisk available to download which has a lot of VOIP features to offer at reduced cost for your VOIP telephony solutions for small medium or large organizations. It can also help individuals or VOIP administrators to upgrade their current version of Asterisk or thinking to migrate their VOIP telephony solution to Asterisks.


8 thoughts on “How to Install Asterisk 13 and PJSIP on CentOS 6”

  1. JamesinFug says:

    Neat page, Preserve the good job. With thanks.

  2. Good article! We are linking to this particularly great content on our website. Keep up the good writing. Birgit Derron Kyle

  3. film izle says:

    I am sure this post has touched all the internet viewers, its really really nice piece of writing on building up new weblog. Ingaberg Enrique Forta

  4. yabanci says:

    I believe you have mentioned some very interesting details, regards for the post. Vanessa Lutero Domineca

  5. netflix says:

    Excellent post. I am experiencing a few of these issues as well.. Aime Maison Baruch

  6. 1080p says:

    Awesome write-up. I am a normal visitor of your website and appreciate you taking the time to maintain the nice site. I will be a frequent visitor for a really long time. Saraann Keith Metsky

  7. diziler says:

    You can definitely see your expertise in the work you write. The world hopes for even more passionate writers like you who are not afraid to say how they believe. Always follow your heart. Kimbra Roland Tierza

  8. online says:

    I savor, lead to I discovered just what I used to be having a look for. You have ended my four day lengthy hunt! God Bless you man. Have a nice day. Bye Ericka Cleve Killoran

Comments are closed.