faxrunq(1)

πŸ“¦
version 1.2.1 Β· 2 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– faxrunq(1) πŸ’–

okay bestie, welcome to the mgetty+sendfax manual and specifically the page for faxrunq β€” the little queue-wrangler that actually gets your faxes OUT the door. grab a boba, we're doing this. πŸ§‹βœ¨


🌸 NAME 🌸

faxrunq β€” send fax jobs queued by faxspool(1)


✨ SYNOPSIS ✨

faxrunq

yes bestie that's it. no flags required, she just goes. πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

So the whole vibe here is: faxrunq runs the fax queue that faxspool(1) set up. It tries to send all the faxes, records the result, removes the job, and sends the notify mails. That's the entire personality. πŸ‘‘

faxrunq goes looking for every job that faxspool(1) queued up in /var/spool/fax/outgoing/*. For each job sitting in that queue, faxrunq tries to send it, using sendfax(8).

If the send succeeds, the job gets removed from the queue, and a "success" mail gets sent to whoever spooled the job in the first place. iconic behaviour. πŸŽ€

If the send fails, it gets logged, and faxrunq just moves on to the next job like nothing happened. BUT β€” if the job fails five times "fatally" β€” and like, fatally here means NOT a locked or engaged line, but "NO CARRIER" (so: no fax machine on the other end, or just line noise being a hater) β€” then the job gets suspended, and the requestor gets a mail telling them so. πŸ’€

You can run faxrunq straight from the command line, but bestie, make sure the user doing that has write access to the modem device and to the fax queue. Usually that means it should be run by "uucp" or "root". πŸ”

In a production environment though, it's way more useful to start faxrunq from cron(8) at regular intervals, like "run it every 5 minutes". Check the cron(8) and/or crontab(1) man pages for this (which one actually exists depends on your system, no cap).


πŸ’… OPTIONS πŸ’…

  • -q β€” tells faxrunq to be quiet, meaning it suppresses all status messages. Error messages will still be printed though, because some things are just too important to shush. 🀫

πŸŽ€ FILES πŸŽ€

  • /var/spool/fax/outgoing/stop β€” if this file exists, faxrunq (and faxrunqd) will do nothing. literally nothing. You can use this to stop queue processing while you're testing something, or if you already know the modem(s) are unavailable and you do not want to run into oany error messages, etc.
  • /var/spool/fax/outgoing/faxqueue_done β€” every single time faxrunq (or faxrunqd) runs the fax queue, a time stamp gets written into that file. It's used by faxspool to display a warning if the queue hasn't been run recently (because that means faxes may get stuck 😭).

🌈 CONFIGURATION FILE 🌈

Some aspects of faxrunq's behaviour can be controlled by a configuration file: /etc/mgetty/faxrunq.config. In this file, you can use the following options:

  • success-send-mail [y/n] β€” a boolean parameter that controls whether a mail will be sent after successful completition of the fax job.
  • failure-send-mail [y/n] β€” a boolean parameter that controls whether a mail will be sent after the fax job has failed more than the maximum number of times.
  • success-call-program <name> β€” here you can specify a program that will be run when the fax has been successfully sent. It will be passed two command line parameters. The first is the full path to the fax JOB file (see faxq(5)), and the second is the last exit code from sendfax (for success-call-program, this is always "0").
  • failure-call-program <name> β€” similar to the "success-call-program", this program will be run when the fax has been failed too often and faxrunq gives up. This script could, for example, print out the fax on a printer so that it can be sent manually on a paper fax machine. retro. πŸ–¨οΈ
  • maxfail-costly <n> β€” this specifies the number of times that a fax may fail "fatally", that is, causing telephone costs (explained above). The default value is 5.
  • maxfail-total <m> β€” this is the absolute maximum number of times that faxrunq will try to send any given fax. The default value is 10. (Right now, it's not yet implemented. πŸ™ˆ)
  • delete-sent-jobs [y/n] β€” determines whether faxrunq should delete jobs after sending, or leave them in the fax queue (while moving the "JOB" file to "JOB.done") so that they can be seen at by "faxq -o". The default value is "do not delete sent faxes".
  • acct-log <path> β€” specifies where faxrunq should protocol success and failure of each try to send a fax job. The default location is /var/spool/fax/outgoing/acct.log.

There are some other options that are allowed, but ignored. These are: max-modems, and faxrunqd-log.

They are used by faxrunqd(8) (which reads the same config file, but has more options). so like, they're not for you, bestie, they're for her cousin. 🫢


πŸ’€ BUGS πŸ’€

  • faxrunq doesn't handle proper time scheduling yet
  • Don't use faxrunq if you have malevolent users with access to the fax spool. It doesn't handle all cases of file movement tricks correctly. Use faxrunqd(8) instead, which does it correctly. (This point is mostly moot if the fax queue is set up correctly β€” that is, owned by 'uucp', mode 755, and faxrunq(1) is also run as user 'uucp'.)
fr fr, read that second one twice. malevolent users = use faxrunqd(8). that's the whole tea. 🍡

πŸ”₯ SEE ALSO πŸ”₯

faxspool(1), sendfax(8), faxq(1), faxqueue(5), faxrunqd(8)


πŸ‘‘ AUTHOR πŸ‘‘

faxrunq is Copyright (C) 1993-2002 by Gert Doering, <gert@greenie.muc.de>.


and that's the whole page, bestie!! πŸ¦‹βœ¨ this was faxrunq(1) from the mgetty+sendfax manual, written by greenie, dated 23 Nov 02. go send some faxes, you absolute icon. mwah. πŸ’–πŸŽ€πŸŒΈ