Aastra XML scripts on Asterisk 1.6


Aastra SIP phoneWith the recent introduction of patch 3 for Aastra XML scripts 2.2.1 we now have scripts that work on Asterisk 1.6 as well as 1.4.  The installation procedure has also been greatly simplified.  There are at least two bugs in patch 3 that I am sure Aastra will eventually fix but for now I will provide the information to fix it here.

There is a choice of RPM or source based installation.  The RPM based is primarily designed for Trixbox and Elastix.  The source based for PBX-in-a-Flash.  This procedure will describe the source based installation.  Note that Aastra XML scripts are only compatible with 32bit Linux installations according to Aastra.  I have not tested and do not know if they will work with 64 bit installations.

The RPM version specifically for Elastix disables ssl for Aastra scripts which Elastix otherwise uses for browser access by default.

It is assumed you have already installed Asterisk, Asterisk addons, and FreePBX using a procedure such as the one on this site.  You should also have the following FreePBX modules installed.

  • Call Forward
  • Conferences
  • DND
  • Day Night Mode
  • Paging and Intercom
  • Parking Lot

Install Aastra XML v2.2.1 scripts:

First, make sure you do not have avahi installed which is not compatible with mDNS.
yum remove avahi

Now perform the installation procedure
cd /usr/src
wget http://pbxinaflash.net/source/aastra-xml-2.2.1/install-aastra-xml.x.gz
gunzip install-aastra-xml.x.gz
chmod +x install-aastra-xml.x

A server reboot is now needed.

Now create the aastra.cfg file in /tftpboot in order to launch the self-configuration process.

Now you should enable all the FreePBX modules, as described above, to use the features in the XML scripts BEFORE you connect and self configure the Aastra phones.  You also need to add the extensions before you self configure the phones which is where you assign the extension numbers.  Note that the password used is voicemail password, not extension password.  So you need to have voicemail enabled for this configuration step.

Also, you need to decide which mode you will be using.  Either 'extension' or 'deviceanduser'.  The default is 'extension'.  You should consult the Aastra XML documentation for those details.

Install patch 3 for Asterisk 1.6

Modify "/etc/asterisk/manager.conf" only with Asterisk 1.6
Add 'originate' as a read/write to the [admin] entry which is the manager user used by freePBX and the Aastra XML scripts, the file should look like this:
secret =amp111

Modify /etc/asterisk/voicemail.conf
As the visual voicemail is modifying the voicemail content outside of the voicemail TUI, you need to have "pollmailboxes=yes" in the [general] section.  The file should look something like this:

#include vm_general.inc
#include vm_email.inc

600 => 600,aastra600,,,attach=no|saycid=no|envelope=no|delete=no
601 => 601,xlite601,,,attach=no|saycid=no|envelope=no|delete=no

Install the patch 3
Patch 1 and Patch 2 are included in Patch 3 so Patch 3 can be installed whatever the status of the installed scripts is.

On the console as root:
cd /usr/src
chmod +x aastra-xml-scripts-2.2.1-patch-3.run

You need to reboot the server in order to restart the daemons.
NOTE: the daemons are started via lines added to /etc/rc.d/rc.local

Fix to patch 3 for Asterisk 1.6

This does not apply to Trixbox CE v2.8.0.2, and versions of Asterisk before approximately  This only applies to changes added in patch 3.  This fixes 2 problems.  The first fix corrects a problem with CallerID not showing up in the visual parking lot.  The second fix corrects a problem with the Parking lot splash screen not showing up when a call is first parked.

function Aastra_get_parked_calls_Asterisk()

function Aastra_check_park_Asterisk($user,$number)


Perhaps it was a bug in the version of Asterisk 1.6 that Trixbox currently uses and Aastra tested on which has since been fixed?!

Parked calls show the “name” part of the CID and not the “number” part which I think is by design.  Probably would not be too difficult to modify the code a bit to get it to show the “number” part as well.