Installation Guide

Post queries and issues that you found during ictfax installation

Installation Guide

Postby falak » Fri Jun 22, 2012 1:49 pm

1: Introduction
===============

ICT-FAX is a unique and complete faxing solution with billing featuring T.38 support, Email2Fax, Web2Fax,
Fax2Email and Billing.

2: Install Basic System Requirements
====================================
1. CentOs 6
2. Apache 2
3. MySQL 5
4. PHP 5.3.3
5. php-mysql
6. php-gd
7. php-curl
8. php-imap
9. perl
10. perl-DBD-mysql
11. libtiff
12. ghostscript
14. ImageMagick
15. poppler-utils
15. curl
16. mysql-devel
17. sendmail

To install above requirements issue following commands at shell prompt

Code: Select all
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 Freeswitch installations

Code: Select all
yum -y install git make

also install yudit for text to pdf support
Code: Select all
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

Code: Select all
chkconfig httpd on
chkconfig mysqld on
service httpd start
service mysqld start



3: Freeswitch Installation
========================
ICTFax is based on Plivo Framework.
So you need to setup and run freeswitch provided by Plivo.org.
Instructions on how to install Freeswitch are given
at http://www.plivo.org/get-started/ and repeated here for your convenience:

* Download and run the FreeSWITCH installer on your system
Note: Currently, this installer is tested on CentOS > 5.5 and Debian-based distros.
# wget --no-check-certificate https://github.com/plivo/plivoframework ... install.sh
# chmod +x install.sh
# ./install.sh

* Run FreeSWITCH
Run in Foreground
# ./usr/local/freeswitch/bin/freeswitch
Run in Background
# ./usr/local/freeswitch/bin/freeswitch -nc

Setup and Run Plivo Framework
-----------------------------------------------

Locate the folder "plivo-devel" in the extracted ICTFax directory.

1. Stop plivo service (if any) and clear /usr/local/plivo

2. Copy and Paste plivo-devel folder in /usr/

3. Go to /usr/plivo-devel and Run plivo_install.sh using following command:
#./plivo_install.sh /usr/local/plivo

5. Go to /usr/local/plivo/bin directory and Run plivo service using the following command:
#./plivo start

NOTE: There may be some errors while starting plivo cache server. But make sure that plivo default server is running.

Plivo Configurations:
-----------------------------

1. Go to /usr/local/plivo/etc/plivo/default.conf
2. Enable EXTRA_FS_VARS by removing # before it.
3. Set variable in plivo config as EXTRA_FS_VARS = variable_duration
4. Set Incoming DEFAULT_ANSWER_URL, DEFAULT_HANGUP_URL

DEFAULT_ANSWER_URL = http://127.0.0.1/ictfax/index.php?q=ictfax/receive_fax
DEFAULT_HANGUP_URL = http://127.0.0.1/ictfax/index.php?q=ict ... ax_billing

Modify above urls according to your installation settings.
Don't forget to remove “#” sign before DEFAULT_HANGUP_URL and EXTRA_FS_VARS.


4: ICT FAX Installation
=======================

4.1: Database
-------------

* Database Installation:
Create "ictfax" database in mysql (Run 'CREATE DATABASE ictfax' query on mysql)


4.2: Frontend / Web GUI
------------------------------
Locate the folder "wwwroot" in the extracted ICTFAX directory.
Rename this folder to ictfax and copy-paste it to /usr directory.

1. Create a symbolic link for /usr/ictfax in /var/www/html
ln -s /usr/ictfax /var/www/html/ictfax

2. Now visit http://DOMAIN.COM/ictfax
and follow the installation instructions for
ICTFax (drupal based) front end installation.

3. Once you are done with installation, visit the website and login as site administrator with username and password
that you provided during installation.

4. Locate the folder "ictpbx" in the extracted ICTFAX directory. Copy it and move it to /usr/ictfax/sites/all/modules.

5. Now comeback to Web GUI and go to Modules menu and enable all modules in "ICTPBX System" Package.

6. Now you'll see menu item Fax Account, ICTPBX System and others in your Navigation Menu.

5: Email to FAX / FAX to Email service (optional)
===============================================

1. make sure that your desired domain's MX records are properly configured for email2fax server.
2. install sendmail service and enable sendmail service at startup.
2a. Also make sure you have created linux user "freeswitch".
3. enable sendmail to listen on public ip address look for following line in /etc/mail/sendmail.mc

DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl

4. and change line mentioned above into

DAEMON_OPTIONS(`Port=smtp, Addr=0.0.0.0, Name=MTA')dnl

5. apply changes

m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf

6. Add freeswitch to list of trusted user

echo "freeswitch" >> /etc/mail/trusted-users

7. Add your domain name in allowed local domain list to let sendmail receive mails for that domain

echo "FAX_DOMAIN.COM" >> /etc/mail/local-host-names

8. route all mails for none-existing addresses into freeswitch mailbox so we can receive emails for addresses like xyz_number@FAX_DOMAIN.COM

echo '@FAX_DOMAIN.COM freeswitch' >> /etc/mail/virtusertable
makemap hash /etc/mail/virtusertable < /etc/mail/virtusertable

9. grant proper permission to apache user on mail folder

chmod +t /var/spool/mail

10. restart sendmail service so changes can take affect

service sendmail restart

11. login at ictfax web interface as admin (ictfax)[[BR]]
12. goto administrator => mailhandler => Add Mailbox and set following fields
E-mail address: fax@FAX_DOMAIN.COM
Folder: /var/spool/mail/freeswitch
POP3 or IMAP Mailbox: IMAP
Mailbox domain: *** must be empty ***
Security: Require password (leave empty if you haven't set already)
Delete messages after they are processed?: TICK / Yes

13. setup cronjob so incoming email can be processed after every 5 minutes

echo 'MAILTO=""' > /tmp/freeswitch_cron.txt
echo "*/5 * * * * wget -O /dev/null 'http://FAX_DOMAIN.COM/cron.php?cron_key=your_key' 2>/dev/null" >> /tmp/freeswitch_cron.txt
crontab -l >> /tmp/freeswitch_cron.txt
crontab /tmp/freeswitch_cron.txt

14. You can find your cron url by logging in at your web interface as admin. Go to Reports -> Status Reports.
Copy your Cron URL and paste at the above URL and then run above lines at the command prompt.

NOTE: make sure that /etc/hosts.allow is properly configured for accepting mails, and
smtp port (25) is not blocked by firewall. if so Add following line to
/etc/sysconfig/iptables above the last reject/drop rule:

-A INPUT -m state --state NEW -m tcp -p tcp --dport 25 -j ACCEPT

Also DO NOT enable CLEAN URLS, because plivo has been configured to use default URLS.

15. Create a content type "fax" with three additional fields "to" of type text, "from" of type text" and "file" of type file.
Go to Admin => Structure => Feeds Importer => Mailhandler nodes. Click Override and then in Processor field make sure Fax Processor is selected. Click Mapping in fax processor. Make sure that your to, from and file fields are correctly mapped to toaddress, fromaddress and attachments respectively.

16. Now you are ready to send faxes through your email. See Admin/User Guide for further details.


===========
http://www.ictinnovations.com
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby msalaque » Thu Jun 28, 2012 2:46 am

wget https://github.com/plivo/plivo/raw/mast ... install.sh path is broken

What is the updated path please ?


thanks
Salaque
msalaque
 
Posts: 3
Joined: Thu Jun 28, 2012 2:44 am

Re: Installation Guide

Postby falak » Sat Jun 30, 2012 3:12 pm

Plivo.org has updated the path of their repository. Following is the updated path:
https://github.com/plivo/plivoframework/raw/master/scripts/plivo_install.sh

I have also updated it in the installation instruction.

msalaque wrote:wget https://github.com/plivo/plivo/raw/mast ... install.sh path is broken

What is the updated path please ?


thanks
Salaque
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby eric » Fri Jul 06, 2012 7:51 pm

I was able to follow all the steps above, and all modules registered successfully except one, the ICTFAX module. I got the bow error when registering that module:

I have curl installed. Is there something I am missing or something that did not install correctly?


Code: Select all
Exception: Curl extension is required for PlivoRestClient to work in require_once() (line 9 of /usr/ictfax/modules/ictpbx/ictfax/lib/plivohelper.php).
eric
 
Posts: 2
Joined: Fri Jul 06, 2012 6:15 pm

Re: Installation Guide

Postby falak » Sat Jul 07, 2012 7:49 am

After installing curl don't forget to restart your web server. Also make sure you have installed plivo and freeswitch before and they are running.

eric wrote:I was able to follow all the steps above, and all modules registered successfully except one, the ICTFAX module. I got the bow error when registering that module:

I have curl installed. Is there something I am missing or something that did not install correctly?

Code: Select all
Exception: Curl extension is required for PlivoRestClient to work in require_once() (line 9 of /usr/ictfax/modules/ictpbx/ictfax/lib/plivohelper.php).
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby mita2000 » Mon Aug 13, 2012 7:58 am

I have issues with step 15. , I don't have content type "fax". I installed everything before that and all ICTFAX modules are active.

Thanks,
Igor
mita2000
 
Posts: 2
Joined: Mon Aug 13, 2012 7:54 am

Re: Installation Guide

Postby falak » Tue Aug 14, 2012 6:58 am

You will have to create this content type from the admin interface. Open ictfax web interface in the browser and Login as Admin, then go to => Structure => content type. Click "Add content type". Set its name as "fax" and leave other parameters as default if you don't know. Click "Save and add fields" button at the bottom. Now create new fields for this content type as mentioned in the guide.

mita2000 wrote:I have issues with step 15. , I don't have content type "fax". I installed everything before that and all ICTFAX modules are active.

Thanks,
Igor
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby falak » Mon Jul 21, 2014 9:57 am

Have you disabled selinux? Also try disabling iptables? Run following commands at shell:

Code: Select all
# setenforce 0

and
Code: Select all
# service iptables stop

If you have already done so, please let me know.
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby falak » Tue Jul 22, 2014 9:28 am

You said that you are able to see Drupal page but no 'ictfax' page. That means you are able to log in as administrator in the web portal? Do you see the navigation menu with menu items like Contact, ICTPBX System, Fax Account etc after login?
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby falak » Thu Jul 24, 2014 11:02 am

This seems fine. "ICTFax system" has the two options that you mentioned. Where as, in admin guide, there is "ICTPBX system" where you configure your trunk. ICTPBX system menu item is available in the navigation menu in the front page left sidebar. If it is not visible there, manually add navigation menu to sidebar from "Admin" -> "Structure" -> "Blocks".
falak
Site Admin
 
Posts: 166
Joined: Tue Jan 17, 2012 7:33 am

Re: Installation Guide

Postby johnny2000 » Mon Sep 29, 2014 1:50 pm

I am now on step 12, but somehow I could not locate where the following is:

" 12. goto administrator => mailhandler => Add Mailbox and set following fields
E-mail address: fax@FAX_DOMAIN.COM
Folder: /var/spool/mail/freeswitch
POP3 or IMAP Mailbox: IMAP
Mailbox domain: *** must be empty ***
Security: Require password (leave empty if you haven't set already)
Delete messages after they are processed?: TICK / Yes"

Under modules the mailhanlder is enabled, but somehow I could not find it as what step 12 is trying to say. Anyone who could point me to the right direction? Thank you in advance.
johnny2000
 
Posts: 5
Joined: Sun Sep 28, 2014 8:46 pm


Return to Installation

Who is online

Users browsing this forum: Google [Bot] and 1 guest

cron