Calling Asterisk IP PBX

Asterisk IP PBX

A long, long time ago in a galaxy far, far away, humans used to make calls, and that’s why several Open Source IP PBX projects were started.

The project I’m going to share with you is Asterisk IP PBX, which has been around for a while, and was the one that got me started in VoIP.

Asterisk is not just an IP PBX, but it’s a tool that can be used for various purposes, as it offers a set of services such as:

  • VoiceGateway
  • SIP proxy
  • Voicemail
  • IVR (interactive voice response)

And many features used in Call Centers, among others.

This post will actually be a tutorial and I will sign it as “Tutoriais da Dona Joaquina” as a tribute to the brilliant Portuguese TV show “Tutoriais da Dona Margarida”, yes, I’m like that, I like these things .

Alright, let’s get down to business!

This tutorial is for installing Asterisk on Ubuntu. In other words, the first step is to install the operating system itself. I won’t cover installing Ubuntu here, but feel free to ask if you need help!

Okay, after installing Ubuntu:

  • Open a terminal window. You can do this by pressing Ctrl + Alt + T on your keyboard.
  • Navigate to the /usr/src directory. Type the following command in the terminal and press Enter:
    src cd /usr/src/
  • Install nano and subversion, and yes so what?😃 Just copy and paste the command:
    apt install subversion nano
  • Download Asterisk (this link may be updated)
curl -O https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-16.30.1.tar.gz
  • Extract the tar file using the command
    tar xvf asterisk-16.30.1.tar.gz
  • Navigate to the asterisk-16.30.1 directory.
    cd asterisk-16.30.1
  • Run the Script script _get_mp3source.sh
    script _get_mp3source.sh contrib/scripts/get_mp3_source.sh
  • Update the repos
    apt update
  • Install the prerequisites with the command
    contrib/scripts/install_prereq install
  • Start the configuration
    ./configure
  • Configure menuselect
    make menuselect
  • Compile Asterisk
    make
  • Install Asterisk
    make install
  • Configure examples
    make samples
  • Configure
    make config
  • Update the OS shared library
    ldconfig

Ok last steps, permissions

  • Add new group called asterisk
    groupadd asterisk
  • Add new user called asterisk
    useradd -r -d /var/lib/asterisk -g asterisk asterisk
  • Add user asterisk to audio and dialout groups
    usermod -aG audio,dialout asterisk
  • Change directory owner to asterisk group and asterisk user
    chown -R asterisk.asterisk /etc/asterisk
  • Change the owner of the directories for the asterisk group and asterisk user
chown -R asterisk.asterisk /var/{lib,log,spool}/asterisk
  • Edit the asterisk file
    nano /etc/default/asterisk
  • Find these two lines and remove the comment
    AST_USER="asterisk"
    AST_GROUP="asterisk"

Now you have your Asterisk PBX installed on your Ubuntu, it’s time to play 😃

Some more settings

  • Enable automatic
    start systemctl enable asterisk
  • Start Asterisk
    systemctl start asterisk
  • Log into the asterisk console
    asterisk -rvvvvvvcfg

Leave a Reply

Your email address will not be published. Required fields are marked *

en_US