Following open source softwares are required for ICTFAX full functionality
To install above requirements issue following commands at shell prompt
yum -y install httpd mysql-server mysql mysql-devel
yum -y install php php-common php-cli php-gd php-imap php-curl php-mysql
yum -y install perl perl-DBD-mysql
yum -y install ghostscript ImageMagick poppler-utils curl sendmail sendmail-cf
following dependencies are required for asterisk installations
yum -y install gcc-c++ make libxml2-devel mysql-devel ncurses ncurses-devel libtiff libtiff-devel gtk+
also install yudit for text to pdf support
cd /usr/src
wget "http://www.yudit.org/download/yudit-2.9.2.tar.gz"
tar xzf yudit-2.9.2.tar.gz
cd yudit*
./configure --prefix=/usr/local
make
make install
before continue, make sure that MySQL and Apache is running
chkconfig httpd on
chkconfig mysqld on
service httpd start
service mysqld start
Note: Following instruction are for asterisk 1.6 installation, If you are willing to install higher version of Asterisk like Asterisk 1.8 then please visit Asterisk 1.8 installation Guide
download spandsp software
wget http://www.soft-switch.org/downloads/spandsp/spandsp-0.0.6pre18.tgz
extract / compile and install
tar xzf spandsp-0.0.6pre18.tgz
cd spandsp-0.0.6
./configure --prefix=/usr
make
make install
Prepare you system for asterisk
useradd -c "Asterisk PBX" -d /var/lib/asterisk asterisk
mkdir /var/run/asterisk
mkdir /var/log/asterisk
chown -R asterisk:asterisk /var/run/asterisk
chown -R asterisk:asterisk /var/log/asterisk
chown -R asterisk:asterisk /var/lib/php/session/
download asterisk
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-1.6.2-current.tar.gz
extract / configure
tar zxf asterisk-1.6.2-current.tar.gz
cd asterisk-1.6.2*
./configure
issue following command and make sure "Fax Application" exist and marked under "Application" then save and exit
make menuselect
now you can compile asterisk and install
make
make install
make config
download asterisk addons
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-addons-1.6.2-current.tar.gz
extract / configure
tar zxf asterisk-addons-1.6.2-current.tar.gz
cd asterisk-addons-1.6*
./configure
issue following command and make sure "res_config_mysql" exist and marked under "Resource Modules" then save and exit make menuselect
compile and install make make install
go into asterisk sound directory
cd /var/lib/asterisk/sounds
download sounds and extract here
wget http://downloads.asterisk.org/pub/telephony/sounds/asterisk-core-sounds-en-alaw-current.tar.gz
tar zxvf asterisk-core-sounds-en-alaw-current.tar.gz
first of all change apache owner to asterisk in /etc/httpd/conf/httpd.conf
sed -i 's/User apache/User asterisk/g' /etc/httpd/conf/httpd.conf
sed -i 's/Group apache/Group asterisk/g' /etc/httpd/conf/httpd.conf
service httpd restart
download and extract ictfax_0.3.2.tar.gz archive contents into /usr directory
wget http://sourceforge.net/projects/ictfax/files/ictfax-0.3.2.tar.gz/download
tar -C /usr -xzf ictfax-0.3.2.tar.gz
grant to asterisk proper permissions on ictfax directory
mkdir -p /usr/ictfax/wwwroot/files/mail/temp
chown -R asterisk:asterisk /usr/ictfax
chmod -R u+rw /usr/ictfax/wwwroot/files
chmod u+rw /usr/ictfax/logs
create "ictfax" database in mysql
echo 'CREATE DATABASE ictfax;' | mysql --user=root --password=ROOT_PASSWD
create tables in "ictfax" while using /usr/ictfax/database/ictfax.sql
mysql --user=root --password=ROOT_PASSWD ictfax < /usr/ictfax/database/ictfax.sql
create mysql procedures with /usr/ictfax/database/ictfax_proc.sql
mysql --user=root --password=ROOT_PASSWD ictfax < /usr/ictfax/database/ictfax_proc.sql
above command will also create a user "ictfaxuser" with "ictfax786" as default. it is strongly recommended to change default password.
NOTE: When you need to change database password please make sure that you have changed password in all following files
/usr/ictfax/ictfax.conf
/usr/ictfax/wwwroot/sites/default/settings.php
/etc/asterisk/res_mysql.conf (it occur in this file 3 time)
create a symbolic link for /usr/ictfax/wwwroot in /var/www/html
ln -s /usr/ictfax/wwwroot /var/www/html/ictfax
edit /usr/ictfax/wwwroot/sites/default/settings.php and update $base_url replace 127.0.0.1 with your public IP or domain name. like
$base_url = 'http://FAX_DOMAIN.TLD/ictfax';
and if you have changed "ictfaxuser" password in mysql then also update $db_url like
$db_url = "mysql://ictfaxuser:ictfax786@localhost/ictfax";
save settings.conf now with your browser visit http://FAX_DOMAIN.TLD/ictfax and login with default admin user "admin" password "demoictfax"
edit /usr/ictfax/ictfax.conf and check / update database access info (dbuser & dbpass) as per your setting for "ictfax" database
also edit /usr/ictfax/etc/asterisk/res_mysql.conf and check / update all instances of dbuser and dbpass
copy all files from /usr/ictfax/sounds into /var/lib/asterisk/sounds
copy all files from /usr/ictfax/etc/asterisk into /etc/asterisk overwrite if prompted
copy all files from /usr/ictfax/agi-bin into /var/lib/asterisk/agi-bin
create required directories and set permission on them
mkdir -p /var/spool/asterisk/tmp
mkdir -p /var/spool/asterisk/outgoing
mkdir -p /var/spool/asterisk/fax/inbox
mkdir -p /var/spool/asterisk/fax/outbox
chown -R asterisk:asterisk /var/spool/asterisk
chown -R asterisk:asterisk /var/lib/asterisk
chmod -R u+rw /var/spool/asterisk
chmod -R u+rx /var/lib/asterisk/agi-bin
restart asterisk so changes can take affect
service asterisk restart
edit /usr/ictfax/ictfax.conf and change company name and email according to your requirements
and if you have changed 'ictfaxuser' password in database then also update db password in ictfax.conf