Hướng dẫn cài đặt Freepbx 13 trên CentOS 6 Mở file /etc/sysconfig/selinux và chuyển thành disabled. Hoặc có thể chạy lệnh sau: sed -i 's/\(^SELINUX=\).*/\SELINUX=disabled/' /etc/sysconfig/selinux Reboot server, sau đó kiểm tra bằng lệnh: sestatus . Kết quả phải là: SELinux status: disabled Update các phần mềm trên server trước khi bắt đầu cài đặt Freepbx: yum -y update yum -y groupinstall core base "Development Tools" Cài đặt các gói phần mềm cơ bản chuẩn bị cho cài đặt Freepbx: yum install gcc gcc-c++ lynx bison mysql-devel mysql-server php php-mysql php-pear php-mbstring php-xml tftp-server httpd make ncurses-devel libtermcap-devel sendmail sendmail-cf caching-nameserver sox newt-devel libxml2-devel libtiff-devel audiofile-devel gtk2-devel subversion kernel-devel git subversion kernel-devel php-process crontabs cronie cronie-anacron wget vim php-xml uuid-devel libtool sqlite-devel unixODBC mysql-connector-odbc libuuid-devel binutils-devel php-ldap Iptables Nên tạm thời tắt Iptables để quá trình cài đặt Freepbx được ổn định Kiểm tra trạng thái Iptables: chkconfig iptables --list Tắt iptables: chkconfig --level 0123456 iptables off service iptables stop MySQL Auto start Mysql chkconfig --level 345 mysqld on Khởi động Mysql service mysqld start Apache Auto start Apache chkconfig --level 345 httpd on Khởi động Apache: service httpd start Cài đặt PearDB: pear channel-update pear.php.net pear install db-1.7.14 Tạo user cho Asterisk: adduser asterisk -M -c "Asterisk User" Cài đặt Asterisk và các phần mềm phụ thuộc trước khi cài đặt Freepbx: cd /usr/src wget http://downloads.asterisk.org/pub/telephony/dahdi-linux-complete/dahdi-linux-complete-current.tar.gz wget http://downloads.asterisk.org/pub/telephony/libpri/libpri-current.tar.gz wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-13-current.tar.gz Cài đặt Dahdi: cd /usr/src tar xvfz dahdi-linux-complete-current.tar.gz cd dahdi-linux-complete-* make all make install make config Cài đặt Libpri: cd /usr/src tar xvfz libpri-current.tar.gz cd /usr/src/libpri-* make make install Cài đặt Asterisk: cd /usr/src tar xvfz asterisk-13-current.tar.gz cd asterisk-* contrib/scripts/install_prereq install contrib/scripts/get_mp3_source.sh make menuselect make make install make config ldconfig Download các file âm thanh bổ sung cho Freepbx: mkdir -p /var/lib/asterisk/sounds cd /var/lib/asterisk/sounds wget http://downloads.asterisk.org/pub/telephony/sounds/asterisk-core-sounds-en-wav-current.tar.gz wget http://downloads.asterisk.org/pub/telephony/sounds/asterisk-extra-sounds-en-wav-current.tar.gz tar xvf asterisk-core-sounds-en-wav-current.tar.gz rm -f asterisk-core-sounds-en-wav-current.tar.gz tar xfz asterisk-extra-sounds-en-wav-current.tar.gz rm -f asterisk-extra-sounds-en-wav-current.tar.gz wget http://downloads.asterisk.org/pub/telephony/sounds/asterisk-core-sounds-en-g722-current.tar.gz wget http://downloads.asterisk.org/pub/telephony/sounds/asterisk-extra-sounds-en-g722-current.tar.gz tar xfz asterisk-core-sounds-en-g722-current.tar.gz rm -f asterisk-core-sounds-en-g722-current.tar.gz tar xfz asterisk-extra-sounds-en-g722-current.tar.gz rm -f asterisk-extra-sounds-en-g722-current.tar.gz Cấu hình permission cho Freepbx: chown asterisk. /var/run/asterisk chown -R asterisk. /etc/asterisk chown -R asterisk. /var/{lib,log,spool}/asterisk chown -R asterisk. /usr/lib64/asterisk chown -R asterisk. /var/www/ Cấu hình Apache sed -i 's/\(^upload_max_filesize = \).*/\120M/' /etc/php.ini sed -i 's/^\(User\|Group\).*/\1 asterisk/' /etc/httpd/conf/httpd.conf sed -i 's/AllowOverride None/AllowOverride All/' /etc/httpd/conf/httpd.conf service httpd restart Cài đặt Freepbx cd /usr/src wget http://mirror.freepbx.org/modules/packages/freepbx/freepbx-13.0-latest.tgz tar xfz freepbx-13.0-latest.tgz cd freepbx ./start_asterisk start ./install -n Đến đây bạn đã cài đặt Freepbx 13 thành công, sau đó có thể truy cập vào http://ip_của_server để truy cập giao diện quản lý của Freepbx |
Chia sẻ kinh nghiệm >