Hylafax

Phone_User

Guru
Joined
Jun 9, 2008
Messages
314
Reaction score
0
I was having problems with faxing with Wards scripts (not his fault) and I was looking for somthing a bit more robust, so I started to look at Hylafax. I followed Ed's install instructions and again had some problems.

So, being the type of person I am I read, and read, and read, and spent my weekend playing with this.

******* Updated Jan 13, 2009 @ 7:02 am est ********

This link will download my setup script for Iaxmodem and Hylafax for a single modem.

*******************************

I have set this up on three machines in my Dundi Cloud, I can tell you that it will fax over my Dundi Cloud as well as my VoIP provider (Voicenetwork.ca):D At this time I can only confirm that it works for PiAF 1.3.

If you follow these instuctions you should have a working fax system in about 15 minutes.

First in FreePBX create a new extension of the IAX2 type. Write down the extension number and the password. Save-reload and then go back and edit the extension. You will want to change the port to 4570 or better as well you want to remove 0.0.0.0/0.0.0.0 from deny and add 127.0.0.1/0.0.0.0 to allow. Also disable call waiting and voicemail.

Disable inbound fax support in general settings and add inbound fax detect in your inbound route. Select the extension number above as the fax extension. I found zaptel detection worked well for my zap lines. Still playing with inbound detection on my VoIP trunk. But outbound on my VoIP trunk works great.

****** Updated Jan 13, 2009 @ 7:02 est

Down load the script to your /usr/src directory and chmod +x hylafax_setup.sh

Then ./hylafax_setup.sh
*******************

This will install nessessary utilities, Iaxmodem, Hylafax and do 'MOST' of the configuration for you.

At the end of the script it runs faxsetup. Say yes to everything except your area code, put in yours. Also at then end when it says do you want to add a faxmodem say no.

Once the script is complete, go to /etc/iaxmodem and edit iaxmodem-cfg.ttyIAX you will want to make sure the port is 4570 or better.

Change the peername to the extention you made earlier as well as the secret.

Then change cidname and cidnumber to yours.

Change the codec to ulaw.

Now, cd to /var/spool/hylafax/etc and edit config.ttyIAX. Make sure the fax number and area code are set to yours. Go down the file a bit and you will see local identifier. Change that to your identifier (Name)

Now edit FaxDispatch and change the email address to yours.

Ok, we should almost be done. At the prompt type in init q and then hylafax restart.

If you received errors from the inittab reload go to /etc end edit inittab. Just remove the last two lines and then re-type them in. I had one instance where adding to it from the script caused problems but by deleting and re-adding it fixed it. I don't know why. If you do have to modify inittab do a init q and hylafax restart.

You will also want to start up webmin and go to boot up and shutdown and set Hylafax to start at boot.

To test your fax login to your server and type this sendfax -n -d 5555551212 /usr/src/hylafax_setup.txt . Replace the 5555551212 with your fax number (cannot be your machine your faxing from ) and you should receive a fax with a copy of the install script.

Now you can download and install DandyFax from this post.

DandyFax has been updated to support Hylafax as well you will get an email notification when your fax is sent. (Sendmail has to be set on your system)


Let me know if you run into any problems. And I will help or fix what I can.

*********** Udated Jan 13, 2009 @ 7:02 est

I re-did the scripts with information provided by a couple of users. Should work much better.

Rob
 
Last edited by a moderator:

darmock

PIAF Developer
Joined
Oct 18, 2007
Messages
2,892
Reaction score
98
looks OK but some of the commands may not work as you have some capitalization's in there. you might want to use all lower case and rename the script to hylafaxsetup.sh



Tom
 

Phone_User

Guru
Joined
Jun 9, 2008
Messages
314
Reaction score
0
Thanks, I changed the commands with capitals, however on upload it would not let me send a .sh file.

Rob
 

darmock

PIAF Developer
Joined
Oct 18, 2007
Messages
2,892
Reaction score
98
You got me there I had forgotten about Ward's security feature Oh Well! No Probs. Did you create the text file it on a unix box or a windows box? If on a windows box copy it over to the unix box and run it thru dos2unix. I always do this if I download a script from anywhere just to be sure it is in the proper format for unix

Tom
 

Phone_User

Guru
Joined
Jun 9, 2008
Messages
314
Reaction score
0
No, I made the script on my linux box. Seems to run ok on it. Waiting on someone else to give it a try to see how it works outside of my environment.

Rob
 

ou812

Guru
Joined
Oct 18, 2007
Messages
479
Reaction score
79
I tried your script but no dice, i could not run the script by copying the file into /usr/src but if i created the file using webmin and do a cut and paste with also the chmod i was able to run it but this is what happened.

root@home:/usr/src $ ./hylafax_setup.txt
: command not found: line 2:
base 100% |=========================| 1.1 kB 00:00
updates 100% |=========================| 951 B 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Excluding Packages from CentOS-5 - Base
Finished
Excluding Packages from CentOS-5 - Updates
Finished
Excluding Packages from CentOS-5 - Addons
Finished
Excluding Packages from CentOS-5 - Extras
Finished
Setting up Install Process
Parsing package install arguments
Package glib2-devel - 2.12.3-2.fc6.i386 is already installed.
Resolving Dependencies
--> Running transaction check
---> Package ghostscript.i386 0:8.15.2-9.3.el5 set to be updated
--> Processing Dependency: ghostscript-fonts for package: ghostscript
--> Processing Dependency: urw-fonts >= 1.1 for package: ghostscript
---> Package sharutils.i386 0:4.6.1-2 set to be updated
--> Running transaction check
---> Package urw-fonts.noarch 0:2.3-6.1.1 set to be updated
---> Package ghostscript-fonts.noarch 0:5.50-13.1.1 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
sharutils i386 4.6.1-2 base 201 k
Installing for dependencies:
ghostscript i386 8.15.2-9.3.el5 updates 5.9 M
ghostscript-fonts noarch 5.50-13.1.1 base 801 k
urw-fonts noarch 2.3-6.1.1 base 4.5 M

Transaction Summary
=============================================================================
Install 4 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 11 M
Downloading Packages:
(1/4): sharutils-4.6.1-2. 100% |=========================| 201 kB 00:05
(2/4): ghostscript-8.15.2 100% |=========================| 5.9 MB 01:39
(3/4): ghostscript-fonts- 100% |=========================| 801 kB 00:14
(4/4): urw-fonts-2.3-6.1. 100% |=========================| 4.5 MB 01:27
warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID e8562897
Importing GPG key 0xE8562897 "CentOS-5 Key (CentOS 5 Official Signing Key) <[email protected]>" from http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: ghostscript-fonts ######################### [1/4]
Installing: urw-fonts ######################### [2/4]
Installing: ghostscript ######################### [3/4]
Installing: sharutils ######################### [4/4]

Installed: sharutils.i386 0:4.6.1-2
Dependency Installed: ghostscript.i386 0:8.15.2-9.3.el5 ghostscript-fonts.noarch 0:5.50-13.1.1 urw-fonts.noarch 0:2.3-6.1.1
Complete!
: command not found: line 4:
: command not found: line 6:
--20:39:04-- http://downloads.sourceforge.net/iaxmodem/iaxmodem-1.1.1.tar.gz
Resolving downloads.sourceforge.net... 216.34.181.60
Connecting to downloads.sourceforge.net|216.34.181.60|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://superb-east.dl.sourceforge.net/sourceforge/iaxmodem/iaxmodem-1.1.1.tar.gz [following]
--20:39:05-- http://superb-east.dl.sourceforge.net/sourceforge/iaxmodem/iaxmodem-1.1.1.tar.gz
Resolving superb-east.dl.sourceforge.net... 209.160.66.130
Connecting to superb-east.dl.sourceforge.net|209.160.66.130|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2321262 (2.2M) [application/x-gzip]
Saving to: `iaxmodem-1.1.1.tar.gz'

100%[===========================================================>] 2,321,262 57.2K/s in 39s

20:39:46 (57.9 KB/s) - `iaxmodem-1.1.1.tar.gz' saved [2321262/2321262]

: command not found: line 8:
--20:39:46-- http://downloads.sourceforge.net/hylafax/hylafax-5.2.8-1.fc6.i386.rpm
Resolving downloads.sourceforge.net... 216.34.181.60
Connecting to downloads.sourceforge.net|216.34.181.60|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://superb-east.dl.sourceforge.net/sourceforge/hylafax/hylafax-5.2.8-1.fc6.i386.rpm [following]
--20:39:50-- http://superb-east.dl.sourceforge.net/sourceforge/hylafax/hylafax-5.2.8-1.fc6.i386.rpm
Resolving superb-east.dl.sourceforge.net... 209.160.66.130
Connecting to superb-east.dl.sourceforge.net|209.160.66.130|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1240376 (1.2M) [application/x-redhat-package-manager]
Saving to: `hylafax-5.2.8-1.fc6.i386.rpm'

100%[===========================================================>] 1,240,376 110K/s in 16s

20:40:07 (74.3 KB/s) - `hylafax-5.2.8-1.fc6.i386.rpm' saved [1240376/1240376]

: command not found: line 10:
--20:40:07-- ftp://66.207.112.203/inittab.add
=> `inittab.add'
Connecting to 66.207.112.203:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done. ==> PWD ... done.
==> TYPE I ... done. ==> CWD not needed.
==> SIZE inittab.add ... 176
==> PASV ... done. ==> RETR inittab.add ... done.
Length: 176

100%[===========================================================>] 176 --.-K/s in 0.003s

20:40:09 (51.9 KB/s) - `inittab.add' saved [176]

: command not found: line 12:
tar: iaxmodem-1.1.1.tag.gz: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error exit delayed from previous errors
: command not found: line 14:
./hylafax_setup.txt: line 15: cd: /iaxmodem-1.1.1: No such file or directory
: command not found: line 16:
./hylafax_setup.txt: line 17: ./configure: No such file or directory
: command not found: line 18:
make: *** No targets specified and no makefile found. Stop.
: command not found: line 20:
: command not found: line 22:
cp: cannot stat `/usr/src/iaxmodem-1.1.1/iaxmodem-cfg.ttyIAX': No such file or directory
: command not found: line 24:
chown: cannot access `/etc/iaxmodem/iaxmodem-cfg.ttyIAX': No such file or directory
: command not found: line 26:
: command not found: line 28:
error: open of hylafax-5.2.8-1.fc6.i386.rpm failed: No such file or directory
: command not found: line 30:
./hylafax_setup.txt: line 31: cd: /var/spool/hylafax/etc: No such file or directory
: command not found: line 32:
--20:40:10-- ftp://66.207.112.203/FaxDispatch
=> `FaxDispatch'
Connecting to 66.207.112.203:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done. ==> PWD ... done.
==> TYPE I ... done. ==> CWD not needed.
==> SIZE FaxDispatch ... 107
==> PASV ... done. ==> RETR FaxDispatch ... done.
Length: 107

100%[===========================================================>] 107 --.-K/s in 0.003s

20:40:11 (31.6 KB/s) - `FaxDispatch' saved [107]

: command not found: line 34:
: command not found: line 36:
cp: cannot stat `/usr/src/iaxmodem-1.1.1/config.ttyIAX': No such file or directory
: command not found: line 38:
chown: cannot access `/var/spool/hylafax/etc/config.ttyIAX': No such file or directory
: command not found: line 40:
: command not found: line 42:
: command not found: line 44:
cp: cannot stat `/etc/itnittab': No such file or directory
: command not found: line 46:
: command not found: line 48:
: command not found: line 50:
./hylafax_setup.txt: line 51: faxsetup: command not found
: command not found: line 52:
: command not found: line 54:


gary.
 

jroper

Guru
Joined
Oct 20, 2007
Messages
3,832
Reaction score
71
Hi

A couple of minor alterations to get the script to run, I've not test further but looking good so far.

Code:
tar zxvf iaxmodem-1.1.1.tag.gz becomes tar zxvf iaxmodem-1.1.1.tar.gz

cd /iaxmodem-1.1.1 becomes cd iaxmodem-1.1.1

Thank you for your efforts

Joe
 

Phone_User

Guru
Joined
Jun 9, 2008
Messages
314
Reaction score
0
Ou812. Sorry for that. I updated the scripts. I had some typos in it that I did not notice. They are fixed now. Just ran it on a new install and did not get any errors.

Jroper, thanks for pointing that out. I re-did the scripts and put it on my ftp with the others. Just to be on the safe side I also ran them throught dos2unix.

Rob
 

Members online

No members online now.

Forum statistics

Threads
25,778
Messages
167,504
Members
19,199
Latest member
leocipriano
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top