Starting a print job
Use the qprt or smit command to request a print job.
- For local print jobs, the printer must be physically attached to your system or, in the case of a network printer, attached and configured on the network.
- For remote print jobs, your system must be configured to communicate with the remote print server.
- Before you can print a file, you must have read access to it. To remove a file after it has printed, you must have write access to the directory that contains the file.
Specify the following information to request a print job:
- Name of the file to print
- Print queue name
- Number of copies to print
- Whether to make a copy of the file on the remote host
- Whether to erase the file after printing
- Whether to send notification of the job status
- Whether to send notification of the job status by the system mail
- Burst status
- User name for "Delivery To" label
- Console acknowledgment message for remote print
- File acknowledgment message for remote print
- Priority level
Use the qprt command to create and queue a print job to print the file you specify. If you specify more than one file, all the files together make up one print job. These files are printed in the order specified on the command line.
The
basic format of the qprt command is:
qprt -PQueueName FileName
The
following qprt command flags are useful:
Item | Descriptor |
---|---|
-b Number | Specifies the bottom margin. The bottom margin is the number of blank lines to be left at the bottom of each page. |
-B Value | Specifies whether burst pages (continuous-form
pages separated at perforations) should be printed. The Value variable
consists of a two-character string. The first character applies to
header pages. The second character applies to trailer pages. Each
of the two characters can be one of the following:
|
-e Option | Specifies whether emphasized print is wanted.
|
-E Option | Specifies whether double-high print is wanted.
|
-f FilterType | A one-character identifier that specifies a filter through which your print file or files are to be passed before being sent to the printer. The available filter identifiers are p, which invokes the pr filter, and n, which processes output from the troff command. |
-i Number | Causes each line to be indented the specified number of spaces. The Number variable must be included in the page width specified by the -w flag. |
-K Option | Specifies whether condensed print is wanted.
|
-l Number | Sets the page length to the specified number of lines. If the Number variable is 0, the page length is ignored, and the output is considered to be one continuous page. The page length includes the top and bottom margins and indicates the printable length of the paper. |
-L Option | Specifies whether lines wider than the page
width should be wrapped to the next line or truncated at the right
margin.
|
-N Number | Specifies the number of copies to be printed. If this flag is not specified, one copy is printed. |
-p Number | Sets the pitch to Number characters per inch. Typical values for Number are 10 and 12. The actual pitch of the characters printed is also affected by the values for the -K (condensed) flag and the -W (double-wide) flag. |
-P Queue[:QueueDevice] | Specifies the print queue name and the optional queue device name. If this flag is not specified, the default printer is assumed. |
-Q Value | Specifies paper size for the print job. The Value for paper size is printer-dependent. Typical values are 1 for letter-size paper, 2 for legal, and so on. Consult your printer manual for the values assigned to specific paper sizes. |
-t Number | Specifies the top margin. The top margin is the number of blank lines to be left at the top of each page. |
-w Number | Sets the page width to the number of characters specified by the Number variable. The page width must include the number of indention spaces specified with the -i flag. |
-W Option | Specifies whether double-wide print is wanted.
|
-z Value | Rotates page printer output the number of quarter-turns
clockwise as specified by the Value variable.
The length (-l) and width (-w) values
are automatically adjusted accordingly.
|
-# Value | Specifies a special function.
|
The following list contains examples of how to use the qprt command flags:
- To request that the myfile file be printed
on the first available printer configured for the default print queue
using default values, type:
qprt myfile
- To request that the myfile file be printed
on a specific queue using specific flag values and to validate the
flag values at the time of print job submission, type:
This passes the myfile file through the pr filter command (the -f p flag) and prints it using emphasized mode (the -e + flag) on the first available printer configured for the queue named fastest (the -Pfastest flag).qprt -f p -e + -Pfastest -# v myfile
- To print the myfile file on legal-size paper,
type:
qprt -Q2 myfile
- To print three copies of each of the new.index.c, print.index.c,
and more.c files at the print queue Msp1,
type:
qprt -PMsp1 -N 3 new.index.c print.index.c more.c
- To print three copies of the concatenation of three files, new.index.c, print.index.c,
and more.c, type:
cat new.index.c print.index.c more.c | qprt -PMsp1 -N 3
Note: The base operating system also supports the BSD UNIX print command lpr and the System V UNIX print command
lp.
You
can also use SMIT to request a print job. To start a print job using
SMIT, type:
smit qprt