ServiceDesk Plus

    Asterisk CTI settings

    SupportCenter Plus provides Computer Telephony Integration (CTI), a technology that allows computer systems to interact with telephones. CTI enables screen popping in SupportCenter Plus, where upon receiving calls, details such as, caller's Name and Contact Number, pop up on the screen. This can be viewed by Support Reps, when they log into the application.

    This document walks you through the entire process of installing and configuring Asterisk PBX, tested with latest version Asterisk 13.7.2 and below.

    The following topics are discussed in this document:

    1. Installing Asterisk

    Asterisk is predominantly for Linux machines. Anyhow, it works for CentOS and Ubuntu, as well. Follow the steps one by one to install Asterisk in your Linux machine.

        a) Go to "/usr/src/" directory and download the required version of Asterisk from the website: http://www.asterisk.org/downloads/asterisk/all-asterisk-versions.

         Examplewget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-13-current.tar.gz

        b) Extract the downloaded tar file as follows:       

                 tar zxvf asterisk*

        c) Navigate to the folder created after extracting the tar file, as mentioned below:

                 cd /usr/src/asterisk*

        d) Execute the following command:

                 ./configure && make menuselect && make && make install && make samples && make config

        e) Navigate to "/etc/asterisk". Check if all the configuration files (.conf files) are available there.

    Now, Asterisk is successfully installed and the server has started.

    Refer the website http://www.voip-info.org/wiki/view/Asterisk+Step-by-step+Installation for more details. 

    2. Configuring the Asterisk Server

    Three files located in /etc/asterisk/ have to be modified as follows:

    a) manager.conf

    Asterisk can be connected to Asterisk Manager Interface (AMI) via a Manager. The manager.conf is the configuration file that holds information such as, the list of users allowed to connect to the AMI, their secrets (passwords), the IP's from which they can connect, their privileges, etc.

    Following is a simple sample configuration:

    1. [general]                       ; the name of the main default context - it must not be changed 
    2. enabled = yes                   ; By default is set to "no". Must be set it to "yes" in order for the AMI to work
    3. port = 5038                     ; The port to which the AMI will listen
    4. bindaddr = 0.0.0.0            ; This binds the AMI to all the IPs of the server  (0.0.0.0 binds to all)
    5. [manager_username]      ; The username to identify when connecting to the AMI at log on
    6. secret = manager_pwd      ; The password to enter at log on
    7. permit=0.0.0.0/0.0.0.0     ; The IPs that the user manager_username will be able to connect from (0.0.0.0/0.0.0.0 permits all)
    8. read = system,call,log,verbose,command,agent,user,originate     ; read permissions for the user manager_username 
    9. write = system,call,log,verbose,command,agent,user,originate    ; write permissions for the user manager_username
    Refer the website http://www.voip-info.org/wiki/view/Asterisk+config+manager.conf for more details.
     

    b) sip.conf

    The sip.conf is the SIP (Session Initiation Protocol) channel configuration file that contains the configuration for the SIP channel driver, chan_sip.so. It also has the information and credentials, required for a telephony device to contact and interact with Asterisk. 

          
    1. [general]                        ; Defines the default configuration for every user and peer
    2. context = default            ; The context as defined in extensions.conf for incoming calls
    3. bindport = 5060             ; UDP Port to bind to (SIP standard port is 5060)
    4. bindaddr = 0.0.0.0          ; IP address to bind to (0.0.0.0 binds to all)
    5. srvlookup = yes              ; Enable DNS SRV lookups on outbound calls
    6. [aksunik]                        ; SIP user 1
    7. type = friend                  ; A SIP entity which can place calls and to which Asterisk can place calls (Both incoming and outgoing) 
    8. context = default
    9. username = aksunik      ; This declares that our user will be named 'aksunik'
    10. secret=3294
    11. host = dynamic              ; Enables the telephone to connect from any IP address
    12. callerid= "Aks Unik :)"
    13. [rahulg]                          ; SIP user 2 
    14. type = friend
    15. context = default
    16. username = 3166
    17. secret=3166
    18. host = dynamic
    19. callerid="Rahul Gupta"
    20. [anandb]                       ; SIP user 3
    21. type = friend
    22. username = 3023
    23. secret=3023
    24. context = default
    25. host = dynamic
    26. callerid="Anand Balan"
    

    Refer the website http://www.voip-info.org/wiki/view/Asterisk+config+sip.conf for more details.

    c) extensions.conf

    The configuration file "extensions.conf" contains the "dial plan" of Asterisk and the master plan of control or execution flow for all of its operations. It controls the way by which the incoming and outgoing calls are handled and routed.

       
    1. [general]
    2. autofallthrough=yes
    3. [default]                ; Context name
    4. exten => 3294,1,Dial(SIP/aksunik)           ; Syntax: Dial(protocol/user)
    5. exten => 3166,1,Dial(SIP/rahulg)
    6. exten => 3023,1,Dial(SIP/anandb)
    

    Each execution step in the extension is written in this format:

    exten => 

    exten => 3294,1,Dial(SIP/aksunik) implies that when dialing 3294, Asterisk will Dial the user aksunik through SIP protocol.

    Refer the website http://www.voip-info.org/wiki/view/Asterisk+config+extensions.conf for more details.

    Important: Asterisk server has to be restarted for the configuration changes to take effect. 

    Restarting the Asterisk Server:

    Do the following:

        a) Execute the command asterisk -r to connect to the asterisk CLI.

        b) In CLI, execute the command core stop now to stop the Asterisk server. The server will be stopped and the CLI will be closed.

        c) Execute asterisk start to start the Asterisk server.

    All the configuration file changes will be applied once the server is restarted.

     


    3. Configuring the SIP Softphone

     Ensure that the Asterisk has been installed properly, with the SIP users defined.

    1. SJPhone 

     a) Download and run the installation file from the website: http://www.sjphone.org/sjp.html, to install the SJPhone in your machine. 

     b) Open the SJPhone. Go to "Menu -> Options".

     

    c) Select the Profiles tab and click New to create a new profile. Enter the Asterisk server details and the SIP user credentials.

    d) Give a Profile name and File name for your reference. Choose a Profile type and that must be Call through SIP Proxy. Click OK.

     

    e) The Profile Options dialog box opens up. No changes are required to be done here. 

     

    f) Click the Initialization tab and ensure the check boxes are checked as shown in the below image.

    g) [This is the important step where the Asterisk server settings are provided.] Click the SIP Proxy tab. In Domain/Realm text box, enter the IP Address of the machine, where the Asterisk is running. You can also enter the Proxy settings, if required. Click OK.

    h) The Service: PBX testing dialog box shows up. Give the SIP username (Account) and Password. This is the account information used to login. Click OK

     

    The profile is set now. The Asterisk server details and the SIP user account information have been successfully added. Put the PBX testing profile in use, for the SJPhone to establish a connection to the server. Click OK.

    Upon successful connection establishment, the following registered as message will be shown. The SJPhone will be now able to place and receive calls.

     

    Note: To register with another SIP user account, go to the Profiles tab and click Initialize to provide the required account details.

    2. X-Lite  

    a) Install X-Lite in your machine by downloading and running the relevant installation file from the website: http://www.counterpath.com/x-lite-download.

    b) Open the download X_Lite application and go to "Softphone -> Account Settings".

     

     

    c) Provide the following details:

    • Account name: An account name for you reference.
    • User ID: The username of the SIP User.
    • Domain: The IP address where Asterisk is running.
    • Password: The secret of the respective SIP User.

    Provide Proxy details (if required), under the Domain Proxy section. Click OK.

     

    d) You will see the below window, with your account details enabled in X-Lite.

     

    4. Configuring Telephony Server Settings

    To establish connection between SupportCenter Plus and the Asterisk server, go to "Admin -> Global Settings -> Telephony Server Settings". Configure the settings as per the below instructions:

    1. Telephony Server: Select Asterisk.
    2. Server Name / IP Address: Enter the IP address or the Server Name of the system, which has the Asterisk PBX server installed.
    3. Port: Enter the port number as in the manager.conf file, located in "/etc/asterisk" directory. Default port number is 5038.
    4. TLinks: This field is only for Avaya server settings, hence skip it.
    5. Username: Enter the username (manager_username) as in the manager.conf file, located in "/etc/asterisk" directory.
    6. Password: Enter the secret (manager_pwd) as in the manager.conf file, located in "/etc/asterisk" directory.
    7. Click Save.

    If the entered server details are correct, clicking Save will automatically establish a connection to the server and enable call alerts.

     

    Note:

    1. In case, if there is a problem with connecting to the Asterisk, ensure the following:

      a) if the server is reachable

      b) if the username/password is correct

    2. It is mandatory to restart SupportCenter Plus application, if any of the configuration files has been modified in the Asterisk.  

    5. Enabling Screen Popup:

    Follow the below instructions to enable screen popping:

     1. Go to "Admin -> Global Settings -> Support Reps".

     2. Edit the required Support Rep details such as, NameE-mail, etc.

     3. Tick the Enable Screen Popup check box and provide the below details:

            a) Sip UserThe user account as mentioned in the sip.conf file for Asterisk PBX.

            b) Extension NumberThe extension number of the Support Rep, for which the popup has to be shown, upon receiving calls.

     4. Provide Login Details for the Support Rep.

    5. Click Save.

     

    6. Screen popping: 

    The Support Rep will receive a popup, whenever his extension number gets a call.

    Note: The Support Rep has to login to the application with his credentials to see the popup. Below is a sample picture of the screen popup.

     

     

    7. Uninstalling Asterisk: 

    To uninstall Asterisk, go to the installation location, i.e., "/usr/src/asterisk*" and execute the following command: 

                make uninstall-all 

     

    Copyright © 2014, ZOHO Corp. All Rights Reserved.