Wondering how to install Vicidial scratch on ubuntu? We can help you.
As part of our Server Management Services, we assist our customers with similar queries.
Today, let us see how our Support techs perform this task.
How to Install Vicidial scratch on ubuntu?
VICIDIAL is an enterprise class, open source, call center suite in use by many large call centers around the world.
It can also function as an ACD for inbound calls, or closer calls coming from VICIDIAL outbound fronters.
It is capable of inbound, outbound, and blended call handling.
VICIDIAL even allows you to have agents logged in from remote locations.
Today, let us see the steps followed by our Support Techs in order to perform this task.
1.Firstly, login to the server as a root user
$ apt-get update #(retrieves the latest repository information)
$ apt-get upgrade #(upgrades any out of date packages
$ apt-get install linux-headers #(Used for zaptel compile) or
$ apt-get install linux-headers-server
$ apt-get install linux-source #(needed if you are going to recompile the linux kernel)
$ apt-get install linux-image-server
$ reboot #(reboot to use the new kernel)
Using cron and aptitude
2.To begin, create a new file:
$ nano /etc/cron.weekly/apt-security-updates
3.Then copy the following text into this new file, save, and exit:
echo “**************” >> /var/log/apt-security-updates
date >> /var/log/apt-security-updates
aptitude update >> /var/log/apt-security-updates
aptitude safe-upgrade -o Aptitude::Delete-Unused=false –assume-yes –target-release `lsb_release -cs`-security >> /var/log/apt-security-updates
echo “Security updates (if any) installed”
Press ctrl+x and the Y “enter” to save
4.Once you are complete, you want to make the file executable. So, via the terminal, type the following line:
$ sudo chmod +x /etc/cron.weekly/apt-security-updates
This script will run once weekly and it installs all available packages from the security repository.
It also generates a log in /var/log/apt-security-updates for later inspection in case something goes wrong.
This script will output information to a log file, so to prevent this log file from getting too large we need to make sure it gets rotated out.
To do this, we’ll use the logrotate utility, which comes with Ubuntu.
Press Alt+F2 and type this command:
$ nano /etc/logrotate.d/apt-security-updates
> install MD5
> install Digest::SHA1
> install readline
> install Bundle::CPAN #(do not change settings,This one takes a while be patient and keep hitting enter!)
> quit
$ cpan (enter through questions until you get to the cpan prompt)
> o conf commit (saves the config changes)
> force install Scalar::Util
> install DBI
> force install DBD::mysql
> install Net::Server
> install Time::HiRes
> install Net::Telnet
> install Unicode::Map
> install Jcode
> install OLE::Storage_Lite
> install Spreadsheet::WriteExcel
> install Proc::ProcessTable
> install Spreadsheet::ParseExcel
> install Mail::Sendmail
> quit
$ cd /usr/src
$ wget http://asterisk.gnuinter.net/files/aste … .08.tar.gz
$ tar xzf asterisk-perl-0.08.tar.gz
$ cd asterisk-perl-0.08
$ perl Makefile.PL
$ make all
$ make install
$ cd /usr/src
$ wget http://www.daveltd.com/src/util/ttyload … 0.5.tar.gz
$ tar xzf ttyload-0.5.tar.gz
$ cd ttyload-0.5
$ make
$ make install
$ cd /usr/src
$ wget http://bart.eaccelerator.net/source/0.9 … .9.5.3.zip
$ unzip eaccelerator-0.9.5.3.zip
$ cd eaccelerator-0.9.5.3
$ phpize
$ ./configure
$ make
$ make install
$ cd /etc/php5/conf.d/
$ nano eaccelerator.ini
> add the following to the eaccelerator.:
extension=”eaccelerator.so”
eaccelerator.shm_size=”48″
eaccelerator.cache_dir=”/var/lib/eaccelerator”
eaccelerator.enable=”1″
eaccelerator.optimizer=”1″
eaccelerator.check_mtime=”1″
eaccelerator.debug=”0″
eaccelerator.filter=””
eaccelerator.shm_max=”0″
eaccelerator.shm_ttl=”0″
eaccelerator.shm_prune_period=”0″
eaccelerator.shm_only=”0″
eaccelerator.compress=”1″
eaccelerator.compress_level=”9″
Press ctrl+x and the Y “enter” to save
$ mkdir /var/lib/eaccelerator
$ chmod 0777 /var/lib/eaccelerator
$ php -v
Please note you should see a line mentioning eaccelerator. If you do not or you get an error you have done something wrong
$ mkdir /usr/src/asterisk
$ cd /usr/src/asterisk
5.FOR 1.4 asterisk do the following:
$ wget http://download.vicidial.com/required-a … ici.tar.gz
$ wget http://downloads.digium.com/pub/zaptel/ … 2.1.tar.gz
$ wget http://downloads.asterisk.org/pub/telep … 0.1.tar.gz
$ tar xzf asterisk-1.4.27.1-vici.tar.gz
$ tar xzf zaptel-1.4.12.1.tar.gz
$ tar xzf libpri-1.4.10.1.tar.gz
$ cd libpri-1.4.10.1
$ make clean; make; make install
$ cd ../zaptel-1.4.12.1
$ ./configure; make clean; make; make install
$ cd ../
$ mv asterisk-1.4.27.1-vici asterisk-1.4.27.1
$ cd asterisk-1.4.27.1
$ ./configure; make clean; make; make install
$ make samples
$ modprobe zaptel
$ modprobe ztdummy
6.Install the module for the digium device that you are using, we are using the T100P single span T1 card so we use:
modprobe wct1xxp
Here’s the list of all digium cards and the modules you use with them:
Card Module
—————–
TDM400P wctdm
X100P wcfxo
TDM* wcfxs
S100U wcusb
T100P wct1xxp
E100P wct1xxp
T400P tor2
E400P tor2
TE110P wcte11xp
TE410P wct4xxp
TE405P wct4xxp
TE411P wct4xxp
TE406P wct4xxp
TE210P wct2xxp
TE205P wct2xxp
TDM2400P wctdm24xxp
7.If you have chosen a Sangoma T1/E1 or analog card, you will need to follow their instructions for installation of their driver software LATEST Sangoma Wanpipe drivers:
wget ftp://ftp.sangoma.com/linux/current_wan … -3.3.9.tgz
8.Now your asterisk installation is built and loaded and it’s time to configure it.
NOTES: If you want to install zttool diagnostics you may need the newt package installed:
$ wget http://download.vicidial.com/packages/n … 1.6.tar.gz
$ ln -s /usr/lib/libnewt.so.0.51.6 /usr/lib/libnewt.so.0.51
9.Then go to your zaptel folder and do ‘make zttool’
Digium/Clone X100P EXAMPLE for reliable cheap hardware timer:
$ ./conf_examples/zaptel.conf.x100p.sample
$ ./conf_examples/zapata.conf.x100p.sample
Digium/Clone T100P EXAMPLE, also works for TE4xxp cards
$ ./conf_examples/zaptel.conf.t100p.sample
$ ./conf_examples/zapata.conf.t100p.sample
Test Asterisk:
$ asterisk -vvvvvvvvvvvvvvvvvvvvvvvvvvvvgc #(to see if Asterisk runs)
> core show version
> dahdi show status
> core show application meetme
> stop now
10 FOR Sounds asterisk run the following steps
$ cd /usr/src/
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
$ wget http://downloads.digium.com/pub/telepho … ent.tar.gz
11.Set the sounds in place
$ cd /var/lib/asterisk/sounds
$ tar xzf /usr/src/asterisk-core-sounds-en-gsm-current.tar.gz
$ tar xzf /usr/src/asterisk-core-sounds-en-ulaw-current.tar.gz
$ tar xzf /usr/src/asterisk-core-sounds-en-wav-current.tar.gz
$ tar xzf /usr/src/asterisk-extra-sounds-en-gsm-current.tar.gz
$ tar xzf /usr/src/asterisk-extra-sounds-en-ulaw-current.tar.gz
$ tar xzf /usr/src/asterisk-extra-sounds-en-wav-current.tar.gz
12.Grab parking file, and convert audio to native formats
$ wget http://download.vicidial.com/conf/conf.gsm
$ sox conf.gsm conf.wav
$ sox conf.gsm -t ul conf.ulaw
$ cp conf.gsm park.gsm
$ cp conf.ulaw park.ulaw
$ cp conf.wav park.wav
$ cd /var/lib/asterisk
$ ln -s moh mohmp3
$ mkdir mohmp3
$ cd mohmp3
$ rm CHANGES*
$ rm LICENSE*
$ rm .asterisk*
$ mkdir /var/lib/asterisk/quiet-mp3
$ cd /var/lib/asterisk/quiet-mp3
13.For SVN 2.2.0 trunk: ( There are other options but this gives you the latest version)
$ mkdir /usr/src/astguiclient
$ cd /usr/src/astguiclient
$ svn checkout svn://svn.eflo.net:43690/agc_2-X/trunk
$ cd trunk
$ perl install.pl
14.Once in Perl Follow these steps:
: manual configuration y
: press enter until you get to webroot and set that to the following:
: press enter through to the Sample configuration files and set that to ‘y’
: Then press enter through to the end of the script
15.To change root mysql password
$ mysqladmin -u root password YOURNEWPASSWORD
16.Then, dump vicidial database
$ mysql -p (enter the mysql root user’s password you set earlier)
> CREATE DATABASE `asterisk` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
> GRANT SELECT,INSERT,UPDATE,DELETE,LOCK TABLES on asterisk.* TO cron@’%’ IDENTIFIED BY ‘1234’;
> GRANT SELECT,INSERT,UPDATE,DELETE,LOCK TABLES on asterisk.* TO cron@localhost IDENTIFIED BY ‘1234’;
> use asterisk;
> \. /usr/src/astguiclient/trunk/extras/MySQL_AST_CREATE_tables.sql
> \. /usr/src/astguiclient/trunk/extras/first_server_install.sql
> \. /usr/src/astguiclient/trunk/extras/sip-iax_phones.sql
> quit
17.Add my.cnf :
$ cd /etc/mysql/
$ wget http://download.vicidial.com/ubuntu/ubuntu-my-vici.cnf
$ mv ubuntu-my-vici.cnf my.cnf
$ /etc/init.d/mysql restart
$ /usr/share/astguiclient/ADMIN_update_server_ip.pl –old-server_ip=10.10.10.15
$ /usr/share/astguiclient/ADMIN_area_code_populate.pl
$ cp /usr/src/astguiclient/trunk/extras/performance_test_leads.txt /usr/share/astguiclient/LEADS_IN/
$ /usr/share/astguiclient/VICIDIAL_IN_new_leads_file.pl –forcelistid=107 –forcephonecode=1
18.Next, Setup Crontab
$ crontab -e
19.Add the following lines:
### remove old vicidial logs and asterisk logs more than 2 days old 28 0 * * * /usr/bin/find /var/log/astguiclient -maxdepth 1 -type f -mtime +2 -print | xargs rm -f 29 0 * * * /usr/bin/find /var/log/asterisk -maxdepth 3 -type f -mtime +2 -print | xargs rm -f 30 0 * * * /usr/bin/find / -maxdepth 1 -name “screenlog.0*” -mtime +4 -print | xargs rm -f ### fix the vicidial_agent_log once every hour and the full day run at night 33 * * * * /usr/share/astguiclient/AST_cleanup_agent_log.pl 50 0 * * * /usr/share/astguiclient/AST_cleanup_agent_log.pl –last-24hours ## uncomment below if using QueueMetrics #*/5 * * * * /usr/share/astguiclient/AST_cleanup_agent_log.pl –only-qm-live-call-check ### updater for VICIDIAL hopper * * * * * /usr/share/astguiclient/AST_VDhopper.pl -q
### adjust the GMT offset for the leads in the vicidial_list table 1 1,7 * * * /usr/share/astguiclient/ADMIN_adjust_GMTnow_on_leads.pl –debug –postal-code-gmt
### optimize the database tables within the asterisk database
3 1 * * * /usr/share/astguiclient/AST_DB_optimize.pl
### VICIDIAL agent time log weekly summary report generation
2 0 * * 0 /usr/share/astguiclient/AST_agent_week.pl
### roll logs monthly on high-volume dialing systems
#30 1 1 * * /usr/share/astguiclient/ADMIN_archive_log_tables.pl
## uncomment below if using Vtiger
#1 1 * * * /usr/share/astguiclient/Vtiger_optimize_all_tables.pl –quiet
### recording mixing/compressing/ftping scripts
#0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_mix.pl
0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_mix.pl –MIX
0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51,54,57 * * * * /usr/share/astguiclient/AST_CRON_audio_1_move_VDonly.pl
1,4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58 * * * * /usr/share/astguiclient/AST_CRON_audio_2_compress.pl –MP3
#2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59 * * * * /usr/share/astguiclient/AST_CRON_audio_3_ftp.pl –MP3
### kill Hangup script for Asterisk updaters
* * * * * /usr/share/astguiclient/AST_manager_kill_hung_congested.pl
### updater for voicemail
* * * * * /usr/share/astguiclient/AST_vm_update.pl
### updater for conference validator
* * * * * /usr/share/astguiclient/AST_conf_update.pl
### flush queue DB table every hour for entries older than 1 hour
11 * * * * /usr/share/astguiclient/AST_flush_DBqueue.pl -q
### reset several temporary-info tables in the database
2 1 * * * /usr/share/astguiclient/AST_reset_mysql_vars.pl
### remove old recordings more than 7 days old
#24 0 * * * /usr/bin/find /var/spool/asterisk/monitorDONE -maxdepth 2 -type f -mtime +7 -print | xargs rm -f
### Reboot nightly to manage asterisk issues and memory leaks – uncomment if issues arise
#30 6 * * * /sbin/reboot
### remove text to speech file more than 4 days old
#20 0 * * * /usr/bin/find /var/lib/asterisk/sounds/tts/ -maxdepth 2 -type f -mtime +4 -print | xargs rm -f
(ctrl+x and the Y to save)
$ cd /etc/init.d/
$ wget http://download.vicidial.com/ubuntu/vicidial
$ chmod +x vicidial
$ update-rc.d -f vicidial defaults
$ nano /etc/apache2/sites-available/default (add the following lines, Added right before </VirtualHost> )
Alias /RECORDINGS/ “/var/spool/asterisk/monitorDONE/”
<Directory “/var/spool/asterisk/monitorDONE”>
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
<files *.mp3>
Forcetype application/forcedownload
</files>
</Directory>
Then, ctrl+x and the Y to save
$ chmod 0777 /var/spool/asterisk/monitorDONE/
$ /etc/init.d/apache2 restart
$ nano /etc/fstab (add the following line to the end of the file)
tmpfs /var/spool/asterisk/monitor tmpfs rw 0 0
(ctrl+x and the Y to save)
$ shutdown -r 0
(Once system reboots open Terminal and login)
$ sudo su
$ screen -ls (should show at least 6 screens, one of which should be asterisk)
For asterisk CLI:
$ sudo su
$ asterisk -rvvvvvvvvvvvvvvvv
20.In a web browser, go to (http://YOUR_SERVER_IP_ADDRESS/vicidial/admin.php) to see if everything is working.
You should also reboot at this point to make sure everything will start back up properly.
If you get this Fatal error: Allowed memory size of 16777216 bytes exhausted
21.Then, restart Apache
$ /etc/init.d/apache2 restart
[Need help with similar queries? We’d be happy to assist you]
Conclusion
In short, we saw how our Support Techs Install Vicidial scratch on ubuntu.
PREVENT YOUR SERVER FROM CRASHING!
Never again lose customers to poor server speed! Let us help you.
Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.
0 Comments