INSTALLATION Complete Asterisk-OpenImsCore

Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 5

Installation et configuration

--------------------Asterisk et openImscore------------

Asterisk:
DEPENDANCES:

sudo apt-get install -y build-essential linux-headers-`uname -r` openssh-server


mysql-client mysql-server libmysql++-dev bison flex phpmyadmin curl sox
libncurses5-dev libssl-dev libmysqlclient15-dev mpg123 libxml2-dev libnewt-dev
sqlite3 libsqlite3-dev pkg-config automake libtool autoconf git subversion uuid
uuid-dev
$ sudo apt-get install python-software-properties
$ sudo add-apt-repository ppa:ondrej/php
$ sudo apt-get update
$ sudo apt-get install -y php7.0
$ sudo apt-get install php7.0-mysql php7.0-curl php7.0-gd php7.0-mcrypt

ASTERISK:

Cheick# apt-get update


-------Installation du serveur Asterisk et de toutes ces dpendances--
Cheick # apt-get install asterisk

-----Installation des voix franaises dAsterisk------


Cheick# apt-get install asterisk-prompt-fr

------Pour finir linstallation il faut autoriser le dmarrage du service. Il faut


modifier un ficher laide de lditeur de texte nano ou
autre.----------------------
nano /etc/default/asterisk

-----------Et modifier le champ.--------------------


RUNASTERISK=yes

---------------Voil notre serveur Asterisk est install. Nous allons apprendre


dmarrer le service .----------------

OpenImscore:
DEPENDANCES:

sudo apt-get install libcurl4-gnutls-dev bison curl debhelper cdbs lintian build-
essential fakeroot devscripts pbuilder dh-make debootstrap dpatch flex libxml2-dev
libmysqlclient-dev ant docbook-to-man ipsec-tools subversion mysql-server-5.5

sudo apt-get install bind9

Installing OpenIMSCore on Ubunto 12.04

--------To install JDK 8:-----------

sudo add-apt-repository ppa:webupd8team/java


sudo apt-get update
sudo apt-get install oracle-java8-installer

sudo apt-get install oracle-java8-set-default

------ Download openIMScore-------------------


sudo mkdir /opt/OpenIMSCore
sudo chown -R username opt/OpenIMSCore/
cd /opt/OpenIMSCore

mkdir ser_ims
svn checkout https://svn.code.sf.net/p/openimscore/code/ser_ims/trunk/ ser_ims

------- problem on ubuntu 12 and solve it by this code----------------

sudo sed -i '/include <curl\/types.h>/d' ser_ims/lib/lost/client.h

------ installing IMScore-------


cd ser_ims
make install-libs all
cd ..
------------- Compile FHoSS----------
sudo mkdir FHoSS
sudo svn checkout https://svn.code.sf.net/p/openimscore/code/FHoSS/trunk/ FHoSS

cd FHoSS
sudo ant compile deploy
sudo sed -i 's/JAVA_HOME\/bin\/java/JAVA_HOME\/usr\/bin\/java/g' deploy/startup.sh
cd ..
--------------- Copy databases to sql server---------
mysql -u root -p -h localhost < ser_ims/cfg/icscf.sql
mysql -u root -p -h localhost < FHoSS/scripts/hss_db.sql
mysql -u root -p -h localhost < FHoSS/scripts/userdata.sql

---- Configure DNS--------------


- To install DNS on ubuntu
sudo apt-get install bind9
-then

sudo cp ser_ims/cfg/open-ims.dnszone /etc/bind/

sudo sed -i '3azone "open-ims.test" {\n\ttype master;\n\tfile "\/etc\/bind\/open-


ims.dnszone";\n};' /etc/bind/named.conf.local

sudo sed -i '2a127.0.0.1\topen-ims.test mobicents.open-ims.test ue.open-ims.test


presence.open-ims.test icscf.open-ims.test scscf.open-ims.test pcscf.open-ims.test
hss.open-ims.test' /etc/hosts

- To restart DNS server


sudo /etc/init.d/bind9 restart

---------------------We need to ensure that the DNS server can be contacted from
our PC, which is why we edit the file / etc / resolv.conf and add the following
lines:----------------------

search open-ims.test
nameserver 127.0.0.1

-----------------We verify that it works properly pinging pcscf.open-


ims.test---------------------------------------------------

ping-pcscf.open-ims.test

As a rule, we get an answer. If the ping does not work, restart the network
interface (localhost) or attiviamola, in the case has not been activated:
sudo / etc / init.d / networking restart

------------- copy start up files-------------


sudo cp ser_ims/cfg/*.cfg ./
sudo cp ser_ims/cfg/*.xml ./
sudo cp ser_ims/cfg/*.sh ./

------ Start up your servers----------


sudo ./pcscf.sh
sudo ./scscf.sh
sudo ./icscf.sh
cd FHoSS/deploy
sudo sh startup.sh

----- to access the FHoSS use this URL----------


http://hssAdmin:hss@localhost:8080/hss.web.console/

OpenIMSCore: Building from source


Initially compile the CSCF. To do this we run the following commands:

cd / opt / OpenIMSCore / ser_ims /


sudo make install-libs all
The duration of completion varies depending on the characteristics of the machine
where you install the software. In general, the duration is between 5-10 minutes.
To fill the other hand HSS (FHoSS in OpenIMSCore) we need to set the environment
variable JAVA using the command:
export JAVA_HOME = / usr/lib/jvm/java-1.6.0-sun
Since this environment variable must be set each time you run the script for the
execution of FHoSS, I advise you to change. Bashrcpresent in your home directory:

gedit ~ /. bashrc
Glue the end the following string:

export JAVA_HOME = / usr/lib/jvm/java-1.6.0-sun

export CLASSPAT=.$JAVA_HOME/lib:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar

export PATH=$PATH:/usr/lib/jvm/java-6-sun/lib
save and close the file. Launch:

source ~ /. bashrc
to apply the changes to environment variables.
Compile using the following commands FHoSS

cd / opt / OpenIMSCore / FHoSS


ant compile deploy
Finally ZhDataType.xsd modify the file in the directory / opt / OpenIMSCore / FHoSS
/ xsd /

gedit / opt / OpenIMSCore / FHoSS / xsd / ZhDataType.xsd


and replace the line

schemaLocation = http://www.w3.org/2001/xml.xsd />


with

schemaLocation = file: / / / opt / OpenIMSCore / FHoSS / xsd / xml.xsd />


OpenIMSCore: Execution of various scripts
To facilitate the implementation copy all files and configuration of all FHoSS CSCF
and associated run script in the / opt / OpenIMSCore /:

cp / opt / OpenIMSCore / ser_ims / cfg / * / opt / OpenIMSCore /


Finally we run all the entities OpenIMSCore. I recommend you open a new tab (Ctrl +
Male + T) to each entity and set the tab title.
For P-CSCF lanciarce

/ Opt / OpenIMSCore / pcscf.sh


To run I-CSCF

/ Opt / OpenIMSCore / icscf.sh


To launch the S-CSCF

/ Opt / OpenIMSCore / scscf.sh


To launch FHoSS

/ Opt / OpenIMSCore / fhoss.sh

If you can see an error writing something like :

set_mod_param_regax: No module matching <pcscf> found i ERROR CURL_ERROR_SIZE"


it means that you must install
libcurl4-openssl-dev
and compile FhoSS from the begining.

You might also like