SMG-SS7 Demo

    demo-network.jpg

    The SMG-SS7 Demo allows a user to test Sangoma's SMG-SS7 solution in their lab for evaluation purposes.  This wiki page will guide the user through setting up 2 systems back to back in a lab.

     

    INSTALLATION & CONFIGURATION

    1. Physical Installation
    2. Install Wanpipe drivers
    3. Install SMG-SS7 package
    4. Install demo licenses and SMG-SS7 Configuration
    5. Wanpipe Configuration
    6. Asterisk Configuration

    OPERATION

    1. Starting SMG-SS7

      # service sangoma-media-gateway start
    2. Monitoring SMG-SS7
    3. Stopping SMG-SS7

      # service sangoma-media-gateway stop

    Physical Installation

     

    The SMG-SS7 Demo requires that 2 servers be connected back to back with 1 port using a Sangoma A101, A102, A104 or A108.

    After physically installing the the A10X cards in your servers you need to create a T1/E1 cross over cable. 

    A T1/E1 cross-over cable pinout: http://wiki.sangoma.com/Pinouts#A101/2/4%20Cross

     


    Install Wanpipe Drivers

    1. Download wanpipe device driver
      -> Latest 3.5 Release: wanpipe-current.tgz
      -> Check Linux Download Page for more info
      --
    2. Untar the wanpipe package
      -> tar xfz wanpipe-current.tgz
      -> cd wanpipe-<version>

    3. Build the wanpipe driver for SMG and install it
      -> make smg
      -> make install 

      Prerequisite to this step is a distro development and linux-header package.
      Check out the wanpipe driver pre-requisite page for more info.
      If this step fails one of the pre-requisistes is not met: Please contact Sangoma Support

    4. Check that driver installed properly
      -> wanrouter hwprobe

      If this step fails hw could be defective or driver did not install properly: Please contact: Sangoma Support

     


    Install SMG-SS7 Package

     

    NOTE: At this time SMG-SS7 is not configurable via the web gui, configuration is done manually!

    The latest SMG release can be installed from a tarball file or an RPM package for CentOS 5.

     

    Installing the RPM through yum

    1. Install Sangoma RPM repository
      -> rpm -ivh http://rpm.sangoma.com/sangoma_repository-0.0.1-Linux.rpm

    2. Install SMG, this will install the RPM and also start the Web GUI automatically
      -> yum -y install sangoma-media-gateway

    Installing through the tarball

    1. Download SMG Latest Package
      -> sangoma-media-gateway-linux-3.2.5.i686.tar.gz
      -> sangoma-media-gateway-linux-3.2.5.x86_64.tar.gz 

    2. Untar the SMG Package
      -> tar xfz sangoma-media-gateway-<ver>.tgz
      -> cd sangoma-media-gateway-<ver>

    3. Install the SMG Gateway
      -> make install
      or
      -> make install DESTDIR=<absolute path to install directory>

      By default SMG package installs in /usr/local/smg directory.

    4. Install SMG boot startup scripts  (optional)
      -> make boot

    5. Start SMG Web GUI
      -> service smg-webgui start

      The web service will start on port: 8888

    6. At this point we are ready to configure and start the SMG gateway from the Web GUI
      Using your browser open the port: 8888 on your SMG gateway machine.

      Default usernname/password: admin/admin

      -> http://localhost:8888

      *Note: click Here for instruction if you are configuring from a remote system to be able to access the Web GUI
       


    Linux Environment Configuration

    1. Firewall
      If you have iptables enabled 
      --> to check run:  iptables -nL

      Make sure to allow:
      --> SIP port:     5062                 (default SMG SIP port)
      --> RTP ports:  21000 to 31000 (default SMG RTP ports)
      --> HTTP port:  8888                (default SMG GUI port)

      On redhat distros one can update /etc/sysconfig/iptables
      --> /etc/init.d/iptables [start|stop|restart] 


     

     


    Install Demo Licenses and SMG-SS7 Configuration

     

    On Server 0 :

    1. Download the SMG-SS7-Demo0 package:
      # wget ftp://ftp.sangoma.com/linux/smg/demo/smg-ss7-demo0.tgz
    2. Untar the demo package and enter the new directory:
      # tar xfz smg-ss7-demo0.tgz
      # cd smg-ss7demo0
    3. Install the demo license and SMG-SS7 configuration files:
      # make install

     

    On Server 1 :

    1. Download the SMG-SS7-Demo1 package:
      # wget ftp://ftp.sangoma.com/linux/smg/demo/smg-ss7-demo1.tgz
    2. Untar the demo package and enter the new directory:
      # tar xfz smg-ss7-demo1.tgz
      # cd smg-ss7demo1
    3. Install the demo license and SMG-SS7 configuration files:
      # make install

     


    Wanpipe Configuration

     

    1. Use "wancfg_tdmapi" to create a basic configuration file for 1 port.
      • Select "E1" as the media type
      • By default wancfg_tdmapi will set the port to CRC4 framing and HDB3 coding but you can also select NCRC4 framing
      • On server 0 select MASTER clocking, on Server 1 select NORMAL clocking
      • SS7 uses CCS signaling 
      • Set data channel "1" to hardware HDLC framing
      • SMG-SS7 does not support hardware DTMF at this time, if you have a HWEC module please set this option to "NO"
      • If you have more then one port on your card please set the other ports to "Unused"
    2. Open wanpipe1.conf and add "HDLC_REPEAT = YES" to the interface section
      # vi /etc/wanpipe/wanpipe1.conf

      [w1g1]
      ACTIVE_CH      = ALL
      TDMV_HWEC   = NO
      MTU                = 80
      HDLC_REPEAT = YES

     


    Asterisk Configuration

    The following Asterisk configuration files needed to be modified to support SMG:

     


    SMG sip.conf Configuration

     

    SMG expects the application server to register a SIP connection so that SMG knows where to send incoming call requests from the PSTN to.

    Also, to make outbound dialing easier one should add a profile for SMG to the sip.conf configuration.

     

    Add the following line in you "sip.conf" to have asterisk register with SMG:

    [general]


    register => sangoma:sangoma@<ip address of SMG server>:5062

     

    To make outbound dialing as easy as possible add the following SIP profile to "sip.conf"

    [authentication]


    [smg]
    type=peer
    host=<ip address of SMG server>
    port=5062
    qualify=yes
    context=from-smg

     


    SMG extensions.conf Sample

     

    [from-smg]
    exten => _X.,1, set(span=${SIP_HEADER(X-freetdm-SpanName)})
    exten => _X.,n,noop(SMG -> incoming call on span=${span})
    exten => _X.,n,answer()
    exten => _X.,n,playback(demo-congrats)
    exten => _X.,n,hangup()

    [to-smg]
    exten => _X.,1, dial(sip/${EXTEN}-g=g1-h=a@smg)    ; dial to SMG trunk group named "g1" and use ascending hunting to find a free channel

     


    Using SMG with Asterisk read() Application

     

    If you are planning to use the Asterisk read() application to receive DTMF from a PSTN line you need to switch SMG to use SIP INFO messages for DTMF events (RFC-2976) rather then the default RFC-2833 method.

    1. Un-comment the following from /usr/local/smg/conf/sip_profiles/internal.xml

      <param name="dtmf-type" value="info"/>
    2. Restart the SMG using "service sangoma-media-gateway restart"

     

    By default SMG uses RFC2833 to transmit DTMF events/tones to the application server and the current the architecture of SMG is that such incoming RTP frames are used to trigger the transmission of RFC2833 events.

    When the Asterisk read() application is in the process of "reading" dtmf digits it does not send any RTP frames to SMG...which in turns causes SMG to not process new DTMF events.  Switching to SIP info message for DTMF will resolve this issue

     


     

    -