ITEM: CD4139L
virtual printers with print queues using a custom backend
ENV:
AIX 4.1.4
Unknown model
DESC:
I have written my own custom print queue backend but I want the
queued jobs to be sent through a virtual printer for formatting
before sending to a printer. Any ideas?
ACT:
There are several ways to do this. Here are two that seem to
work well:
1) Create a file in the /dev/directory (eg /dev/lpx)
2) smit mkpq
print to a file in the /dev/directory
Use the name of the file created in step1
3) chvirprt -q yourq -d yourdevice -a mo=/your/program
Where "yourdevice" is the device created in step 1 and used in step2
Now jobs sent to this queue will be passed through the virtual printer
and the last thing that occurs is that the formatted data will be
piped as stdin into the program specified in the mo attribute.
Another way of doing this same thing, would be you make a backend
shell script like this:
\#!/bin/ksh
/usr/lib/lpd/piobe $* | /your/program
This way jobs queued will be formatted by piobe and then piped into
your program.
Support Line: virtual printers with print queues using a custom backend ITEM: CD4139L
Dated: August 1996 Category: N/A
This HTML file was generated 99/06/24~13:30:18
Comments or suggestions?
Contact us