Modification of the mi, mp, and _d attributes on a PostScript queue
The root user can modify the mi, mp, and _d attributes in the virtual printer definition so that the queue backend can determine the file type (PostScript or non-PostScript ASCII) and set the print environment accordingly.
Input data stream attributes store the pipelines for different input data stream types. For more information, see Virtual printer input data stream attributes. The definition for a generic PostScript printer has four input data stream pipelines: ia (extended ASCII), in (troff), ip (passthru), and is (PostScript). The _d attribute in the colon file controls which of the four input data stream processing pipelines will, by default, be used. The default value for _d on a generic PostScript queue is s (PostScript), so the pipeline defined by is will be used.
The mi attribute uses single, comma-separated characters to name input data stream types. The mp attribute uses comma-separated strings to identify input data stream types. There is a one-to-one pairing between the characters of mi and the strings of mp.
The default value of mi for a generic PostScript virtual printer is s. The default value for mp is %%!; the first two characters of a PostScript file are %!. (Recall that printer colon file escape sequences all begin with a % so, to use a literal % in an attribute definition, it must be escaped with another %.) The virtual printer will interpret all files beginning with %! as being of data stream type s, and use the is pipeline. Because non-PostScript ASCII file do not begin with a %!, they will not be printed by this queue.
Submitting a non-PostScript ASCII job to a PostScript queue with a generic PostScript virtual printer definition will result in the loss of the job. To enable ASCII printing on this queue, the root user can use the lsvirprt command to modify the referenced attributes as follows:
- mi=a,s
- mp=,%%!
- _d=%mi
Use the lsvirprt command to select the generic PostScript queue. The following prompt will appear:
To LIST attributes, enter AttributeName1 ..(* for all attributes)
To CHANGE an attribute value, enter AttributeName=NewValue
To FORMAT and EDIT an attribute value, enter AttributeName~v
To EDIT the attribute file, enter ~v
To terminate, press Enter:At the prompt:
- Enter mi=a,s.
- Enter mp=,%%!.
- Enter d=%mi.
After each attribute redefinition is entered, the attribute's new value will be displayed, followed by the prompt.
This new value sets up a pairing of input data stream type a (extended ASCII) with any string at all, and input data stream type s (PostScript) with the string %!. Input data streams that do not being with a %! will be processed by the ia pipeline, and all input data streams that do begin with a %! will be processed by the is pipeline.
qprt -Pqueue_name -da /etc/motdThis command requests that the file named /etc/motd be printed on the queue named queue_name and that the input data stream be treated as ASCII (the ia pipeline will be used).