[ Pobierz całość w formacie PDF ]
.To set your computer to automatically wait for incoming faxes, you can use9the fax script s wait command-line option for example,# fax waitrunning /usr/bin/fax answer/usr/bin/efax: Thu Dec 04 16:42:22 1997 efax v 0.8a Copyright 1996 Ed CasasYou could also use the background operator to put the shell script into the background.Youcan check on the status of your Linux fax machine with the status command-line optionfor example,# fax statusUSER PID %CPU %MEM SIZE RSS TTY STAT START TIME COMMANDroot 2304 0.3 1.3 1072 420 p3 S myfile.g3This pipes the file myfile.txt through the pbmtext command, which outputs a portablebitmap graphics format into the pbm2g3 command, which then converts the piped stream ofcharacters into the fax graphic format.After you do this, you can send the file (assuming that9you re the root operator) with# /usr/sbin/sendfax -v -l ttyS1 -C cls2 -r 5551212 myfile.g3Trying fax device /dev/ttyS1.OK.Dialing 5551212.OK.sending myfile.g3.This runs the sendfax program.The -v command-line option tells sendfax to give somefeedback during the faxing operation.I ve specified the ttyS1 serial port with the -l option,and sent the fax through a Class 2 fax modem with -C cls2 command-line option.The phonenumber 555-1212 was specified with the -r option, and the file, myfile.g3, was the file youcreated with the preceding command-line pipe.If you would rather use a simpler approach, try the faxspool program, which automaticallyconverts your text file, and places it in the fax spool directory under the /var/spool/faxdirectory for example,# faxspool 5551212 myfile.txtspooling to /var/spool/fax/outgoing/F000010.spooling myfile.txt.myfile.txt is format: asciiAladdin Ghostscript 3.33 (4/10/1995)Copyright (C) 1995 Aladdin Enterprises, Menlo Park, CA.All rights reserved.This software comes with NO WARRANTY: see the file COPYING for details.Loading NimbusMonL-Bold font from /usr/share/ghostscript/fonts/n022004l.pfb.1750128 436826 1320152 28679 0 done.Printing myfile.txtPage height = 67.\nPutting Header lines on top of pages.\nFax queued successfully.Will be sent at next faxrunq run.\nThe faxspool program requires only a phone number and filename, and has the advantageof handling multiple pages easily.You can see the number of faxes awaiting in the fax queuewith the faxq command for example,# faxqF000010/JOB: queued by bball.1 page(s) to 5551212The faxq command reports on the number of jobs you ve created, the number of pages, andthe phone number of the remote fax machine.You can remove the waiting fax by using thefaxrm command, as in the following example:# faxrm F000010158 Hour 9The waiting faxes may be sent by the root operator by running the faxrunq command forexample,# faxrunqprocessing F000011/JOB./usr/sbin/sendfax -v 5551212 f1.g3Trying fax device /dev/ttyS1.OK.Dialing 5551212.OK.sending f1.g3.command exited with status 0send mail to bball.This shows that the faxrunq command uses the sendfax program to look at the fax queue inthe /var/spool/fax directory, connects with the modem, dials out, and then sends the fax.One nice feature of the sendfax software package is that a mail message is automaticallymailed to the fax sender to verify the faxing, as in the following example:.Subject: OK: your fax to 5551212Your fax has been sent successfully at: \cThu Dec 4 23:45:26 EST 1997\n\nJob / Log file:phone 5551212user bballinput myfile.txtpages f1.g3Status Thu Dec 4 23:45:26 EST 1997 successfully sent\nSending succeeded after 0 unsuccessful tries.You can also set up your Linux system to automatically receive incoming faxes with the mgettyprogram.Used much like the uugetty program, mgetty also requires at least one change toits configuration file in the /etc/mgetty+sendfax directory.The change you can make (as theroot operator) is to edit the phone identification entry in the file mgetty
[ Pobierz całość w formacie PDF ]