Giter Club home page Giter Club logo

autofax's Introduction

AUTOFAX (Version 0.46125) - english

NAME
SYNOPSIS
SHORT DESCRIPTION
INSTALLATION
USAGE
OPTIONS
PRECONDITIONS
AUTOMATICALLY INSTALLED SOFTWARE PACKAGES
IMPLICATIONS
UNINSTALLING
RETURN CODES
ERRORS
PROGRAM MODIFICATION
LIABILITY
AUTHOR


NAME

autofax − Fax server functionality: induces automatic fax transmission of files, naming of received faxes and logging of all of them in a database
(manpage-Hilfe in deutsch verfügbar: ’man autofax’ oder ’man -Lde autofax’)

SYNOPSIS

autofax [-<shortopt>|--<longopt> [<supplement>]] ...

SHORT DESCRIPTION

autofax offers quasi the functionality of a fax server, which can be useful for some also behind a fast data line.
autofax
is a command line program to remit files of a certain directory automatically to hylafax (in case a linux-compatible modem is installed) and/or capisuite (in case a fritzcard 2.0 or 2.1 is installed), if the fax number is integrated in the file name as requested. Furthermore, autofax holds the posted faxes in a mariadb database.
Additionally, received faxes from hylafax/capisuite can be named automatically with the sender’s name, according to his fax number, and stored.
The usability within a network (may also be a windows network with only one linux machine) is being accomplished by automatic integration of all relevant directories into a samba server. It could be complemented by a frontend for the mariadb database.

INSTALLATION

First, please read the chapters ’functionality’, ’preconditions’,’automatically installed software packages’ and ’implications’ below. Then, if connected to the internet, call (e.g. by coying the line and pasting it into a terminal):
N=autofax;P=${N}_inst.sh;cd ~;wget https://raw.githubusercontent.com/autofax/$N/master/install.sh -O$P&&sh $P

At last, call:
autofax

and answer some questions of the program.
The first execution and the first processing of a sent/received fax with each of hylafax and/or capisuite may take some time and need some additional input, respectively.
autofax -again
for each of then. Hereby the necessary program installations for future fax receiving will simultaneously be completed.

USAGE

Ideally, the program should have installed itsself after the first call(s) (see above) and one-time answering of some questions in a self-running way.
Then a directory e.g. ’tobefaxed’ exists, in which e.g. users in a network (e.g. via the above mentioned samba share) can deposit files to be faxed, e.g.
"Medical report on Frank Ill to Dr. Healthy and Frank Ill to fax 099 987654321 and 088 887654321.doc" (it could also be e.g. an *.xls, a *.jpg, a *.tif, a *.txt, a *pdf file; the section ’ to Dr. Healthy and Frank Ill’ is optional for the later allocation of the fax number(s) in the database, it may also be obmitted; on the other hand, if the program can assign the last (1-)3 faxes to a certain addressee clearly, the section ’ to fax 099 987654321 and 088 887654321’ may be obmitted).
When autofax is called for the next time (per default 2 minutes), the above mentioned example file will initially be copied and renamed into
"Medical report on Frank Ill to Dr. Healthy to fax 099 987654321.doc" and
"Medical report on Frank Ill to Frank Ill to fax 088 887654321.doc" and converted into the pdf-files
"Medical report on Frank Ill to Dr. Healthy to fax 099 987654321.pdf" and
"Medical report on Frank Ill to Frank Ill to fax 088 887654321.pdf".
Those are subsequently being relayed to hylafax or Capisuite and from there sent.
Simultaneously they are being moved from ’tobefaxed’ to the waiting directory, e.g. ’waitingfaxes’ and recorded in the spool table spooltab.
Faxes which are placed by a user in the directory ’tobefaxed/2200’ will be handled starting at 10 p.m., if autofax is running.
If subdirectories in ’tobefaxedfR’ are found named with a date or time (e.g. ’20180101 0800’ or ’2200’), the contained faxes will be processed after that time an in the first case the subdirectory will then be deleted if empty.
At each call, autofax checks the status of hylafax and/or Capisuite. The Finishing of a fax process there causes autofax to move the source files (here the above mentioned .doc- and .pdf-files) from the waiting directory to one or several archive directories or a directory for failed faxes and to move their database record from ’spooltab’ to the archive table ’outa’.
Further on, incoming faxes via hylafax or Capisuite are being transmitted to an incoming directory and if applicable named including the sender’s name. To this purpose, customizeable sql commands are being used, if specified.
Depending on operating system, accessability and preferences the users thus could look up the status of their faxes in the above mentioned directories, in the database tables or by calling ’autofax’, ’autofax -lista’, ’autofax -listf’ or ’autofax -listi’.

OPTIONS

autofax -?’ or ’autofax -h’ shows the important command line options and ’autofax -lh’ all of them. Some options (e.g. the sql commands for finding an addressee from the fax number) cannot be set via the command line, but only via the configuration file, which can be edited directly by ’autofax -vi’ or interactively by ’autofax -rf’.
Options which are not saved:
-v, --verbose
: screen output more verbose
-lfn, --logfilenew
: delete log file afore
-cf, --conffile <string>
: uses configuration file <string> instead of ’’
-sqlv, --sql-verbose
: screen output with SQL commands
-ia, --interactive
: all parameters will be prompted (some of them not shown here)
-noia, --nointeraction
: no questions, e.g. for a call of autofax within cron
-delf, --deletefax
: delete a fax with query
-delo, --deleteorphans
: delete entries from ‘spool‘ without detection of file in waiting directory or capisuite fax or hylafax
-dela, --deleteallwaiting
: delete all waiting faxes and associated entries from ‘spool
-again, --receiveagain
: present a received fax again
-red, --redirect
: redirect outgoing fax ahead by the other channel
-csf, --correctsuccessflag
: in the database table ‘outa‘ the success flag is being corrected
-rod, --reorderdir
: Examine files in waiting,failed a.faxed directory against the tables ‘outa‘ and put them to order
-st, --stop
: stop autofax
-listo, --listoutg
: lists entries from ‘outa‘ with success flag
-listf, --listfailed
: lists entries from ‘outa‘ without success flag
-listi, --listinca
: lists entries from ‘inca
-listw, --listwaiting
: lists waiting faxes
-s, --search <string>
: Look in processed faxes for <string>: ’’
-n, --reccount <zahl>
: No. of listed entries = <no> instead of ’30
-info, --version
: shows the program version
-vi, --vi
: edit/view configuration and log file (finish with ’:qa’)
-vc, --vc
: edit capisuite log files (finish with ’:qa’)
-vh, --vh
: edit hylafax modem configuration file (finish with ’:qa’)
-vs, --vs
: edit source files (finish with ’:qa’)
-h, --help
: Explanation of frequent options
-lh, --longhelp
: Explanation of all options
Options to be saved in the configuration file: (preced. ’1’=don’t save, ’no’=contrary, e.g. ’-noocra’,’-1noocri’):
-lg, --language <string>
: Language/Sprache/Lingue/Lingua [deutsch,englisch] ’e
-ldr, --logdir <path>
: choses <path> as log directory, currently ’/var/log
-lf, --logfilename <string>
: log file <string> (in path ’/var/log’) will be used instead of ’autofax.log
-l, --log
: put detailed logs in file ’/var/log/autofax.log’ (otherwise shorter)
-tdr, --tofaxdir <path>
: faxes the files from <path> instead of ’/var/autofax/tobefaxed
-wdr, --waitdir <path>
: files are waiting in <path> instead of ’/var/autofax/waitingfaxes
-ndr, --notfaxeddir <path>
: Failed Faxes are collected here and not in ’/var/autofax/notfaxed
-rdr, --receiveddir <path>
: directory for recieved faxes ’/var/autofax/recvdir
-capi, --takecapi
: use capisuite or not
-hyla, --takehyla
: use hylafax or not
-fc, --firstcapi
: try to send faxes primarily via capisuite or not
-fh, --firsthyla
: try to send faxes primarily via hylafax or not
-mod, --hmodem <string>
: Modem used for hylafax, instead of ’’
-mc, --maxcapitries <zahl>
: try Hylafax after <no> tries of Capisuite instead of ’3
-mh, --maxhylatries <zahl>
: try Capisuite after <no> tries of Hylafax instead of ’3
-cuser, --cuser <string>
: takes the linux user <string> for capisuite and/or samba instead of ’’
-crct, --cringcount <zahl>
: No. of bell rings until Capisuite accepts the call, instead of ’1
-hrct, --hringcount <zahl>
: No. of bell rings until hylafaxs accepts the call, instead of ’2
-hmd, --hmaxdials <zahl>
: No of dialing retries in hylafax, instead of ’11
-it, --immediatelytarget
: copy faxes into target directory irrespective of faxing success or not
-ocri, --ocri
: Text from received faxes will be filtered or not
-ocro, --ocro
: Text from sent pictures will be filtered or not
-tfs, --tofaxstr <string>
: the fax number will be expected after <string> instead of ’to fax
-tcfs, --tocfaxstr <string>
: fax no.for fax with preference to capisuite is expected after <string> instead of ’to cfax
-thfs, --tohfaxstr <string>
: fax no.for fax with preference to hylafax is expected after <string> instead of ’to hfax
-ts, --tostr <string>
: name of addressee is expected after <string> instead of ’ to
-ands, --andstr <string>
: separating string <string> for multiple addressees/tel’numbers, instead of ’and
-host, --host <string>
: takes the database on host <string> instead of ’localhost
-muser, --muser <string>
: takes the user <string> for MySQL/MariaDB instead of ’user
-mpwd, --mpwd <string>
: takes the password <string> for MySQL/MariaDB
-db, --database <string>
: uses the database <string> instead of ’autofax
-fd, --find <zahl>
: version 1,2 or 3 of filefind (variable performance differences instead of ’3
-cm, --cronminutes <zahl>
: every how many minutes shall autofax be called in crontab (0=not at all), instead of ’2
-autoupd, --autoupdate
: Update program automatically or not -1lg.SH FUNCTIONALITY

When called, ’autofax’ accomplishes the following:

1) The current hardware is being checked.
a)
with the command ’lspci | grep -i isdn’ for a fritz card.
b)
with the command ’stty -F’ for a fax modem.

2) The fax configuration file fax.conf of capisuite is read, if it exists

3) Further defaults from the program code are assigned which can be overloaded by the autofax configuration file (see 4), command line arguments or anwers to questions (see 5).

4) Defaults are loaded from the configuration file, if it exists (per default autofax.conf in the same directory as autofax, per default /usr/local/sbin/autofax))

5) Questions are asked, if values are missing from the configuration file (see 4) or if a command line option demands interacitivity.

6) The directory of hylafax is beeing determined (/var/spool/hylafax or /var/spool/fax), if hylafax is installed.

7) Directories used by the users for fax files to be sent, for waiting faxes, for fax files already sent, for failed faxes and for received faxes are being checked and created if needed. Thereby user defined file name patterns can be respected to store successfully sent faxes in different directories.

8) The program inserts itsself if wanted and necessary in root’s crontab in order to be called in adjustable intervals. To avoid this, either ’cronminut’ can be set to 0, or the already generated autofax entries can be commented out with a leading ’#’.

9) The program checks if all user-relevant directories (see 7) are being included in samba shares in /etc/samba/smb.conf; such are being added if needed.

10) Working of MariaDB is being checked, if necessary it is being (installed and) started, the database tables spooltab (for faxes just in spool), outa (for sent and failed faxes) and inca (for received faxes) are being checked and if necessary created or amended.

11) In case of the respective command line options corrections in the contents of the waiting directory or of the database tables are being commited or their contents is being listed and then the program is being finished.

12) Otherwise, file in the outgoing directory are being analysed. Each file with some identifiable fax number(s) within its file name which is or can be converted in/into pdf format will be moved to to waiting directory and recorded in spooltab.
If a file contains more than one recepients and/or a conversion to pdf is necessary, additional files are generated and the original file may be renamed. If necessary, additional numbers near the end of the file name(s) may be added in order not to conflict with any other file name in one of the directories mentioned in 7).
If more files have been generated, the successive movements and recordings are being carried out with all of them.

13) Depending on the configuration the functionaliy of hylafax and/or capisuite is being checked and if necessary and possible restored (including by installation of those programs; in case of a fritzcard 2.0 or a fax modem USR5637 an additional automatic configuration can/will be done). Kernel modules for hylafax and/or capisuite are automatically generated, also in case of a kernel update.

14) In case of respective command line options faxes are being deleted and the program is finished.

15) Otherwise the files which have been recorded under 12) in spooltab are being forwarded to hylafax or capisuite and this is being protocolled in spooltab.

16) All faxes which are recorded in spooltab as waiting are being checked in hylafax/capisuite as to their status which is being updated in spooltab (number of tries hitherto).
If hylafax and capisuite are working simultaneously and a prespecified number of send tries has been reached without success in the programs of the first preference of those two, the fax is additionally forwarded to the second of the two programs.
If the fax transmission is finished (with/without success), the file is being moved from the waiting directory to the respective directory for sent faxes or for failed faxes, optionally modified by ocr via ocrmypdf (if a young enough python3 > 3.5 is installed), and the database entry is being transferred from spooltab to outa.
The status of the mentioned faxes is being displayed.

17) If additional faxes in the spool of hylafax/capisuite are detected which are not created via autofax, they are displayed. In intervals they will be integrated into the autofax database (without the not available information on the original file name).

18) Via hylafax/capisuite received faxes are copied to a receiving directory and there named with the name of the sender, if possible, by means of their fax number which is being looked up using a predefineable number of predefineable sql commands, which are applied one after another until the fax number is found.
Such sql commands shall deliver (at least) 2 fields (with a user defined sense), whose contents, separated by a comma, will be used by autofax to name the received faxes. Before applied, within the sql commands the string ’&&faxnr&&’ will be replaced by the current fax number. Example:
select concat(haname,’, ’,ort,’, ’,kvnu) name, zulg from kvaerzte.hae where concat(if(mid(fax1k,1,1)=’0’,’’,’08131’), replace(replace(replace(replace(fax1k,’ ’,’’),’-’,’’),’/’,’’),’´’,’’)) = ’&&faxnr&&’

If more sql commands are specified and one of them does not give a result, the next one will be tried.
Optionally, the received faxes are subjected to ocr via a call of ocrmypdf.

19) The configuration file is being written, if necessary.

20) If the option -autoupd (--autoupdate) is acitve, at last after the second call of every day the version number of autofax will be compared with that of the installation source und if necessary a new version will be installed.

Some program parts are executed simultaneously, which may loosen up the display of the result.
Sending and receiving are started every minute, until the respective other part has finished for the first time.
Check and possibly correction of possibly falsely stored fax files (e.g. by a cancelling the program deliberately) will be done in intervals.

PRECONDITIONS

Hardware: Computer with a fritzcard 2.0 or 2.1 or/and a linux compatible fax modem; in the current version, a US Robotics modem USR5637 and one of the below mentioned linux distributions are needed for an automatic installation (by answering some questions). In case of a concurrent use of a fritzcard and a modem, the program can optimize the security of transmission of a fax.
Software
: The program was adjusted to an installation of Opensuse >= 42.1, Debian >= 9.10, Ubuntu >= 16.04, Mint >= 18 or Fedora >= 24 with standard options. System D has to be installed, i.e., "systemctl" has to run, which is the case in the mentioned program versions. One of the packet managers rpm or dpkg and apt, dnf, yum or zypper has to be installed, respectively, as is the case per default in the mentioned linux distributions. The program ’wget’ must be installed. Uninstalling of the programs added by autofax by make uninstall works currently only with the english and the german versions of the packet manager.

AUTOMATICALLY INSTALLED SOFTWARE PACKAGES

(for this purpose, depending on the distribution, zypper, apt(-get), dnf or yum are used).

makefile:
gcc V.6, g++ V.6, groff, libmysqlclient-dev(el), libtiff-dev(el) (in case of version 4.0.7 with a slight modification, see Makefile)

autofax:
acl, boost, boost-devel, boost-iostreams-devel, boost-local-devel, cron, ghostscript, imagemagick, libreoffice-common, libreoffice-base, mariadb-server, policycoreutils, policycoreutils-python-utils, poppler-tools, samba, sfftobmp, (in debian-derivates, for mariadb, additionally: apt-transport-https)

in case capisuite shall be used:
capisuite, capiutils, capi4linux, fcpci-3.10.0, gcc-4.8, g++-4.8, kernel-source (linux-source), libcapi20-2, libcapi20-3, libxslt-tools, linux-headers-$(uname -r), python-devel, (in fedora, additionally: kernel-modules-extra),

in case hylafax shall be used:
hylafax+, hylafax+-client, sendmail, tiff (in case of version 4.0.7 with a slight modification, see Makefile)

in case ocr shall be used:
ffmpeg, ffmpeg-devel, ffmpeg-compat, gcc, libavformat-devel, libffi-devel, ocrmypdf, python3-devel, python3-pip, python3-setuptools, rpmfusion, qpdf, redhat-rpm-config, tesseract-ocr, unpaper, and via ’python3 pip’: cryptography, cffi, image, M2Crypto, ocrmypdf, PyPDF2, reportlab, ruffus.

in case You want to work on the source files with ’sh viall’:
vim

All those installations may include dependent programs.
If You don’t want one of those programs or want to keep an older version of one, You may not install autofax or use the respective program parts.

IMPLICATIONS

The program has to take the following measures for its neat function:

1) In debian, in the file /etc/apt/sources.list a dvd-entry can be moved behind the standard online repositories.
2)
Sudo (is missing per default in debian) will be installed if needed.
The current linux user, if not already contained, will be entered into an administrator group mentioned in /etc/sudoers, because he has to call "sudo".
3)
’GNU make’ will be installed if not present, automatically by calling ’sh install.sh’ or ’configure’.
4)
Installation of hylafax+, in case a modem is connected and hylafax+ is not installed. If necessary configuration of hylafax+ by calling ’faxsetup -nointeracitve’, by editing the configuration files config and config.* (e.g. config.ttyACM0) in the hylafax configuration directory (default e.g. /var/spool/hylafax/etc).

5) Installation of capisuite, in case a fritzcard is inserted and capisuite is not installed. If necessary configuration of /etc/capisuite/capisuite.conf and /etc/capisuite/fax.conf. If necessary edition of the python-script for received faxes (default e.g. /usr/lib64/capisuite/incoming.py) in order to determine the rings before answer, creation and edition of the files ’/etc/udev/rules.d/46-FKN_isdn_capi.rules’, ’/etc/modprobe.d/50-blacklist.conf’.

6) Installation of services:
a)
in systemd (in the directory /usr/lib/systemd/system or /lib/systemd/system), especially:
hylafax-faxq.service
, hylafax-hfaxd.service, hylafax-faxgetty-....service (e.g. hylafax-faxgetty-ttyACM0),
capisuite.service
,
b)
Moving of existing service files from the directory /etc/init.d to a newly created directory /etc/ausrangiert ("discarded"): hylafax, capisuite
c)
In case selinux is active (as per default in fedora), it impedes per default hylafax; in this case, a module for selinux is silently arranged in order to allow running hylafax-hfaxd. Furtheron, up to the possible construction of a better fitting solution, the domain ’getty’ has to be deactivated with the command ’semanage permissive -a getty_t’ in order to be able to receive faxes.

7) Creation of a logfile, per default /var/log/autofax.log.

8) if necessary creation and making accessible of the configurable directories for faxes to be sent, waiting, finished and failed.

9) if necessary creation and making accessible of the configuration file autofax.conf in the same directory where the program is located by itsself (default: /usr/local/sbin/autofax).

10) Insertion of a line for the periodic automatic program call in root’s crontab

11) if necessary insertion of sections for the directories mentioned under 8) in /etc/samba/smb.conf, if necessary insertion of the program user or (if root) the user chosen for the capisuite as samba user. In case a Suse firewall is present, allow samba-server for "external zone". After calling autofax, the directories mentioned in 8) should be readable via samba within a local network and the directory for faxes to be sent should also be writable.

12) if necessary insertion of a database in mariadb with a configurable name, creation and modification of several tables and a procedure in this database, if necessary insertion of a user with a configurable name in mariadb for the management of those tables.

13) With specific command line options for autofax, faxes can be deleted, especially:
a)
in hylafax by callinng ’faxrm’
b)
in capisuite: by deleting files like /var/spool/capisuite/users/<user>/sendq/*.txt und ~/*.sff. In capisuite, an orphaned lock file (/var/spool/capisuite/users/<user>/sendq/*.lock) can be deleted, too.

14) With a specific command line option for autofax, an old received fax can be converted to a pdf-File again.

UNINSTALLING

Change in a terminal to the installation directory (for the same installed user, it’s cd ~/autofax, otherwise it will be displayed by autofax -info).
Call make uninstall.
Then the installed autofax will be deleted and the script uninstallinv will be executed in reverse order which has been generated during the installation and execution of autofax.
Thereby additionally installed program packets, permissions, samba shares and firewall exceptions are deleted.
Configuration files, data, and system relevant programs like libgcc and selinux will not be deleted.
Error messages originate mostly in efforts to delete a program already missing and can then be ignored.

RETURN CODES

0: Normal return code
7
: The info screen (autofax -info) has been displayed
8
: The help has been displayed
9
: To start the just installed capi module the computer has to be restarted
10
: Initializing of the database failed and the program was stopped therefore
11
: Checking of a database table failed and the program was stopped therefore
17
: Fork to another thread failed
98
: Program stopped because it is already running once
99
: A search command at a link failed while using autofax -fd 2
113
: An sql command for the mariadb database failed with a miscellaneous error
115
: A database entry failed because of a full disk
After calling autofax -vi or autofax -vs the return code of vi/vim will be passed

ERRORS

Please report any errors with the word ’autofax’ included in the email headline.
Please report as well, if different hard- or software yields a requirement for a program modification.

PROGRAM MODIFICATION

By calling ’sh viall’ and application of the usual ’vim’-commands, followed by ’make’ and ’make install’ from the installation directory (’~/autofax), You may alter the program.

LIABILITY

The program has been written with the best aim and has been tested by the author.
Nevertheless the author cannot be liable for any damage caused by the program.

AUTHOR

Gerald Schade ([email protected]; www.diabdachau.de)


AUTOFAX (Version 0.46125) - deutsch

NAME
SYNOPSIS
KURZBESCHREIBUNG
INSTALLATION
GEBRAUCH
OPTIONEN
VORAUSSETZUNGEN
AUTOMATISCH INSTALLIERTE PROGRAMMPAKETE
AUSWIRKUNGEN DES PROGRAMMABLAUFS
DEINSTALLATION
RUECKGABEWERTE
FEHLER
PROGRAMMÄNDERUNG
HAFTUNG
AUTOR


NAME

autofax − FaxServer-Funktionalität: veranlasst automatischen Faxversand von Dateien, Benennung empfangener Faxe und Protokollierung aller Faxe in einer Datenbank
(manpage available in english: ’man autofax’ or ’man -Len autofax’)

SYNOPSIS

autofax [-<kurzopt>|--<langopt> [<ergänzung>]] ...

KURZBESCHREIBUNG

autofax bietet quasi die Funktionalität eines Faxservers, welcher für manche auch hinter einer schnellen Datenleitung sinnvoll sein kann.
autofax
ist ein Befehlszeilenprogramm, mit dem Dateien in einem bestimmten Verzeichnis automatisch an hylafax (falls ein linux-kompatibles Fax-Modem angeschlossen ist) und/oder capisuite (falls eine Fritzcard 2.0 oder 2.1 angeschlossen ist) weiterleitet werden, wenn die Faxnummer im Dateinamen wie vorgesehen eingetragen ist, und das weiterhin die versandten Faxe in einer MariaDB-Datenbank abspeichert.
Außerdem können von hylafax/capisuite empfangene Faxe automatisch nach dem Sender anhand dessen Faxnummer benannt und abgespeichert werden.
Die Netzwerkintegration (z.B. auch in ein Windows-Netzwerk mit nur einem Linuxrechner) geschieht durch automatischen Eintrag der für autofax relevanten Verzeichnisse in einen Samba-Server. Sie könnte ergänzt werden durch eine Maske für die mariadb-Datenbank.

INSTALLATION

Zunächst lesen Sie bitte die untenstehenden Kapitel ’Funktionsweise’,’Voraussetzungen’,’Automatisch installierte Programmpakete’ und ’Auswirkungen des Programmablaufs’.
Anschließend verbinden Sie den Rechner falls nötig mit dem Internet und rufen Sie auf (z.B. durch Kopieren der Zeile in die Zwischenablage und Einfügen in einem Terminal):
N=autofax;P=${N}_inst.sh;cd ~;wget https://raw.githubusercontent.com/autofax/$N/master/install.sh -O$P&&sh $P

Zuletzt rufen Sie auf:
autofax

und beantworten einige Rueckfragen des Programms.
Der erste Programmaufruf und die erste Faxverarbeitung eines gesandten/empfangenen Faxes mit Hylafax/Capsiuite können jeweils etwas dauern und ein paar zusätzliche Eingaben erfordern.
autofax -erneut für jedes von Ihnen. Hierdurch wird gleichzeitig die notwendige Programminstallation für künftige Faxe vervollständigt.

GEBRAUCH

Im Idealfall sollte sich das Programm nach dem/n erstem/n Aufruf/en (s.o.) und Beantworten einmaliger Rückfragen so eingerichtet haben, dass es von selbst weiter läuft.
Es existiert dann ein Verzeichnis z.B. ’zufaxen’, in das z.B. Benutzer im Netzwerk (z.B. über die o.g. Samba-Freigabe) zu faxende Dateien stellen können wie z.B.
"Arztbericht zu Franz Krank an Dr. Gesund und Franz Krank an Fax 099 987654321 und 088 887654321.doc" (es könnte auch z.B. eine *.xls, eine *.jpg, eine *.tif, eine *.txt oder eine *.pdf-Datei sein; die Passage ’an Dr. Gesund und Franz Krank ’ ist optional für die spätere Zordnung der Faxnummer(n) in der Datenbank, sie darf auch fehlen; auf der anderen Seite darf für den Fall, dass das Programm die letzten (1-)3 Faxe zu einem Adressaten eindeutig einer Faxnummer zuordnen kann, die Passage ’ an Fax 099 987654321 und 088 887654321’ auch fehlen).
Wenn autofax beim nächsten Mal automatisch aufgerufen wird (standardmäßig alle 2 Minuten), wird die o.g. Beispieldatei zunächst kopiert und umbenannt in
"Arztbericht zu Franz Krank an Dr. Gesund an Fax 099 987654321.doc" und
"Arztbericht zu Franz Krank an Franz Krank an Fax 088 887654321.doc" und in die PDF-Dateien
"Arztbericht zu Franz Krank an Dr. Gesund an Fax 099 987654321.pdf" und
"Arztbericht zu Franz Krank an Franz Krank an Fax 088 887654321.pdf" umgewandelt.
Diese werden dann automatisch an hylafax oder Capisuite weitergeleitet und von dort aus verschickt.
Gleichzeitig werden sie aus ’zufaxen’ in das Warteverzeichnis, z.B. ’warteauffax’ verschoben und in die Spooltabelle spooltab eingetragen.
Gibt es in ’zufaxenfR’ Unterverzeichnisse, deren Namen aus einem Datum oder Uhrzeit bestehen (z.B. ’20180101 0800’ oder ’2200’), so werden darin enthaltene Faxe erst nach diesem Zeitpunkt verarbeitet und im ersteren Fall das Unterverzeichnis nach Leerung geloescht.
Bei jedem Aufruf überprüft autofax den Status von hylafax und/oder Capisuite. Der Abschluss eines Faxvorgangs dort hat zur Folge, dass autofax die Quelldateien (also hier die o.g. .doc- und .pdf-Dateien) aus dem Warteverzeichnis in ein oder mehrere alternative Archivverzeichnisse oder ein Verzeichnis für gescheiteterte Faxe ablegt und den Datenbankeintrag von ’spooltab’ in die Archivtabelle ’outa’ verschiebt.
Weiterhin werden über hylafax oder Capisuite angekommene Faxe in ein Empfangsverzeichnis kopiert und ggf. nach dem Sender benannt. Hierzu werden, falls angegeben, konfigurierbare SQL-Befehle verwendet, die in frei festlegbarer Zahl der Reihe nach so lange aufgerufen werden, bis einer einen Datensatz zu der Faxnummer findet.
Der Benutzer könnte also je nach Betriebssystem, Zugriffsmöglichkeit und Präferenz in den genannten Verzeichnissen, in den Datenbanktabellen oder durch Aufruf von z.B. ’autofax’, ’autofax -lista’, ’autofax -listf’ oder ’autofax -listi’ den Stand des Faxens überprüfen.

OPTIONEN

autofax -?’ oder ’autofax -h’ zeigt die wichtigen Befehlszeilenoptionen und ’autofax -lh’ alle. Einige Optionen (z.B. die SQL-Befehle zur Suche eines Adressaten aus der Faxnummer) können nicht über die Befehlszeile, sondern nur über die Konfigurationsdatei eingegeben werden, die wiederum über ’autofax -vi’ direkt editiert oder auch über ’autofax -rf’ interaktiv gepflegt werden kann.
Optionen, die nicht gespeichert werden:
-w, --wortreich
: Bildschirmausgabe gespraechiger
-ldn, --logdateineu
: logdatei vorher loeschen
-kd, --konfdatei <string>
: verwendet Konfigurationsdatei <string> anstatt ’’
-sqlw, --sql-wortreich
: Bildschirmausgabe mit SQL-Befehlen
-rf, --rueckfragen
: alle Parameter werden abgefragt (darunter einige hier nicht gezeigten)
-krf, --keinerueckfragen
: keine Rueckfragen, z.B. für Aufruf aus cron
-loef, --loeschefax
: ein Fax nach Rueckfrage loeschen
-loew, --loeschewaise
: Eintraege aus ‘spool‘ loeschen, zu denen keine Datei im Wartevz.und kein Capi- oder Hylafax nachweisbar ist
-loea, --loescheallew
: alle wartenden Faxe und zugehoerige Eintraege aus ‘spool‘ loeschen
-erneut, --erneutempf
: empfangenes Fax erneut bereitstellen
-uml, --umleiten
: ausgehendes Fax vorzeitig auf zweitem Weg schicken
-kez, --korrerfolgszeichen
: in der Datenbanktabelle ‘outa‘ wird das Erfolgszeichen korrigiert
-bvz, --bereinigevz
: Dateien aus Wartevz.,Gescheitertenvz.u.Gefaxtvz.gegen ‘outa‘ pruefen und ggf. aufraeumen
-st, --stop
: autofax anhalten
-lista, --listausg
: listet Datensaetze aus ‘outa‘ mit Erfolgskennzeichen auf
-listf, --listfehlgeschl
: listet Datensaetze aus ‘outa‘ ohne Erfolgskennzeichen auf
-liste, --listeing
: listet Datensaetze aus ‘inca‘ auf
-listw, --listwartende
: listet wartende Faxe auf
-s, --suche <string>
: Suche in verarbeiteten Faxen nach <string>: ’’
-n, --dszahl <zahl>
: Zahl der aufzulistenden Datensaetze = <zahl> statt ’30
-info, --version
: Zeigt die Programmversion an
-vi, --vi
: Konfigurations- u.Logdatei bearbeiten/sehen (beenden mit ’:qa’)
-vc, --vc
: Capisuite-Konfigurationsdateien bearbeiten (beenden mit ’:qa’)
-vh, --vh
: Hylafax-Modem-Konfigurationsdatei bearbeiten (beenden mit ’:qa’)
-vs, --vs
: Quelldateien bearbeiten (beenden mit ’:qa’)
-h, --hilfe
: Erklärung häufiger Optionen
-lh, --langhilfe
: Erklärung aller Optionen
Optionen z.Speich. i.Konfigur’datei (vorausg. ’1’=doch nicht speichern, ’no’=Gegenteil, z.B. ’-noocra’,’-1noocri’):
-sp, --sprache <string>
: Language/Sprache/Lingue/Lingua [deutsch,englisch] ’d
-lvz, --logvz <pfad>
: waehlt als Logverzeichnis <pfad>, derzeit ’/var/log
-ld, --logdname <string>
: logdatei <string> (im Pfad ’/var/log’) wird verwendet anstatt ’autofax.log
-l, --log
: protokolliert ausfuehrlich in Datei ’/var/log/autofax.log’ (sonst knapper)
-zvz, --zufaxenvz <pfad>
: faxt die Dateien aus <pfad> anstatt ’/var/autofax/zufaxen
-wvz, --wartevz <pfad>
: Dateien warten in <pfad> anstatt ’/var/autofax/warteauffax
-ngvz, --nichtgefaxtvz <pfad>
: Gescheiterte Faxe werden hier gesammelt anstatt in ’/var/autofax/nichtgefaxt
-evz, --empfvz <pfad>
: Empfangsverzeichnis fuer Faxempfang ’/var/autofax/empfvz
-capi, --obcapi
: Capisuite verwenden oder nicht
-hyla, --obhyla
: Hylafax verwenden oder nicht
-cz, --capizuerst
: versuche faxe zuerst ueber Capisuite wegzuschicken oder nicht
-hz, --hylazuerst
: versuche faxe zuerst ueber hylafax wegzuschicken oder nicht
-mod, --hmodem <string>
: Fuer Hylafax verwendetes Modem, anstatt ’’
-mc, --maxcapiv <zahl>
: nach <zahl> Versuchen Capisuite wird Hylafax versucht, anstatt nach ’3
-mh, --maxhylav <zahl>
: nach <zahl> Versuchen Hylafax wird Capisuite versucht, anstatt nach ’3
-cuser, --cuser <string>
: verwendet fuer Capisuite und/oder Samba den Linux-Benutzer <string> anstatt ’’
-ckzl, --cklingelzahl <zahl>
: Zahl der Klingeltoene, bis Capisuite den Anruf annimmt, anstatt ’1
-hkzl, --hklingelzahl <zahl>
: Zahl der Klingeltoene, bis Hylafax den Anruf annimmt, anstatt ’2
-hmw, --hmaxwahlvers <zahl>
: Zahl der Wahlversuche in Hylafax, anstatt ’11
-gz, --gleichziel
: Faxe werden auch ohne Faxerfolg ins Zielverzeichnis kopiert oder nicht
-ocre, --ocre
: Text aus empfangenen Faxen wird ermittelt oder nicht
-ocra, --ocra
: Text aus gesandten Bildern wird ermittelt oder nicht
-afs, --anfaxstr <string>
: faxnr wird hinter <string> erwartet statt hinter ’an Fax
-acfs, --ancfaxstr <string>
: faxnr fuer primaer Capisuite wird hinter <string> erwartet statt hinter ’an cFax
-ahfs, --anhfaxstr <string>
: faxnr fuer primaer hylafax wird hinter <string> erwartet statt hinter ’an hFax
-as, --anstr <string>
: Adressatenname wird hinter <string> erwartet statt hinter ’ an
-us, --undstr <string>
: Trennstring <string> fuer mehrere Adressaten/Telefonnummern statt ’und
-host, --host <string>
: verwendet die Datenbank auf Host <string> anstatt auf ’localhost
-muser, --muser <string>
: verwendet fuer MySQL/MariaDB den Benutzer <string> anstatt ’user
-mpwd, --mpwd <string>
: verwendet fuer MySQL/MariaDB das Passwort <string>
-db, --datenbank <string>
: verwendet die Datenbank <string> anstatt ’autofax
-fd, --finde <zahl>
: Version 1,2 oder 3 -Dateisuche (variable Performanceunterschiede) anstatt ’3
-cm, --cronminuten <zahl>
: alle wieviel Minuten soll autofax ueber crontab aufgerufen werden (0=gar nicht), anstatt ’2
-autoakt, --autoaktual
: Programm automatisch aktualisieren oder nicht -1lg.SH FUNKTIONSWEISE

Beim Aufruf von ’autofax’ geschieht folgendes:

1) Die aktuelle Hardware wird überprüft:
a)
mit dem Befehl ’lspci | grep -i isdn’ bezüglich einer ISDN-Karte
b)
mit dem Befehl ’stty -F’ bezüglich eines Fax-Modems.

2) Die Fax-Konfigurationsdatei fax.conf der Capisuite wird eingelesen, falls es sie gibt

3) Weitere Vorgaben aus dem Programmcode werden zugewiesen, die durch die autofax-Konfigurationsdatei (siehe 4), Kommandozeilenargumente oder Antworten auf Rückfragen (siehe 5) überdeckt werden können.

4) Vorgaben werden geladen aus der Konfigurationsdatei, falls existent (standardmäßig autofax.conf im selben Verzeichnis wie autofax, standardmäßig /usr/local/sbin/autofax))

5) Rückfragen werden gestellt, falls in der Konfigurationsdatei Werte fehlen oder falls eine Kommandozeilenoption Interaktivität verlangt.

6) Das Verzeichnis von hylafax wird ermittelt (/var/spool/hylafax oder /var/spool/fax), falls hylafax installiert ist.

7) Von Benutzern verwendete Verzeichnisse für zu verschickende, wartende, versandte und gescheiterte und empfangene Fax-Dateien werden überprüft und ggf. erstellt. Dabei können in der Konfiguration angegebene Dateinamensmuster berücksichtigt werden, um erfolgreich versandte Faxe je nach Dateinamen in verschiedenen Verzeichnissen zu speichern.

8) Das Programm trägt sich ggf. in crontab (des Benutzers root) ein, um auf Wunsch in (einstellbaren) Abständen aufgerufen zu werden. Um dies zu verhindern, kann entweder ’cronminut’ auf 0 eingestellt werden oder die bereits erstellten autofax-Einträge mit crontab -e mit einem vorangestellten ’#’ auskommentiert werden.

9) Das Programm überprüft, ob alle benutzerreleventen Verzeichnisse (s. 7) von Sambafreigaben in /etc/samba/smb.conf erfasst werden, solche werden nötigenfalls ergänzt.

10) Der Betrieb von MariaDB wird überprüft, ggf. wird es (installiert und) in Betrieb gesetzt, die Datenbanktabellen spooltab (für gerade laufende Faxe), outa (für gesandte und gescheiterte Faxe) und inca (für angekommene Faxe) werden überprüft und ggf. erstellt oder erweitert.

11) Im Fall der entsprechenden Kommandozeilenoptionen werden Korrekturen bei Dateien im Warteverzeichnis oder den Protokolltabellen durchgeführt oder deren Inhalt aufgelistet und das Programm dann beendet.

12) Andernfalls werden Dateien im Zufaxenverzeichnis analysiert. Jede Datei, deren im Dateinamen enthaltene Faxnummer(n) ermittelbar ist/sind und die in eine PDF-Datei umwandelbar ist (oder schon so vorliegt), wird ins Warteverzeichnis verschoben und in spooltab eingetragen.
Falls eine Datei mehrere Faxnummern enthält und/oder eine PDF-Umwandlung nötig ist, werden zusätzliche Dateien erstellt und die ursprüngliche Datei ggf. umbenannt. Falls nötig, können die Dateien zusätzliche Zifferm nahe ihrem Namensende bekommen, so dass die Namen mit keinem anderen der unter 7) genannten Verzeichnisse in Konflikt steht.
Falls neue Dateien erstellt wurden, werden die nachfolgenden Verschiebungen und Protokollierungen mit allen durchgeführt.

13) Je nach Konfiguration wird die Funktionsfähigkeit von hylafax und/oder capisuite überprüft und ggf. nach Möglichkeit hergestellt (falls nötig und möglich auch mit Installation dieser Programme; für eine Fritzcard 2.0 sowie für ein Faxmodem USR5637 kann/wird auch eine automatische Konfiguration erfolgen). Kernelmodule für hylafax bzw. capisuite werden für die aktuelle Kernelversion erstellt, auch bei etwaigen Kernelupdates.

14) Im Fall entsprechender Kommandozeilenoptionen werden Faxe gelöscht und das Programm dann beendet.

15) Andernfalls werden die unter 12) in spooltab eingetragenen Dateien an hylafax oder capisuite weitergeleitet und dies in spooltab protokolliert.

16) Alle in spooltab als wartend stehenden Faxe werden in hylafax/capisuite auf ihren Status überprüft, dieser wird in spooltab aktualisiert (Zahl der bisherigen Faxversuche).
Falls sowohl hylafax als auch capisuite aktiv sind und eine voreingestellte Zahl an Anwahlversuchen im Programm der ersten Präferenz dieser beiden erfolglos erreicht ist, wird das Fax auch noch an das jeweils andere Programm weitergeleiet.
Falls der Faxvorgang (erfolgreich oder erfolglos) beendet ist, wird die Datei aus dem Warteverzeichnis in die Verzeichnisse für fertige bzw. gescheiterte Faxe verschoben, optional mit ocrmypdf einer Texterkennung unterzogen (falls ein ausreichend junges Python3 > 3.5 installiert ist), und der Datenbankeintrag aus spooltab in die Tabelle outa verschoben.
Der Status der genannten Faxe wird angezeigt.

17) Weitere in der Warteschleife von hylafax/capisuite befindliche, nicht über autofax erstellte Faxe werden ggf. angezeigt. In Intervallen werden sie in die autofax-Datenbank integriert (ohne die fehlende Information über den ursprünglichen Dateinamen)

18) Über hylafax/capisuite empfangene Faxe werden ggf. mit Hilfe der Faxnummer anhand voreingestellter SQL-Befehle nach dem Namen des Absenders benannt und in ein Empfangsverzeichnis gestellt.
Solche SQL-Befehle sollen (mindestens) zwei Ergebnisfelder (mit benutzerdefinierter Bedeutung) liefern, deren Inhalt dann, durch ein Komma getrennt, von autofax zur Benennung eines empfangenen Faxes verwendet werden. Vor der Anwendung des SQL-Befehls wird die Zeichenfolge ’&&faxnr&&’ zur aktuellen Faxnummer erweitert. Beispiel fuer einen solchen SQL-Befehl:
select concat(haname,’, ’,ort,’, ’,kvnu) name, zulg from kvaerzte.hae where concat(if(mid(fax1k,1,1)=’0’,’’,’08131’), replace(replace(replace(replace(fax1k,’ ’,’’),’-’,’’),’/’,’’),’´’,’’)) = ’&&faxnr&&’

Wenn mehrere SQL-Befehle angegeben werden, so wird der jeweils naechste angewandt, wenn einer kein Ergebnis liefert.
Optional werden die empfangenen Dateien mit Hilfe von ocrmypdf einer Texterkennung unterzogen.

19) Die Konfigurationsdatei autofax.conf wird ggf. geschrieben.

20) Wenn die Option -autoakt bzw. --autoaktual aktiv ist, wird zuletzt bei jedem zweiten Aufruf jedes Tages die Versionsummer von autofax mit der der Installationsquelle verglichen und im Fall eines Rückstands eine Aktualisierung durchgeführt

Einige Programmteile laufen parallel, dies kann sich die Reihenfolge der Ergebnisanzeige auflockern.
Senden und Empfangen wiederholen sich ggf. minütlich, bis der jeweils andere Teil zum ersten Mal fertig ist.
Überprüfung und ggf. Korrektur evtl. falsch abgelegter Fax-Dateien (z.B. infolge eines willkürlichen Programmabbruchs von außen) werden in Abständen durchgeführt.

VORAUSSETZUNGEN

Hardware: Computer mit einer Fritzcard 2.0 oder 2.1 und/oder einem linux-kompatiblen Modem; in der vorliegenden Fassung wird für eine automatische Installation des Programms (unter Beantwortung einiger Rückfragen) ein US Robotics Modem USR5637 und eine der untenstehenden Linuxversionen benötigt. Im Fall der Verwendung von Fritzcard plus einem Modem kann das Programm beide Faxwege alternativ nutzen, um die Übertragungssicherheit zu erhöhen.
Software
: Das Programm wurde auf eine Installation von Opensuse >= 42.1, Debian >= 9.10, Ubuntu >= 16.04, Mint >= 18 oder Fedora >= 24 mit jeweils Standardoptionen abgestimmt. System D muss installiert sein bzw. systemctl muss laufen, was in den genannten Programmversionen der Fall ist. Jeweils einer der Paketmanager rpm oder dpkg sowie apt, dnf, yum oder zypper muss installiert sein, wie in den genannten Linuxdistributionen standardmäßig der Fall. Das Programm ’wget’ wird vorausgesetzt. Die Deinstallation der durch autofax hinzugefügten Programme mit make uninstall ist gegenwärtig nur für englische und deutsche Versionen der Paketmanager eingerichtet.

AUTOMATISCH INSTALLIERTE PROGRAMMPAKETE

(hierzu wird je nach Distribution zypper, apt(-get), dnf oder yum verwendet).

makefile:
gcc V.6, g++ V.6, groff, libmysqlclient-dev(el), libtiff-dev(el) (im Fall von Vers. 4.0.7 mit leichter Modifikation, s. Makefile)

autofax:
acl, boost, boost-devel, boost-iostreams-devel, boost-local-devel, cron, ghostscript, imagemagick, libreoffice-common, libreoffice-base, mariadb-server, policycoreutils, policycoreutils-python-utils, poppler-tools, samba, sfftobmp, (in debian-derivates, für mariadb, zusätzlich: apt-transport-https)

falls capisuite benutzt werden soll:
capisuite, capiutils, capi4linux, fcpci-3.10.0, gcc-4.8, g++-4.8, kernel-source (linux-source), libcapi20-2, libcapi20-3, libxslt-tools, linux-headers-$(uname -r), python-devel, (in fedora, zusätzlich: kernel-modules-extra),

falls hylafax benutzt werden soll:
hylafax+, hylafax+-client, sendmail, tiff (im Fall von Vers. 4.0.7 mit kleiner Modifikation, s. Makefile)

falls ocr benutzt werden soll:
ffmpeg, ffmpeg-devel, ffmpeg-compat, gcc, libavformat-devel, libffi-devel, ocrmypdf, python3-devel, python3-pip, python3-setuptools, rpmfusion, qpdf, redhat-rpm-config, tesseract-ocr, unpaper, and via ’python3 pip’: cryptography, cffi, image, M2Crypto, ocrmypdf, PyPDF2, reportlab, ruffus.

falls Sie die Quelldateien mit ’sh viall’ bearbeiten wollen:
vim

All diese Installationen können abhängige Programme einschließen.
Falls Sie eines dieser Programme nicht wollen bzw. nicht aktualisieren wollen, dann dürfen Sie autofax oder die entsprechenden Programmteile nicht auf diesem Computer verwenden.

AUSWIRKUNGEN DES PROGRAMMABLAUFS

Das Programm muss zum ordentlichen Funktionieren folgende Maßnahmen ergreifen:

1) In Debian kann in der Datei /etc/apt/sources.list ein DVD-Eintrag hinter die Standard-Online-Repositories verschoben werden.
2)
Sudo (fehlt anfangs bei Standardinstallation in Debian) wird ggf. installiert.
Der Benutzer beim Installationsvorgang wird, falls nicht schon enthalten, in eine Administrator-Gruppe eingetragen, die in /etc/sudoers genannt wird, da er "sudo" ausführen muß.

3) ’GNU make’ wird, falls nicht vorhanden, durch Aufruf von ’sh ./install.sh’ bzw. ’configure’ automatisch installiert.

4) Installieren von Hylafax+, falls ein Modem angeschlossen ist und Hylafax+ nicht installiert ist. Ggf. Konfiguration von Hylafax+ durch Aufruf von ’faxsetup -nointeracitve’, durch Editieren der Konfigurationsdateien config und config.* (z.B. config.ttyACM0) im hylafax-Konfigurationsverzeichnis (Vorgabe z.B.: /var/spool/hylafax/etc/)

5) Installieren von capisuite, falls eine Fritzkarte eingebaut ist und capisuite nicht installiert ist. Ggf. Bearbeitung der Konfigurationsdateien /etc/capisuite/capisuite.conf und /etc/capisuite/fax.conf. Ggf. Bearbeitung des Python-Scripts für ankommende Faxe (Vorgabe z.B.: /usr/lib64/capisuite/incoming.py) zur Bestimmung der Zahl der Klingeltöne bis zur Faxannahme, Erstellung bzw. Bearbeitung der Dateien

6) Einrichten von Diensten:
a)
in systemd (im Verzeichnis /usr/lib/systemd/system oder /lib/systemd/system), insbesondere:
hylafax-faxq.service
, hylafax-hfaxd.service, hylafax-faxgetty-....service (z.B. hylafax-faxgetty-ttyACM0),
capisuite.service,
b)
Verschieben von Diensten aus dem Verzeichnis /etc/init.d in ein neu eingerichtes Verzeichnis /etc/ausrangiert: hylafax, capisuite
c)
falls selinux aktiv ist (wie standardmäßig in fedora), dann behindert es standardmäßig hylafax; in diesem Fall wird im Hintergrund ein Modul für selinux eingerichtet, um den Betrieb von hylafax-hfaxd wieder zu erlauben. Ferner muss (bis zur eventuellen Erstellung einer maßgeschneiderteren Lösung) die Domäne ’getty’ mit dem Befehl ’semanage permissive -a getty_t’ in selinux entschärft werden, um faxe über hylafax empfangen zu können.

7) Erstellen einer Protokolldatei, standardmäßig /var/log/autofax.log.

8) ggf. Erstellen und Zugreifbarmachen der bestimmbaren Verzeichnisse für zu sendende, wartende, abgearbeitete und empfangene Faxe.

9) ggf. Erstellen und Verändern der Konfigurationsdatei autofax.conf in dem Verzeichnis, in dem auch es selbst steht (Vorgabe: /usr/local/sbin/autofax).

10) ggf. Einfügen einer Zeile zum automatischen periodischen Aufruf des Programms in das crontab (von root)

11) ggf. Einfügen von Abschnitten für die unter 8) genannten Verzeichnisse in /etc/samba/smb.conf, ggf. Einfügen/Passwortzuteilen des Programmbenutzers bzw. (falls root) des für die Capisuite gewählten Benutzers als Samba-Benutzer. Falls Suse-Firewall vorhanden, samba-Server fuer "externe Zone" eintragen. Nach Programmaufruf sollten die unter 8) genannten Verzeichnisse im Samba-Netzwerk sichtbar sein und Dateien im Verzeichnis für zu sendende Faxe erstellt werden können.

12) ggf. Einfügen einer Datenbank für die Faxe in mariadb unter einem bestimmbaren Namen, Anlage und Veränderung mehrerer Tabellen und einer Prozedur in dieser Datenbank, ggf. Einfügen eines Benutzers mit bestimmbarem Namen in mariadb zur Datenpflege in diesen Tabellen

13) durch entsprechende Befehlszeilenoptionen von autofax können innerhalb von hylafax und capisuite Faxe gelöscht werden, insbesondere:
a)
in hylafax: durch Aufruf von ’faxrm’
b)
in capisuite: durch Löschen der Dateien wie /var/spool/capisuite/users/<user>/sendq/*.txt und ~/*.sff. In capisuite kann auch eine verwaiste Lock-Datei (/var/spool/capisuite/users/<user>/sendq/*.lock) gelöscht werden.

14) mit einer Befehlszeilenoption kann ein früher empfangenes Fax erneut in eine pdf-Datei umgewandelt werden.

DEINSTALLATION

Wechseln Sie in einem Terminal in das Installationsverzeichnis (beim selben eingeloggten Benutzer: cd ~/autofax, ansonsten wird es über autofax -info angezeigt).
Rufen Sie dort make uninstall auf.
Dadurch wird das installierte autofax gelöscht und das Script uninstallinv in umgekehrter Reihenfolge abgearbeitet, das bei der Installation und beim Aufruf von autofax erstellt wurde.
Dadurch werden zusätzlich installierte Programmpakete, zusätzlich erteilte Berechtigungen, für autofax eingerichtete Sambafreigaben und Firewallausnahmen wieder gelöscht.
Auf die Deinstallation der Konfigurationsdateien, der angesammelten Daten und systemrelevanter Programme wie libgcc und selinux wird dabei verzichtet.
Etwaige Fehlermeldungen beziehen sich meist auf einen Deinstallationsversuch bereits entfernter Programme und können ignoriert werden.

RUECKGABEWERTE

0: Normaler Rückgabewert
7
: Der Infobildschirm (autofax -info) wurde angezeigt
8
: Die Hilfe wurde angezeigt
9
: Zur Inbetriebnahme des gerade eingerichteten Capi-Moduls muss der Rechner neu gestartet werden
10
: Die Initialisierung der Datenbank scheiterte und das Programm wurde deshalb beendet
11
: Die Überprüfung einer Datenbanktabelle scheiterte und das Programm wurde deshalb beendet
17
: Gabelung zu weiterem thread misslungen
98
: Programmaufruf abgebrochen, da es bereits einmal läuft
99
: Suchbefehl mit autofax -fd 2 bei Dateilink misslungen
113
: Ein SQL-Befehl für die Mariadb-Datenbank scheiterte an sonstigem Fehler
115
: Eine Datenbankeintragung scheiterte an voller Festplatte
Nach Aufruf von autofax -vi oder autofax -vs wird ggf. der Rückgabewert von vi/vim weitergeleitet

FEHLER

Fehler bitte mit u.a. dem Wort ’autofax’ in der Email-Ueberschrift melden.
Bitte auch melden, wenn sich Änderungsbedarf durch andere Hard- bzw. Software ergeben.

PROGRAMMÄNDERUNG

Durch Aufruf von ’sh viall’ mit den üblichen ’vim’-Befehlen, gefolgt von ’make’ und ’make install’ vom Installationsverzeichnis (’~/autofax) aus können Sie das Programm ändern.

HAFTUNG

Das Programm wurde mit bester Absicht entwickelt und durch den Autor getestet.
Trotzdem kann der Autor für keine Schäden haften, die durch das Programm entstehen könnten

AUTOR

Gerald Schade ([email protected]; www.diabdachau.de)


autofax's People

Contributors

libelle17 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.