Skip to main content

VC INSTALLATION CENTOS 7

 

VC INSTALLATION CENTOS 7 


Table of content

Step by Step guide for VC scratch installation in Centos 7





1. Asterisk - Telephony server

2.Mariadb - Database

3.Apache - Webserver

  Pre-Requisites

Before proceeding with installation steps , we must have below pre-requisites ready

Centos 7 installed either full DVD or minimal OS installation
Console access to the server or SSH access via putty .
Root access or other user with necessary permission
Internet access in the server to download softwares.
Basic knowledge of linux commands like vi or nano editor, copy ,paste.

  Phase 1: Scratch Install - OS Stuff's installation


  OS Update,Selinux disable,Timezone settings

--Copy paste the below commands--

yum check-update
yum update -y
yum -y install epel-release
yum -y groupinstall 'Development Tools'
yum -y update
yum install -y kernel*
yum install nano

  Disable the SELINUX -Copy paste the below command

--Copy paste ---
sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
  Set your Timezone [replace with your timezone]

    --Copy paste ---

 

timedatectl set-timezone Asia/Kolkata

  Reboot the server once
     --Copy paste ---

reboot

  Updating YUM Repos
    --Copy paste ---

yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum -y install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
yum -y install yum-utils
yum-config-manager --enable remi-php74
  Installing Yum Repo For MariaDB
    --Copy paste ---

nano /etc/yum.repos.d/MariaDB.repo

    --Copy paste ---

[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.3/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
        Save And exit the file by Pressing Crtl+c and :wq Enter
 
 
 
  Phase 2: Scratch Install - Pre-Requisites installation
  Pre-requisites software Installation

    --Copy Paste Below command---

yum install make patch gcc perl-Term-ReadLine-Gnu gcc-c++ subversion php php-devel php-gd gd-devel php-mbstring php-mcrypt php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc php-opcache curl curl-devel perl-libwww-perl ImageMagick libxml2 libxml2-devel httpd libpcap libpcap-devel libnet ncurses ncurses-devel screen mysql-devel ntp mutt glibc.i686 wget nano unzip sipsak sox libss7* libopen* openssl libsrtp libsrtp-devel unixODBC unixODBC-devel libtool-ltdl libtool-ltdl-devel htop iftop -y

    --Copy paste ---

yum -y install sqlite-devel
yum install mariadb-server mariadb -y

  Mysql/MariaDB Custom my.cnf Settings

    --Copy paste below commands--

cp /etc/my.cnf /etc/my.cnf.original
echo "" > /etc/my.cnf

nano  /etc/my.cnf

    [--copy paste below contents ---]

[mysql.server]
user = mysql
#basedir = /var/lib
[client]
port = 3306
socket = /var/lib/mysql/mysql.sock
[mysqld]
datadir = /var/lib/mysql
bind-address = 127.0.0.1
socket = /var/lib/mysql/mysql.sock
user = mysql
old_passwords = 0
ft_min_word_len = 3
max_connections = 800
max_allowed_packet = 32M
skip-external-locking
sql_mode="NO_ENGINE_SUBSTITUTION"
log-error = /var/log/mysqld/mysqld.log
query-cache-type = 1
query-cache-size = 32M
long_query_time = 1
#slow_query_log = 1
#slow_query_log_file = /var/log/mysqld/slow-queries.log
tmp_table_size = 128M
table_cache = 1024
join_buffer_size = 1M
key_buffer = 512M
sort_buffer_size = 6M
read_buffer_size = 4M
read_rnd_buffer_size = 16M
myisam_sort_buffer_size = 64M
max_tmp_tables = 64
thread_cache_size = 8
thread_concurrency = 8
# If using replication, uncomment log-bin below
#log-bin = mysql-bin
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
no-auto-rehash
[isamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M
[myisamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M
[mysqlhotcopy]
interactive-timeout
[mysqld_safe]
#log-error = /var/log/mysqld/mysqld.log
#pid-file = /var/run/mysqld/mysqld.pid
    
    Save And exit the file by Pressing Crtl+x and y Enter

  Enabling Mysql Logging

    --Copy Paste below commands --

mkdir /var/log/mysqld
mv /var/log/mysqld.log /var/log/mysqld/mysqld.log
touch /var/log/mysqld/slow-queries.log
chown -R mysql:mysql /var/log/mysqld

  Apache/Httpd Custom Settings

    --Copy paste below lines--

nano +217 /etc/httpd/conf/httpd.conf

--replace --

CustomLog logs/access_log combined
--with --

CustomLog /dev/null common

--goto Last line by typing 
--copy paste the below content--


        Save And exit the file by Pressing Crtl+x and Enter

  Php Custom php.ini Settings

    --Copy paster below command--

nano /etc/php.ini
    --search and edit below settings by pressing Ctrl+w --
    
error_reporting = E_ALL & ~E_NOTICE
memory_limit = 48M
short_open_tag = On
max_execution_time = 330
max_input_time = 360
post_max_size = 48M
upload_max_filesize = 42M
default_socket_timeout = 360
date.timezone = America/New_York

--Note: Remove Preceedign colon(;) from date.timezone
--Save And exit the file by Pressing Crtl+x and  Enter


  MariaDb/httpd service start and enable at startup
    --Copy paste ---

systemctl enable httpd.service
systemctl enable mariadb.service
systemctl start httpd.service
systemctl start mariadb.service

  Phase 3 : Scratch Install - CPAN Modules installation


    --Copy paste ---
yum install perl-CPAN -y
yum install perl-YAML -y
yum install perl-libwww-perl -y
yum install perl-DBI -y
yum install perl-DBD-MySQL -y
yum install perl-GD -y
    --Copy paste ---
cd /usr/bin/
curl -LOk http://xrl.us/cpanm
chmod +x cpanm
cpanm -f File::HomeDir
cpanm -f File::Which
cpanm CPAN::Meta::Requirements
cpanm -f CPAN
cpanm YAML
cpanm MD5
cpanm Digest::MD5
cpanm Digest::SHA1
cpanm readline --force


cpanm Bundle::CPAN
cpanm DBI
cpanm -f DBD::mysql
cpanm Net::Telnet
cpanm Time::HiRes
cpanm Net::Server
cpanm Switch
cpanm Mail::Sendmail
cpanm Unicode::Map
cpanm Jcode
cpanm Spreadsheet::WriteExcel
cpanm OLE::Storage_Lite
cpanm Proc::ProcessTable
cpanm IO::Scalar
cpanm Spreadsheet::ParseExcel
cpanm Curses
cpanm Getopt::Long
cpanm Net::Domain
cpanm Term::ReadKey
cpanm Term::ANSIColor
cpanm Spreadsheet::XLSX
cpanm Spreadsheet::Read
cpanm LWP::UserAgent
cpanm HTML::Entities
cpanm HTML::Strip
cpanm HTML::FormatText
cpanm HTML::TreeBuilder
cpanm Time::Local
cpanm MIME::Decoder
cpanm Mail::POP3Client
cpanm Mail::IMAPClient
cpanm Mail::Message
cpanm IO::Socket::SSL
cpanm MIME::Base64
cpanm MIME::QuotedPrint
cpanm Crypt::Eksblowfish::Bcrypt
cpanm Crypt::RC4
cpanm Text::CSV
cpanm Text::CSV_XS

  Make Sure all CPANS installed by rerunning all Cpan commands
  Copy paste below commands ,make sure you see upto date installed

    --Copy paste ---

cpanm File::HomeDir
cpanm File::Which
cpanm CPAN::Meta::Requirements
cpanm CPAN
cpanm YAML
cpanm MD5
cpanm Digest::MD5
cpanm Digest::SHA1
cpanm readlinecpanm Bundle::CPAN
cpanm DBI
cpanm DBD::mysql
cpanm Net::Telnet
cpanm Time::HiRes
cpanm Net::Server
cpanm Switch
cpanm Mail::Sendmail
cpanm Unicode::Map
cpanm Jcode
cpanm Spreadsheet::WriteExcel
cpanm OLE::Storage_Lite
cpanm Proc::ProcessTable
cpanm IO::Scalar
cpanm Spreadsheet::ParseExcel
cpanm Curses
cpanm Getopt::Long
cpanm Net::Domain
cpanm Term::ReadKey
cpanm Term::ANSIColor
cpanm Spreadsheet::XLSX
cpanm Spreadsheet::Read
cpanm LWP::UserAgent
cpanm HTML::Entities
cpanm HTML::Strip
cpanm HTML::FormatText
cpanm HTML::TreeBuilder
cpanm Time::Local
cpanm MIME::Decoder
cpanm Mail::POP3Client
cpanm Mail::IMAPClient
cpanm Mail::Message
cpanm IO::Socket::SSL
cpanm MIME::Base64
cpanm MIME::QuotedPrint
cpanm Crypt::Eksblowfish::Bcrypt
cpanm Crypt::RC4
cpanm Text::CSV
cpanm Text::CSV_XS

  Phase 4 : Scratch Install - Supporting Softwares


 
 Asterisk Perl Installation
cd /usr/src
wget http://download.vicidial.com/required-apps/asterisk-perl-0.08.tar.gz
tar xzf asterisk-perl-0.08.tar.gz
cd asterisk-perl-0.08
perl Makefile.PL
make all
make install
  SIPSAK
cd /usr/src
wget http://download.vicidial.com/required-apps/sipsak-0.9.6-1.tar.gz
tar -zxf sipsak-0.9.6-1.tar.gz
cd sipsak-0.9.6
./configure
make
make install
/usr/local/bin/sipsak --version
  LAME
cd /usr/src
wget http://downloads.sourceforge.net/project/lame/lame/3.99/lame-3.99.5.tar.gz
tar -zxf lame-3.99.5.tar.gz
cd lame-3.99.5
./configure
make
make install
  JANSSON
cd /usr/src/
wget http://www.digip.org/jansson/releases/jansson-2.5.tar.gz
tar -zxf jansson-2.5.tar.gz
#tar xvzf jasson*
cd jansson*
./configure
make clean
make
make install
ldconfig

  Phase 5 : Scratch Install - Asterisk|DAHDI|Libpri

  Downloading asterisk/dahdi/libpri
    --copy paste--
mkdir /usr/src/asterisk
cd /usr/src/asterisk
wget http://download.vicidial.com/beta-apps/dahdi-linux-complete-2.11.1.tar.gz
wget http://downloads.asterisk.org/pub/telephony/libpri/libpri-current.tar.gz
wget http://download.vicidial.com/required-apps/asterisk-1.8.23.0-vici.tar.gz
  Unzip/Untar the Downloaded Files
    --copy paste--
cd /usr/src/asterisk
tar -xvzf asterisk-*
tar -xvzf dahdi-linux-complete-*
tar -xvzf libpri-*
  Installing DAHDI Software
    --copy paste--
yum install dahdi*
cd /usr/src/asterisk
cd dahdi-linux-complete-*
make all
make install
make config
modprobe dahdi
modprobe dahdi_dummy
dahdi_genconf -v
dahdi_cfg -v
  Installing LibPri Software
    --copy paste--
cd /usr/src/asterisk
cd libpri*
make
make install
  Installing Asterisk Software
    --copy paste--
cd /usr/src/asterisk/asterisk-*

contrib/scripts/install_prereq install

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

yum install php-intl


nano /etc/httpd/conf.d/recordings.conf

Alias /recordings "/var/www/recordings/"

Alias /RECORDINGS "/var/www/recordings/"

<Directory "/var/www/recordings/files/">

Options Indexes FollowSymLinks

AllowOverride All

Require all granted

</Directory>


nano /etc/httpd/conf.d/voicelogger.conf

Alias /voicelogger "/var/www/html/voicelogger/public"
<Directory "/var/www/html/voicelogger/public/">
Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
</Directory>


CREATE DATABASE voicecatch DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
CREATE USER 'cron'@'localhost' IDENTIFIED BY '1234';
GRANT SELECT,CREATE,ALTER,INSERT,UPDATE,DELETE,LOCK TABLES on voicecatch.* TO cron@'%' IDENTIFIED BY '1234';
GRANT SELECT,CREATE,ALTER,INSERT,UPDATE,DELETE,LOCK TABLES on voicecatch.* TO cron@localhost IDENTIFIED BY '1234';
GRANT RELOAD ON *.* TO cron@'%';
GRANT RELOAD ON *.* TO cron@localhost;
flush privileges;
SET GLOBAL connect_timeout=60;


copy voicelogger folder into the html folder

cd /var/www/html/voicelogger

mysql

use voicecatch;

source voicecatch.sql

copy agi files into the /var/lib/asterisk/agi-bin/

chmod 755 *.*

copy asterisk config files from backup folder.

nano /etc/rc.d/rc.local
    --copy paste below after last line --


# Disable console blanking and powersaving
/usr/bin/setterm -blank
/usr/bin/setterm -powersave off
/usr/bin/setterm -powerdown
### start up the MySQL server
systemctl start mariadb.service
### start up the apache web server
systemctl start httpd.service

### load dahdi drivers
modprobe dahdi
modprobe dahdi_dummy
/usr/sbin/dahdi_cfg -vvvvvvvvvvvvv


  Enabling Rc.local and run at startup

chmod +x /etc/rc.d/rc.local
systemctl enable rc-local
systemctl start rc-local


Install Phpsysinfo and samba and other utility.


Comments

Popular posts from this blog

voice broadcast in vicidial Step by Step Guide

 Follow all below mention steps:- 1.  Open https://ttsmp3.com/   2.  Select Voice Indian English 3.  Type whatever you want to convert into voice.   4.  Read and confirm and then download as a MP3.   5.  Open downloaded file with wavepad and convert into 16bit Mono 8k PCM WAV. or you can use online audio converter from below mention link. site support .wav file only so you need to convert MP3 file to wav using below mention site. https://g711.org/   6.  Upload file to vicidial audio store.   7.  Manual copy file into /var/lib/asterisk/sound/ folder using winscp software. https://winscp.net/download/WinSCP-5.21.6-Portable.zip   8.  Copy campaign from existing Broadcast camp.   9.  Click on created camp and select details view then click on survey     select Survey First Audio File:- as audio file which we created in step 1 and submit.   10. Create list and select campaign as Newly created campaign broadcast, and change routing extensions.   11. Create user with same name of remote agent

Debian 11 Vicidial scratch install dynamic portal

  Step by step guide to scratch install the vidial dynamic portal in Debian 11 or ubuntu based vicidial scratch installations. If you have installed vicidial using scratch installation instead of using the default vicibox iso then you need to manually install and configure the dynamic portal , follow this blog tutorial to scratch install the vicidial dynamic portal . Here's the steps to install and configure the vicidial dynamic portal in scratch installations. Steps to install vicidial dynamic portal cd /usr/src git clone https://github.com/manish23k/vicidial-dynamicportal.git cd vicidial-dynamicportal chmod +x vici_dynportal.sh ./vici_dynportal.sh or you can install manually. Follow the below steps to install and configure the vicidial dynamic portal in your scratch installations, Step 1: Install the firewalld and ipset apt install firewalld apt  install ipset Step 2: Download the Dynamic portal files from my Github cd /usr/src/ mkdir dynamicportal cd dynamicportal wget ht

Vicidial Scratch installation Debian 11 with Asterisk 16, WebRTC and Dynamic Portal

  Vicidial Scratch installation Debian 11  Asterisk 16, WebRTC and Dynamic Portal apt update apt upgrade apt-get install git nano wget cd /usr/src/ git clone https://github.com/manish23k/Vici_Install_Scripts_Deb_11.git cd Vici_Install_Scripts_Deb_11/ chmod +x *.sh Run ./vici_install_deb_ast16.sh Install WebRTC ./vicidial-install-webrtc.sh Once Done with Configuration Secure Server with Vici Dynamic Portal Run ./vici_dynportal.sh