Sunday, January 29, 2012

Asterisk Server

Asterisk is basically a linux based application/software being used for the implementation of a telephone private branch exchange (PBX). Its name comes from the asterisk symbol, “*”. Mark Spencer in 1999 from Digium was the creater of Asterisk. Like any PBX, it allows attached telephones to make calls to one another, and to connect to other telephone services including the public switched telephone network (PSTN) and Voice over Internet Protocol (VoIP) services.

Asterisk is released under a dual license model, using the GNU General Public License (GPL) as a free software license and a proprietary software license to permit licensees to distribute proprietary, unpublished system components.

Originally designed for Linux, Asterisk also runs on a variety of different operating systems including NetBSD, OpenBSD, FreeBSD, Mac OS X, and Solaris. A port to Microsoft Windows is known as AsteriskWin32.[1] Asterisk is especially small enough to run in an embedded environment like Customer-premises equipment-hardware running OpenWrt.

Features

Asterisk was one of the first open source PBX software packages but later on some similar open source softwares were annouced e.g. trixbox, which was initally named as Asterisk@Home. The Asterisk software includes many features available in proprietary PBX systems: voice mail, conference calling, interactive voice response (phone menus), and automatic call distribution. Users can create new functionality by writing dial plan scripts in several of Asterisk's own extensions languages, by adding custom loadable modules written in C, or by implementing Asterisk Gateway Interface (AGI) programs using any programming language capable of communicating via the standard streams system (stdin and stdout) or by network TCP sockets.

To attach traditional analog telephones to an Asterisk installation, or to connect to PSTN trunk lines, the server must be fitted with special hardware. Digium and a number of other firms sell PCI cards to attach telephones, telephone lines, T1 and E1 lines, and other analog and digital phone services to a server.

Asterisk supports a wide range of video and Voice over IP protocols, including the Session Initiation Protocol (SIP), the Media Gateway Control Protocol (MGCP), and H.323. Asterisk can interoperate with most SIP telephones, acting both as registrar and as a gateway between IP phones and the PSTN. The Inter-Asterisk eXchange (IAX2), a native protocol in Asterisk provides efficient trunking of calls among Asterisk PBXes, in addition to distributed configuration logic, and call completion to VoIP service providers who support it. Some telephones support the IAX2 protocol directly (see Comparison of VoIP software for examples).

By supporting a mix of traditional and VoIP telephony services, Asterisk allows deployers to build new telephone systems, or gradually migrate existing systems to new technologies. Some sites are using Asterisk servers to replace proprietary PBXes; others to provide additional features (such as voice mail or voice response menus, or virtual call shops) or to reduce costs by carrying long-distance calls over the Internet (toll bypass).

In addition to VoIP protocols, Asterisk supports many traditional circuit-switching protocols such as ISDN and SS7. This requires appropriate hardware interface cards supporting such protocols, marketed by third-party vendors. Each protocol requires the installation of software modules such as Zaptel, Libpri, Libss7, chanss7, wanpipe and others. With these features, Asterisk provides a wide spectrum of communications options.

Configuration
To configure Asterisk into an operational system, the administrator must:
  • create channels/devices that allow Asterisk to communicate through a voice path that uses that channel and/or devices. These can be VoIP, or TDM, or analogue telephony devices.
  • compose a dial plan, written in the Asterisk control language, to express the algorithm or control flow Asterisk uses to respond when calls are presented to it over these channels. Asterisk can be used for many specific applications and a customized dial plan has to be created specifically for each purpose, such as the functionality of a PBX. Asterisk is thus a 'construction kit' for building PBXs, rather than a PBX in itself, as is commonly thought.
Asterisk is configured by a set of configuration text files. One of these, extensions.conf, contains the operational flow logic of Asterisk. A native scripting language is used to define the elements of process control, namely variables, procedural macros, contexts, extensions, and actions. A context groups all the valid destination numbering codes which apply to a set of channels on which incoming (to Asterisk) calls can be presented. These numbering codes, called “extensions” (even though they often are not) are the starting points for the scripts which instruct Asterisk how to process calls made to those numbers within that context.

To clarify: contexts define the source of a call, and extensions define its destination.

Because each channel declares a context, the dial plan restricts and permits which extensions and facilities its device may access. Extensions consist of possibly multiple steps of execution, each performing either logical operations, directing program flow, or executing one of the many included applications available in Asterisk.

Applications are loadable modules that perform specialized operations, such as dial a telephone number or another internal extension (app_dial), perform conferencing services (app_meetme), or handle the operations of voice mail (app_voicemail). The plethora of applications available provide a unique capability and tool set to formulate algorithms that can perform a large array of different, customized telephony scenarios. Applications control the Asterisk core functions through a set of internal operation primitives, that are organized in an extensible fashion through a modular architecture and application programming interfaces (APIs).

Programming an Asterisk system can also be accomplished via separate, external applications using the Asterisk Gateway Interface. The Asterisk Gateway Interface (AGI) is a software interface and communications protocol for inter-process communication with Asterisk. In this, external, user-written programs, are launched from the Asterisk dial plan via pipes to control telephony operations on its associated control and voice channels. It is similar to the CGI feature of web servers in that any language can be used to write the external program which communicates with Asterisk via the standard streams, stdin and stdout.

There are several graphical user interfaces (GUIs) for Asterisk. These interfaces allow administrators to view, edit, and change various aspects of Asterisk via a web interface. As of version 1.8, a GUI labeled “Asterisk-GUI” is being developed alongside Asterisk by Digium. There are other GUIs, such as FreePBX. Other attempts to simplify Asterisk installation have been made, trixbox (formerly Asterisk at home (A@H)) is a popular distribution of Asterisk that includes Asterisk and FreePBX. PBX in a Flash (PIAF) is another such distribution.

Digium has also packaged a variant entitled AsteriskNow, which is a customized Linux installation and includes FreePBX and all ancillary software to provide an "off-the-shelf" PBX, requiring only that the user prepare the requisite dial plans (see above) and connect the necessary hardware. The target market for AsteriskNow is the administrator who wishes to set up a PBX using Asterisk, but who may not have the experience in server configuration to perform the initial setup of a base Asterisk installation.

Internationalization

While initially developed in the United States, Asterisk has become a popular VoIP PBX worldwide because it is freely available under open source licensing, and has a modular, extensible design. The American-English, French and Mexican Spanish female voices along with other new prompts like Australian-English [1] for the Interactive voice response and voice mail features of Asterisk are frequently updated with submissions from developers in many different languages and dialects. Additionally, voice sets are offered for commercial sale in different languages, dialects and genders.

 Development

Major Releases:

1.0 - Released on 23 September 2004[5]
1.2 - Released on 15 November 2005[6]
1.4 - Released on 26 December 2006[7]
1.6 - Released on 2 October 2008[8]
1.8 - Released on 21 October 2010[9]
10.0 - Released on 15 December 2011[10]

Derived products

Asterisk is a core component in many "PABX in a box" commercial products and Open Source projects. Some of the commercial products are hardware and software bundles, for which the manufacturer supports and releases the software as Open Source. Examples are TrixBox and Elastix.

Asterisk is also included in the LinuxMCE home entertainment/automation system