Asterisk D500 LAN Single Server Installation

 


Transcoding Package

 

Download the Latest Sangoma Media Transcoding Release:  
---> sng-tc-linux-1.3.8.i686.tgz                   (2016-01-07)             ChangeLog
---> sng-tc-linux-1.3.8.x86_64.tgz             (2016-01-07)

*A manual firmware upgrade is required to use the above 1.2.x releases for cards 
purchased before November 10th, 2010 
--> Firmware upgrade Procedure 

 


 Hardware Installation

  1. Mount your transcoder, then boot the server
    -> choose a server in your network and install the D500 in the PCI Express slot

    *Note: -> The PCI Express slot will server to provide power to the D500, where RTP traffic will flow through the LAN connection
               -> An extra Ethernet interface may be brought up if your server has a Broadcom tg3 driver installed.  Run "ifconfig" to verify.  Disregard this extra interface (bring it down if necessary) as this interface is only used when using PCI Express Single Server installation. 

    ---------

  2. Plug the Ethernet cable into your transcoder to attach to your network


Transcoding package installation

  1. Download and Install the transcoding package on a server where you have installed the D500
    * Note: If you are doing this on an Official FreePBX Distro machine, please run yum install asterisk<ver>-devel libxml2-devel first 

    -> wget <URL of Package>
    -> tar xfz sng-tc-<ver>-<arch>.tgz
    -> cd sng-tc-<arch>-<ver>
    -> make
    -> make install

    The D500 transcoder will be detected through the server's main LAN Ethernet interface, typically Eth0
    --------

  2. Firmware Update

    To check if the firmware on the transcoder requires updating run the firmware update utility

    --> Run: sngtc_tool –dev ethX –firmware  (replace ‘X’ with the interface of main LAN, such as Eth0)
         -> a broadcast message will be sent out Eth0 to any Sangoma transcoders on the network and will detect the D500 inside this server as it is connected to same network
    --> If the FROM and TO version are the same you are up to date so cancel the update; if the versions are different please update.
    --> If the update fails insure the RJ45 is properly connected to the D500 and is illuminated Green colour.  Also verify your firewall/security is not blocking any communication
    * Note sngtc_server must NOT be running during the update; sngtc_server_ctrl stop will stop the server if it is running.


Transcoding Module Installation and Configuration

*Note: This step assumes Asterisk is on the same server as the server hosting the D500. If Asterisk only exists on other server(s) please go to -> D500 LAN distributed codec module configuration

The steps below will install the Asterisk trancoding module, so please insure you have the Asterisk headers already installed (ie: /usr/include/asterisk/)

  1. cd sng-tc-<arch>-<ver>

  2. make asterisk

  3. make install

  4. [ -d /usr/lib64/asterisk/modules ] && cp /usr/lib/asterisk/modules/codec_sangoma.so /usr/lib64/asterisk/modules/codec_sangoma.so

The Asterisk Codec Module is now installed and requires configuration via the following steps. This step will auto detect the D500 transcoder located on the server (through the LAN only) and will create Asterisk codec module and sngtc_server configuration files. These files instruct Asterisk that in order to reach the transcoding resource(s) it must communicate over the LAN to the sngtc_server, which serves as the gateway to the D500.  All transcoding modules on the D500 will all be treated as one big transcoding resource.  There is no option to manually control individual transcoding modules onboard the D500.  Auto detection is performed through the main LAN.

 --> sngtc_cfg --server --asterisk 
or
--> sngtc_cfg --server --asterisk --astdir=/etc/asterisk

If multiple interfaces have detected the D500 transcoder, then you may have multiple LAN connections to this server, or the PCI Express Ethernet interface (tg3) has detected the D500.  Select configuration for only the interface of the main LAN (and only one)

 Asterisk Sangoma Transcoding Config file:         
/etc/asterisk/sangoma_codec.conf

Transcoder Hardware Configuration file:
/etc/sngtc/sngtc_server.conf

If you have more than one one module (480) on the D500  "sngtc_server.conf" will only list information of the first module detected (i.e IP address).  The rest of the D500 module configurations are hidden and will use consecutive IP addresses. (i.e first D500 module- 10.1.1.150, second D500 module- 10.1.1.151, third D500 module- 10.1.1.152...)

Asterisk now needs to be configured to load the "codec_sangoma" module each time it starts. 

--> vi /etc/asterisk/modules.conf

--> Add the line "load => codec_sangoma.so" into the file; save and quit

By default G729 is the only codec registered with Asterisk.  If you require additional codecs please go to the following wiki page to configure them --> Asterisk codec configuration.


Operation

  • The sngtc_server is at the heart of the transcoding environment. It interfaces the transcoder hardware and codec module (the codec module, in asterisk, communicates with the sngtc_server in order to pass information to/from transcoder). It controls all Sangoma transcoders that are located on the same computer (this means you cannot have multiple sngtc_servers controlling/communicating with specific transcoders).   

    The sngtc_server needs to be started before transcoding can be done. Below is the usage of the sngtc_server_ctrl command. 

*Note by default this script is started on system boot. 

--> sngtc_server_ctrl (start|stop|restart)

 

  • To enable Asterisk to connect to the sngtc_server and then to the transcoder you will need the have the module codec_sangoma loaded. To load the module run the command below. 

*Note the step above shows you how to auto load this on Asterisk start.

 Asterisk CLI> module load codec_sangoma.so

WARNING: There is a bug in Asterisk that may lead to crashes when loading codecs if there are 2 different modules providing the same translation paths. See this bug report for more information: http://issues.asterisk.org/view.php?id=17092. You can also read the sample configuration comments in sng-tc-<version>/codec/asterisk/sangoma_codec.conf.sample to learn more about work-arounds in case you face the problem.

 

  • To status the codec_sangoma module use the commands below. 

Asterisk CLI> sangoma show translators(Shows codecs registered by codec_sangoma)  

Asterisk CLI> sangoma show transcoding sessions(Shows active transcoding sessions) 

Asterisk CLI> sangoma show rtp statistics(Shows real time RTP stats including dropped packets)

 

<- back to Asterisk D500 main menu

 

Return to Documentation Home I Return to Sangoma Support