1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148
|
<!--startcut ==========================================================-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<title>Hylafax Issue 25</title>
</HEAD>
<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#A000A0"
ALINK="#FF0000">
<!--endcut ============================================================-->
<H4>
"Linux Gazette...<I>making Linux just a little more fun!</I>"
</H4>
<P> <HR> <P>
<!--===================================================================-->
<center>
<H2>Hylafax</H2>
<H4>By <a href="mailto:dp4022@speedy.udg.es">Dani Pardo</a></H4>
</center>
<P> <HR> <P>
Our company network is based on some sparcs and linux servers and windows
(3.11 and 95) clients, wich telnet to the server to use a Cobol-written
accounting program. After passing from nfs to samba (imagine the user's fun
when they first discovered winpopup), we decided to try some fax software.
We had some alternatives: comercial (and really expensive) Un*x software, the
NT alternative, and the free software solution.
<P>
NT was an unfriendly and unflexible solution, based on licenses
per user, and we didn't want to spend thousands of dollars buying an unix fax
server. Having had the good samba experience, we decided to give hylafax
a try.
<P>
HylaFax (originally flexfax) is made by Silicon Graphics, and
distributed with source code, availiable at <a
href="http://www.vix.com/hylafax/">http://www.vix.com/hylafax/</a>.
Latest version is 4.0pl1. Get also the tiff library. If you get the source,
you must first compile and install the tiff library (in order to convert
tiff files to .g3 fax format). You must also have Ghostscript up and running
to convert from Postscript to g3. As experience: use the latest ghostscript
you can get (unless you would like to see your customer receiving ghostscript
error messages by fax).
<P>
After having the tiff library installed, hylfax compiles at first under
an stardard linux distribution, placing binaries under /usr/local, and
/var/spool/fax for the jobs.
<P>
Once installed, configure the system by running /usr/local/sbin/faxsetup.
It will add the fax user, modify /etc/services and /etc/inetd.conf (hylafax
listens to ports 4559 and 444). After some other confguration, faxsetup will
run faxaddmodem, in order to configure wich modem(s) to use. Faxaddmodem
will talk to the modems you've specified, getting its parameters, and let you
configure other stuff.
<P>
Hylafax consists in two daemons: hfaxd (the server), and hfaxq (the
priorityzed Round-Robin scheduler). You should run faxmodem to tell the scheduler wich modem(s) it
can use. If you've also planed to receive calls, you'll have to set up
faxgetty, that will place incoming faximiles into /var/spool/fax/incoming,
respecting also data calls (pasing the control to getty/mgetty).
You should also add these daemons in /etc/rc.d. Now you can check the
server works by telneting yourself at port 4559.
<P>
Some useful programs you will use are sendfax (files), faxstat (to
check the queue), and faxrm to remove jobs. Sendfax calls faxq, sendpage, etc.. It also
invoques ghostscript for the image format translation, so you'll normally
send postscript or ascii text. If you want to send other formats, check out
/usr/local/lib/fax/typerules. Other interesting configuration files reside
at /var/spool/fax/etc: If you run in trouble with your modem, you'll
probably want to check them.
<P>
And to finish with the server side, it's not a bad idea to modify
crontab to invoque faxqclean, in order to remove sent faxes.
<H4>The Client Side</H4>
<P>
Once you've hylafax up and running, it's time to configure the
clients: There's MacFlex for Macintosh users, and WinFlex for Windows users.
With Winflex (and MacFlex too), you'll install a generic postscript printer (I
usually use a Apple Laserwriter Pro600 window's driver). So, when something
is sent to that printer, a window appears, asking for the phone number. You
can also check the queue, remove jobs, etc. Once the fax is sent, the user
will receive an e-mail confirming the job has been done with some other
useful information. HylaFax creators claim that "you'll never
loose a fax",
and I must say that this aspect has been taken with a great effort.
<P>
WinFlex, although a good solution, is not perfect (the interface
with the printer driver is a bit poor), and doesn't use all hylafax
features yet (any volunteer?).
<P>
Another feature yet to be perfectioned, this time a server feature,
is the automatic cover page generation: I've really had pains to create the
cover page, much postscript knowledge needed. In our company, we finally
wrote the cover page as a normal document with our word processor, and copy
it in a samba share.
<H4>Let's Have Fun</H4>
<P>
The real party began when I was told about the accounting department
special need. They needed to send the facturation automatically by fax. That
facturation was generated by the cobol program as an ascii file, up to 20
pages. But ALL pages had to inlcude the company logo at top, and some text
at the left side. That seemed to be a harder issue than the cover page one,
but after some scripting and some C, and thanks giving to hylafax flexibility,
I could write a printer filter that:
<ul>
<li>gets the phone number from the ascii file.
<li>divides the ascii file into pages (pages where separated by an EOP)
<li>converts each page to pbm (portable bitmap) with pbmplus package
<li>Mixes the pbm logo with each page
<li>convert all mixed pages into postscript (with ghostscript)
<li>Join all postscript pages into one, and finally calls sendfax.
</ul>
<P>
Now, I don't even want to think how I'd solve this problem with a
Windows server.
<P>
<H4>Conclusions</H4>
<P>
HylaFax is a versatile, powerful and flexible fax software, although
missing some features. It's highly configurable, provides a good amount of
debugging information, its secure, and it's free.
<P>
There's also a mailing list, where you can get patches and solve some
problems. Once again, free software has proven me its
strength.
<!--===================================================================-->
<P> <hr> <P>
<center><H5>Copyright © 1998, Dani Pardo <BR>
Published in Issue 25 of <i>Linux Gazette</i>, February 1998</H5></center>
<!--===================================================================-->
<P> <hr> <P>
<A HREF="./lg_toc25.html"><IMG ALIGN=BOTTOM SRC="../gx/indexnew.gif"
ALT="[ TABLE OF CONTENTS ]"></A>
<A HREF="../lg_frontpage.html"><IMG ALIGN=BOTTOM SRC="../gx/homenew.gif"
ALT="[ FRONT PAGE ]"></A>
<A HREF="./gm.html"><IMG SRC="../gx/back2.gif"
ALT=" Back "></A>
<A HREF="./sorensen.html"><IMG SRC="../gx/fwd.gif" ALT=" Next "></A>
<P> <hr> <P>
<!--startcut ==========================================================-->
</BODY>
</HTML>
<!--endcut ============================================================-->
|