Soporte & Consultoria

Soporte Remoto y Consultoria skype : ambiorixg12.
Nota no se brinda ningun tipo de consulta o soporte fuera del blog de forma gratuita

domingo, 14 de septiembre de 2014

Instalacion de Asterisk 11 & Freepbx v 2.11 en CENTOS 6.5 64 bit


Instalacion de  Asterisk + Freepbx

Actualizamos el Sistema

yum -y update
yum groupinstall core
yum groupinstall base

Desactivamos el Selinux
setenforce 0

Reiniciamos

reboot

Instalamos las depenencias.

yum install -y make wget openssl-devel ncurses-devel  newt-devel libxml2-devel kernel-devel gcc gcc-c++ sqlite-devel

yum install gcc gcc-c++ wget bison mysql-devel mysql-server php php-mysql php-process php-pear php-mbstring tftp-server httpd make ncurses-devel libtermcap-devel sendmail sendmail-cf caching-nameserver sox newt-devel libxml2-devel libtiff-devel php-gd audiofile-devel gtk2-devel subversion nano kernel-devel selinux-policy sqlite-devel openssl-devel libuuid-devel libcurl-devel tzdata

yum install libtool-ltdl-devel unixODBC unixODBC-devel mysql-connector-odbc

Instalamos el APACHE PHP MYSQL

Apache

yum install httpd

service httpd start

chkconfig httpd on


MYSQL
yum install mysql-server
service mysqld start
/usr/bin/mysql_secure_installation

chkconfig mysqld on


PHP-MYSQL
yum install php php-mysql


Instalar pear



rpm -qa|grep php-pear



[root@server]# yum install php-pear
[root@server]# rpm -qa|grep php-pear
php-pear-1.4.9-8.el5


[root@server]# pear install db

yum -y install php-posix
[root@server]# service httpd restart 



Create Asterisk User

adduser asterisk -M -d /var/lib/asterisk -s /sbin/nologin -c "Asterisk User"


Descargamos Asterisk  y Freepbx
cd /usr/src/

Asterisk
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-11-current.tar.gz


Freepbx
wget http://65.181.118.232/fpx/freepbx-2.11.0.tar.gz

Descomprimimos

tar zxvf asterisk*

tar zxvf freepbx-2.11*


Instalamos Asterisk
cd /usr/src/asterisk*
./configure --libdir=/usr/lib64 && make menuselect && make && make install
Vamos a copiler flags y desactivamos build native

selecionamos tambien los extrasounds


make samples
make config
service asterisk start
asterisk -rvvvvvvvvv


Freepbx
nano +457 /etc/php.ini
memory_limit = 128M
service httpd restart


[root@pbx1 ~]# cd /etc
[root@pbx1 etc]# mv asterisk asterisk1
[root@pbx1 etc]# mkdir asterisk
[root@pbx1 etc]# ls asterisk




cd /usr/src/freepbx-2.11*/


 Change Apache User
Change User apache and Group apache to User asterisk and Group asterisk.

sed -i "s/User apache/User asterisk/" /etc/httpd/conf/httpd.conf
sed -i "s/Group apache/Group asterisk/" /etc/httpd/conf/httpd.conf

restart apache
service httpd restart

Creamos las bases de datos
cd /usr/src/freepbx-2.11*/
mysqladmin create asterisk -p
mysqladmin create asteriskcdrdb -p
mysql asterisk < SQL/newinstall.sql -p
mysql asteriskcdrdb < SQL/cdr_mysql_table.sql -p

 mysql -p

 mysql> GRANT ALL PRIVILEGES ON asterisk.* TO asteriskuser@localhost IDENTIFIED BY 'amp109';

 mysql> GRANT ALL PRIVILEGES ON asteriskcdrdb.* TO asteriskuser@localhost IDENTIFIED BY 'amp109';
mysql> flush privileges;

Instalamos freepbx

/usr/sbin/safe_asterisk

 sed -i "s_/usr/lib_/usr/lib64_" asterisk.conf install_amp libfreepbx.install.php

 ./install_amp

asterisk -rvvvvvvvvvvvv
sip show peers ( No hay  ningun sip peer creado aun).

Creamos una extension desde la Web de Freepbx y volvemos a correr el comando


Freepbx-demo*CLI> sip show peers
Name/username             Host                                    Dyn Forcerport                                                                              Comedia    ACL Port     Status      Description
100                       (Unspecified)                            D  No                                                                                      No          A  0        UNKNOWN
1 sip peers [Monitored: 0 online, 1 offline Unmonitored: 0 online, 0 offline]
Freepbx-demo*CLI>






1 comentario: