Flexisip:installation

From BelledonneComm
Jump to: navigation, search

Installation

Hardware and Operating system

This guide assumes that you are using either a Debian 7 or a Centos 7 (or more recent) distribution.

The hardware should be chosen according to the workload you want to be able to sustain. Although flexisip is not quite CPU intensive (unless you are transcoding), you should make sure that your machine has enough RAM. Up to about 10000 connections, you should be OK with 8 GB of RAM.

Installation on Centos7

There are 3 steps that are required for installing on Centos7:

  • You have to have the EPEL repository added to your list of repositories; we use it for the hiredis-devel package.

To install EPEL, simply go there: http://mirror.ibcp.fr/pub/epel/7/x86_64/repoview/epel-release.html and download and install the package.

  • Then, add our nightly repository to your yum repo list:
cat > /etc/yum.repos.d/Belledonne.repo <<EOF
[Belledonne]
name=Belledonne
baseurl=http://www.linphone.org/snapshots/centos7
enabled=1
gpgcheck=0
EOF
  • Then perform the actual installation:
sudo yum update
sudo yum install bc-flexisip

The very first launch will fail, because it will lack a valid configuration file (see below for instructions to use a default configuration).

Installation on Debian8 Jessie (works for Debian 7 Wheezy too)

Create the Belledonne Communications apt repo in /etc/apt/sources.list.d/belledonne.list :

deb [arch=amd64] http://linphone.org/snapshots/debian jessie main


FOR WHEEZY ONLY: If not yet present, add the wheezy backport repository (for redis-server):

deb http://ftp.debian.org/debian/ wheezy main

Install the belledonne communication gpg key used to sign the debs:

sudo wget -O /etc/apt/trusted.gpg.d/belledonnecommunications.gpg https://linphone.org/snapshots/debian/keyring.gpg

Update aptitude and install flexisip and it's dependencies:

aptitude update
aptitude install bc-flexisip

Installation from sources using git

If none of the above solutions suit your case, you can still install Flexisip manually by compiling it.

First you have to install tools needed for compilation. You will at least need: cmake, C++ compiler (for instance g++ or Clang), pkg-config, automake, autoconf, libtoolize (libtool), intltoolize (intltool).

Then the following procedure will download latest flexisip with its dependencies and install them in current directory flexisip/OUTPUT:

git clone git://git.linphone.org/flexisip --depth 1 --recursive
cd flexisip
./prepare.py flexisip
 make -C WORK/flexisip/cmake

Default configuration

First of all, be aware that we install flexisip in a non-standard directory : /opt/belledonne-communications/bin. You should add this directory to your path for ease of testing:

export PATH=$PATH:/opt/belledonne-communications/bin


Then you should create the flexisip configuration file: /etc/flexisip/flexisip.conf and restart the flexisip daemon:

# this will dump flexisip's default configuration into the configuration file.
/opt/belledonne-communications/bin/flexisip --dump-default all > /etc/flexisip/flexisip.conf

# on debian:
service flexisip restart

# on centos7:
systemctl start flexisip.service

Startup options

By default, flexisip uses the /etc/flexisip/flexisip.conf configuration file. You can use the --configfile option to force flexisip to use another configuration file.

An init script is installed in /etc/init.d/flexisip to manage the automatic start/stop of the service during the machine boot.

This script reads into /etc/default/flexisip to read command line options. The --daemon and --syslog options are always added when the flexisip command invocation when it is run from init scripts in order to comply with boot system requirements.

It is possible to pass additional command line options by creating or editing the /etc/default/flexisip file with a single line:

flexisip_OPTIONS="--configfile /opt/mycompany/myflexisipconf.conf"