1 Contributor: Gerhard Zuber <zuber@berlin.snafu.de>
4 Subject: F A X I N G with S A M B A
5 =============================================================================
7 This text describes how to turn your SAMBA-server into a fax-server
8 for any environment, especially for Windows.
11 UNIX box (Linux preferred) with SAMBA
13 mgetty+sendfax package
14 pbm package (portable bitmap tools)
17 mgetty099-May31.tar.gz
18 I got it from: ftp://ftp.gwdg.de/pub/linux/misc/mgetty/mgetty099-May31.tar.gz
21 making mgetty+sendfax running:
22 ==============================
24 go to source tree: /usr/src/mgetty+sendfax
25 cp policy.h-dist policy.h
27 change your settings: valid tty ports, modem initstring, Station-Id
29 #define MODEM_INIT_STRING "AT &F S0=0 &D3 &K3 &C1\\\\N2"
31 #define FAX_STATION_ID "49 30 12345678"
33 #define FAX_MODEM_TTYS "ttyS1:ttyS2:ttyS3"
35 Modem initstring is for rockwell based modems
36 if you want to use mgetty+sendfax as PPP-dialin-server,
37 define AUTO_PPP in Makefile:
39 CFLAGS=-O2 -Wall -pipe -DAUTO_PPP
41 compile it and install the package.
42 edit your /etc/inittab and let mgetty running on your preferred
45 s3:45:respawn:/usr/local/sbin/mgetty ttyS2 vt100
49 and enjoy with the lightning LEDs on your modem
50 your now are ready to receive faxes !
53 if you want a PPP dialin-server, edit
54 /usr/local/etc/mgetty+sendfax/login.config
56 /AutoPPP/ - ppp /usr/sbin/pppd auth debug passive modem
60 Tools for printing faxes:
61 =========================
63 your incomed faxes are in:
64 /var/spool/fax/incoming
70 g3cat $i | g3tolj | lpr -P hp
73 g3cat is in the tools-section, g3tolj is in the contrib-section
74 for printing to HP lasers.
78 Now making the fax-server:
79 ===========================
82 mgetty+sendfax/frontends/winword/faxfilter
86 /usr/local/etc/mgetty+sendfax/
88 prepare your faxspool file as mentioned in this file
89 /usr/local/bin/faxspool
91 if [ "$user" = "root" -o "$user" = "fax" -o \
92 "$user" = "lp" -o "$user" = "daemon" -o "$user" = "bin" ]
94 make sure you have pbmtext (from the pbm-package). This is
95 needed for creaating the small header line on each page.
97 make sure your ghostscript is functional. You need fonts !
98 I prefer these from the OS/2 disks
101 prepare your faxheader
102 /usr/local/etc/mgetty+sendfax/faxheader
105 edit your /etc/printcap file:
111 :if=/usr/local/etc/mgetty+sendfax/faxfilter:sh:sf:mx#0:\
112 :lf=/usr/spool/lp3/fax-log:
117 edit your /usr/local/samba/lib/smb.conf
119 so you have a smb based printer named "fax"
126 Now you have a printer called "fax" which can be used via
127 TCP/IP-printing (lpd-system) or via SAMBA (windows printing).
129 On every system you are able to produce postscript-files you
132 On Windows 3.1 95 and NT:
134 Install a printer wich produces postscript output,
135 e.g. apple laserwriter
137 connect the "fax" to your printer
140 Now write your first fax. Use your favourite wordprocessor,
141 write, winword, notepad or whatever you want, and start
144 Usually each fax has a header page. It carries your name,
145 your address, your phone/fax-number.
147 It carries also the recipient, his address and his *** fax
148 number ***. Now here is the trick:
152 as the recipients fax-number. Make sure this text does not
153 occur in regular text ! Make sure this text is not broken
154 by formatting information, e.g. format it as a single entity.
156 The trick is that postscript output is human readable and
157 the faxfilter program scans the text for this pattern and
158 uses the found number as the fax-destination-number.
160 Now print your fax through the fax-printer and it will be
161 queued for later transmission. Use faxrunq for sending the