📜 ⬆️ ⬇️

Asterisk - Enterprise Computer Telephony System

I want to talk about the free solution for computer telephony from the company Digium . Asterisk is an ATC created by hackers (in the original sense of the word), or rather, it is a super convergent computer telephony platform distributed under the GNU GPL license, originally developed by Mark Spenser, who later became the president and technical director of Digium. Thanks to the commercial support of His company and the GNU GPL license, Asterisk is actively developing and supported by thousands of people from all over the world.


Asterisk supports


Protocols


Audio codecs

TitleTransmission rate, KbpsThe need for a license
G.71164Need not
G.72616, 24, 32 or 40Need not
G.729AeightNeed (not needed for transit)
GSM13Need not
iLBC13.3 (frames at 30 ms) or 15.2 (frames at 20 ms)Need not
SpeexVariable between 2.15 and 22.4Need not
G.723.16.4 Kbps (frame has a size of 189 bits, supplemented to 24 bytes) and 5.3 Kbps (frame has a size of 158 bits, supplemented to 20 bytes). Mode of operation may change dynamically from frame to frameNeed (not needed for transit)
MP3


Video codecs


Asterisk can work with both analog lines (FXO / FXS modules) and digital (ISDN BRI and PRI - T1 / E1 streams). With the help of computer boards (the most famous manufacturers of which are Digium, Sangoma, OpenVox, Rhino, AudioCodes) Asterisk can be connected to high-throughput T1 / E1 lines, which allow you to work with dozens and hundreds of telephone lines. According to Wikipedia
')
Asterisk works with OKS-7 (Common Channel Signaling No. 7, in Europe known as SS7 - Signaling System No. 7) is a set of signaling telephone protocols for organizing a multiservice (intelligent) network.

Presentation on working with SS7 with astricon.net By Matthew Fredrickson (Matthew Fredrickson) SS7 and its support in Asterisk - pdf


Important points to choose

Performance Asterisk Systems

Experienced data on system performance are presented on the forum [ ru ] and the original text [ en ].

The main recommendations are 1
PurposeNumber of channelsMin configuration
Amateur systemno more than 5400 MHz, 256 MB RAM
SOHO systemfrom 5 to 101 GHz, 512 MB RAM
Small business systemup to 253 GHz, 1 GB RAM
Medium or large systemmore than 252 CPUs or multiple servers in a distributed architecture

OS


Asterisk - can work on almost any Linux platform plus some other OS, such as Solaris, BSD, MacOS X and there is even a project Asterisk for Win32 . Regarding the choice of OS for Asterisk, I don’t want to develop a holivar and I propose to choose you yourself, without interfering with reading the thread form dedicated to this issue. In conclusion, I will say that I myself use CentOS - a popular distribution kit used with Asterisk (compiled from raw RedHat) version 5.2.
Detailed installation guide for CentOS 5.2 from the Linuxoid blog.
I recommend not to install X because they will compete with Asterisk for resources.

Install and configure Asterisk


Asterisk in the basic configuration includes three main packages available for download on the official website :
links to 32-bit versions, but 64 – bit are also available.

If you plan to use only VoIP, then Asterisk is enough, but it is recommended to install all the packages.

Additionally, you can install


Required Linux Packages

In my case, everything was already contained in the system, I just updated the kernel (even if it seems scary to no one).

Small retreat


Against the above, there is also AsteriskNOW software available Beta 1.5 - it is a specialized Linux distribution that already includes Asterisk with all the necessary software, plus a web-based GUI. This distribution is also distributed under the GNU GPL license and is free for download 32-bit and 64-bit .
Screenshots can be viewed on the official website .

The Trixbox distribution kit enjoys special popularity and love - it is a software package based on CentOS and Asterisk, whose main task is to create an IP telephony server in the shortest time possible.
Currently version 2.6.2 is available. Installation steps can be spied on the site voiceip.com.ua .

The Elastix distribution kit from PaloSanto Solutions does not bypass Trixbox Community Edition in terms of functionality. Distributed under the GNU GPL. The basis of the Elastix was CentOS 5 with a kernel 2.6.18. The basis of the VoIP system is Asterisk 1.4.18, the developers supplemented it with proprietary utilities and third-party modules. Recycled A2Billing was used as a billing system. The delivery also includes an Openfire 3.4.2 server that provides XMPP / Jabber messaging. Also included in the distribution kit are two CRM (Customer Relationship Management) - SugarCRM and VTigerCRM
Review and installation can be found in the article Linuxoid .

Continue


I will not upload an article with general questions of installing and configuring Asterisk, all the more so as there are some wonderful articles on the web that tell in detail about each of the steps. Despite the fact that the articles were written 3 - 4 years ago, believe me, they do not lose their relevance, I don’t argue, the versions have changed from 1.2 to 1.6, even the name of the telephone driver has changed and the functionality has significantly expanded, but you shouldn’t be scared.

My recommendation is MUST READ:


Articles about Asterisk in the journal "System Administrator"
Posted by Mikhail Platov :

Note: articles use utilities zaptel, which changed its name to DAHDI
ztcfg -> dahdi_cfg
ztmonitor -> dahdi_monitor
ztscan -> dahdi_scan
ztspeed -> dahdi_speed
zttest -> dahdi_test
zttool -> dahdi_tool
zapconf -> dahdi_genconf formerly known as genzaptelconf)

And the ways have changed:
  • The system configuration file has been renamed from /etc/zaptel.conf to /etc/dahdi/system.conf
  • The dahdi_cfg utility can now be used to select an echo suppressor for each channel or group of channels based on settings from the configuration file: system.conf; The full list of changes on the svn-trunk of developers or in Russian on the website voip.rus.net .

Asterisk: we organize automatic distribution of incoming calls - the issues of organizing a call processing queue, so necessary in the services that work with clients, are considered. Author Sergey Yaremchuk

Mark Spencer: “This Asterisk attracts users to Linux, and not vice versa!”
Interview with Mark Spencer 2006, text: Dmitry Shurupov , photo: Jon Hall

Asterisk security issues are discussed in the article Safe Asterisk by Maxim Litnitsky - PLEASE REMOVE THIS GREAT ATTENTION

Unfortunately, articles for various reasons did not include important aspects of Asterisk, so I will try to draw your attention to them.

AGI, EAGI, DeadAGI and FastAGI


Asterisk Gateway Interface (AGI) is a gateway interface through which external programs (scripts) can influence the logic of the Asterisk dialplan. AGI scripts (similar to CGI for http servers) can be written in almost any programming language, interact with Asterisk using the descriptors of the files STDIN (standard input), STDOUT (standard output) and STDERR (standard error) and implement advanced database logic and external resources.
EAGI is AGI, which, besides everything, allows the script to read the incoming audio stream, for example, for speech recognition needs.
DeadAGI is an AGI which is correctly executed for a “dead” - disconnected channel.
FastAGI - allows you to run a remote AGI script via a TCP socket - this reduces the system load and transfers it to another server, for example, many Asterisk servers, can use single AGI scripts.

The most popular programming languages ​​for AGI are Perl, Python and PHP.
I can only say that for these and other programming languages ​​there are “wrappers” - frameworks that allow you to abstract AGI from request-response logic and program at a higher level of abstraction.

AMI


Asterisk Manager Interface (AMI) is a software interface that allows you to connect to Asterisk via TCP / IP and fully control Asterisk, used to communicate with CRM-systems .

Ajam


Aynchronous Javascript and XML (AJAM) - available from Asterisk version 1.4, provides a web browser or any other application to contact AMI via HTTP. It is used in the web – based GUI for Asterisk plus that it uses the Prototype library, which saves developers from many cross-browser issues.

Integration with Databases


The important point is the ability of Asterisk to store its configuration and state in the database. This key feature allows you to build stunning distributed telephone systems.

Asterisk real-time architecture

This method of storing configuration files is not in the file system, but in the tables of the Database. There are two types of real-time architectures:Detailed material [ ru ] and [ en - original ].

Storage of CDR files in the Database


Call Detail Records (CDR) - a record file of call parameters passed through the system. Asterisk allows you to store CDR files in:An important part of the dialplan that provides it with power and dynamism is func_odbc , it allows you to create and use in the dialplan functions of extracting and using information from the database.

IVR


Interactive Voice Response (IVR) is already an integral part of any platform and business engaged in customer service. The cost of commercial IVR systems (Avaya, Cisco, Genesys, Nortel or Dialogic) is sufficient, high, and Asterisk is simply created for this.
Unfortunately, there is no Russian female voice for Asterisk (free). After the installation, Asterisk speaks to us in Allison Smith’s voice - about 300 promts, plus another 600 in the asterisk – sounds supplement.

Text translation of voice proms is available for Asterisk versions 1.4, 1.6As well as a male Russian voice from romik_g for Asterisk 1.4.

The resource ivrvoice.ru can be downloaded and used for any peaceful purposes, including business, Russian promty for Asterisk.

If you decide to record your own proms, the main requirement is to normalize the records to -3 dB with pauses at the beginning and end of the recording. To convert an audio file, use the SoX (Sound eXchange) utility.

However, IVR systems are “not only valuable mech” and DTMF , but also Automatic Speech Recognition (ASR) and Text – to – speech (TTS) systems for speech playback engines. True, with the Russian here is still tight.
But know should:I can not say about, a wonderful example of the use of all this - ZoIP from Simon Ditner (Simon Ditner). This is the port of the popular Zork game with Asterisk full speech support.

Video and Asterisk


Links to working with videos in Asterisk [ ru ] and [ en - original ].

An interesting resource is sip.fontventa.com , a pity that the last update was January 19, 2007, containing the source code of the library for working with the H.324 protocol used in UMTS 3G video calls.

Dundi


Distributed Universal Number Discovery (DUNDi) , created by Mark Spencer - “this is a peer-to-peer system for searching Internet gateways for telephony services, is completely distributed and has no centralized service at all”. In some ways, this is the routing protocol for VoIP.
DUNDi - allows you to request an alternative VoIP route to an extension number or PSTN telephone number from peers. DUNDi can be used both in the local network - to simplify the management of extensions in Asterisk systems of a large company, and in the global network, but here you need to sign the General Peering Agreement (GPA) for access, you can also find it in the subfolder of the source code doc /. The GPA is legally binding to protect network participants from people abusing the protocol.

For study I recommend the article How to use DUNDi to distribute calls among the DUNDi Peering Network .

Details are topics for future articles.



Books


1 [en] Asterisk: The Future of Telephony , Authors: Jim Van Meggelen, Jared Smith, Leif Madsen
or books.google.com
[ru] unfortunately, the book was published not so long ago, but all the same and THANK YOU VERY MUCH for it!
You can order on books.ru in 2 versions:Asterisk: The Future of Telephony Book Free Translation
(Maxim, so that we do without you;)

[found ru at the last moment] Asterisk: the future of telephony - DRAFT-copy

[en] trixbox Without Tears The Dumb-Me guide - free for download

Video


[en] Free Video Tutorials for trixbox FreePBX and Asterisk Systems

Informational resources


Forums (small list)


Shops (small list)



Companies offering Asterisk - solutions


For those who are interested in certification and licensing of telecommunication platforms, I ask to the Asterisk forum and certification , where i1 is your humble servant.

Official mailing lists for those who are interested in Asterisk.

Asterisk is FUN !!!

Source: https://habr.com/ru/post/54751/


All Articles