Modifications to faxrunq and

Tore Høivaag Larsen larsent at
Tue Nov 4 23:09:49 GMT 1997

	just some ideas to those who use mgetty+sendfax-1.1.9 with Samba:  

To add logging of fax send success, time and number of pages sent to
printer lp0, change the perl scripts faxrunqd and (for those
who uses Respond) to include:

open(SPOOLER,"| cat -v | lpr -Plp0 -h 2>/dev/null");

before the 'print ACC' and 'print LOG' statements and add the
appropriate 'print SPOOLER' statements.  Remember to close(SPOOLER);

Forgot to mention that you'd better set the printer to not spew out the
page after the print job.

E.g. from faxrunqd:
	## write accounting info
	open ( ACC, ">>$accfile" ) || die "can not open file: $accfile";
	open(SPOOLER,"| cut -v | lpr -Plp0 -h 2>/dev/null");
	print ACC "SUCCESS: JOB $job BY $mailto TO $phone TRIES $tries TIME
$startdate -> $enddate\n";
	print SPOOLER "SUCCESS: JOB $job BY $mailto TO $phone TRIES $tries TIME
$startdate -> $enddate\n";
	close ( ACC );

Happy faxing...

Tore H. Larsen			  	Scase AS
Engineer				Eidsvågbakken 1
E-mail: tore.h.larsen at		N-5080 Eidsvåg  
Vc: +47-55951200  Fax: +47-55257120	Bergen - Norway

More information about the samba mailing list