The available printer options vary depending on the printer. The standard options are described in the Standard Printing Options section below. Printer-specific options are also available and can be listed using the lpoptions command:

lpoptions -p printer -l

Creating Saved Options
Saved options are supported in CUPS through printer instances. Printer instances are, as their name implies, copies of a printer that have certain options associated with them. Use the lpoptions command to create a printer instance:

lpoptions -p printer/instance -o name=value …

The -p printer/instance option provides the name of the instance, which is always the printer name, a slash, and the instance name which can contain any printable characters except space and slash. The remaining options are then associated with the instance instead of the main queue. For example, the following command creates a duplex instance of the LaserJet queue:

lpoptions -p LaserJet/duplex -o sides=two-sided-long-edge

Instances do not inherit lpoptions from the main queue.

Printing Multiple Copies
Both the lp and lpr commands have options for printing more than one copy of a file:

lp -n num-copies filename lpr -#num-copies filename

Copies are normally not collated for you. Use the ”-o Collate=True” option to get collated copies:

Canceling a Print Job
The cancel(1) and lprm(1) commands cancel a print job:

cancel job-id lprm job-id

The job-id is the number that was reported to you by the lp command. You can also get the job ID using the lpq(1) or lpstat commands:

lpq lpstat

Moving a Print Job
The lpmove(8) command moves a print job to a new printer or class:

lpmove job-id destination
The job-id is the number that was reported to you by the lp or lpstat commands. Destination is the name of a printer or class that you want to actually print the job.

Note: The lpmove command is located in the system command directory (typically /usr/sbin or /usr/local/sbin), and so may not be in your command path. Specify the full path to the command if you get a “command not found” error, for example:

/usr/sbin/lpmove foo-123 bar

Standard Printing Options
The following options apply when printing all types of files.

where “WIDTH” and “LENGTH” are the width and length of the media in points, inches, centimeters, or millimeters, respectively.

Setting the Orientation
The ”-o landscape” option will rotate the page 90 degrees to print in landscape orientation:

lp -o landscape filename lpr -o landscape filename

The ”-o orientation-requested=N” option rotates the page depending on the value of N:

-o orientation-requested=3

portrait orientation (no rotation)

-o orientation-requested=4

landscape orientation (90 degrees)

-o orientation-requested=5

reverse landscape or seascape orientation (270 degrees)

-o orientation-requested=6

reverse portrait or upside-down orientation (180 degrees)
Printing On Both Sides of the Paper
The -o sides=two-sided-short-edge and -o sides=two-sided-long-edge options will enable two-sided printing on the printer if the printer supports it. The -o sides=two-sided-short-edge option is suitable for landscape pages, while the -o sides=two-sided-long-edge option is suitable for portrait pages:

If only one banner file is specified, it will be printed before the files in the job. If a second banner file is specified, it is printed after the files in the job.

The available banner pages depend on the local system configuration; CUPS includes the following banner files:

“none” – Do not produce a banner page. “classified” – A banner page with a “classified” label at the top and bottom. “confidential” – A banner page with a “confidential” label at the top and bottom. “secret” – A banner page with a “secret” label at the top and bottom. “standard” – A banner page with no label at the top and bottom. “topsecret” – A banner page with a “top secret” label at the top and bottom. “unclassified” – A banner page with an “unclassified” label at the top and bottom.

Holding Jobs for Later Printing
The -o job-hold-until=when option tells CUPS to delay printing until the when time, which can be one of the following:

-o job-hold-until=indefinite

print only after released by the user or an administrator

-o job-hold-until=day-time

print from 6am to 6pm local time

-o job-hold-until=night

print from 6pm to 6am local time

-o job-hold-until=second-shift

print from 4pm to 12am local time

-o job-hold-until=third-shift

print from 12am to 8am local time

-o job-hold-until=weekend

print on Saturday or Sunday

-o job-hold-until=HH:MM

print at the specified UTC time

Releasing Held Jobs
Aside from the web interface, you can use the lp command to release a held job:

lp -i job-id -H resume

where “job-id” is the job ID reported by the lpstat command.

Setting the Job Priority
The -o job-priority=NNN option tells CUPS to assign a priority to your job from 1 (lowest) to 100 (highest), which influences where the job appears in the print queue. Higher priority jobs are printed before lower priority jobs, however submitting a new job with a high priority will not interrupt an

Specifying the Output Order
The -o outputorder=normal and -o outputorder=reverse options specify the order of the pages. Normal order prints page 1 first, page 2 second, and so forth. Reverse order prints page 1 last.

Selecting a Range of Pages
The -o page-ranges=pages option selects a range of pages for printing:

As shown above, the “pages” value can be a single page, a range of pages, or a collection of page numbers and ranges separated by commas. The pages will always be printed in ascending order, regardless of the order of the pages in the “page-ranges” option.

The default is to print all pages.

Selecting Even or Odd Pages
Use the -o page-set=set option to select the even or odd pages:

The default is -o outputorder=normal for printers that print face down and -o outputorder=reverse for printers that print face up.

Printing Mirrored Pages
The -o mirror option flips each page along the vertical access to produce a mirrored image:

lp -o mirror filename lpr -o mirror filename

This is typically used when printing on T-shirt transfer media or sometimes on transparencies.

Raw or Unfiltered Output
The -o raw option allows you to send files directly to a printer without filtering. This is sometimes required when printing from applications that provide their own “printer drivers” for your printer:

lp -o raw filename lpr -o raw filename

The -l option can also be used with the lpr command to send files directly to a printer:

lpr -l filename

Text Options
CUPS supports several options that are only used when printing plain text files. These options have absolutely no effect on PostScript, PDF, HP-GL/2, or image files.

Setting the Number of Characters Per Inch
The -o cpi=value option sets the number of characters per inch:

lp -o cpi=10 filename lp -o cpi=12 filename lpr -o cpi=17 filename

The default characters per inch is 10.

Setting the Number of Lines Per Inch
The -o lpi=value option sets the number of lines per inch:

lp -o lpi=6 filename lpr -o lpi=8 filename

The default lines per inch is 6.

Setting the Number of Columns
The -o columns=value option sets the number of text columns:

lp -o columns=2 filename lpr -o columns=3 filename

The default number of columns is 1.

Setting the Page Margins
Normally the page margins are set to the hard limits of the printer. Use the -o page-left=value, -o page-right=value, -o page-top=value, and -o page-bottom=value options to adjust the page margins:

The value argument is the margin in points; each point is 1/72 inch or 0.35mm.

Pretty Printing
The -o prettyprint option puts a header at the top of each page with the page number, job title (usually the filename), and the date. Also, C and C++ keywords are highlighted, and comment lines are italicized:

lp -o prettyprint filename lpr -o prettyprint filename

Turning Off Text Wrapping
The -o nowrap option disables wrapping of long lines:

lp -o nowrap filename lpr -o nowrap filename

Image Options
CUPS supports several options that are only used when printing image files. These options have absolutely no effect on PostScript, PDF, HP-GL/2, or text files.

Positioning Images
The -o position=name option specifies the position of the image on the page:

“center” – Center the image on the page (default) “top” – Print the image centered at the top of the page “left” – Print the image centered on the left of page “right” – Print the image centered on the right of the page “top-left” – Print the image at the top left corner of the page “top-right” – Print the image at the top right corner of the page “bottom” – Print the image centered at the bottom of the page “bottom-left” – Print the image at the bottom left corner of the page “bottom-right” – Print the image at the bottom right corner of the page

The scaling=percent value is a number from 1 to 800 specifying the size in relation to the page (not the image.) A scaling of 100 percent will fill the page as completely as the image aspect ratio allows. A scaling of 200 percent will print on up to 4 pages.

The ppi=value value is a number from 1 to 1200 specifying the resolution of the image in pixels per inch. An image that is 3000×2400 pixels will print 10×8 inches at 300 pixels per inch, for example. If the specified resolution makes the image larger than the page, multiple pages will be printed to satisfy the request.

The natural-scaling=percent value is a number from 1 to 800 specifying the size in relation to the natural image size. A scaling of 100 percent will print the image at its natural size, while a scaling of 50 percent will print the image at half its natural size. If the specified scaling makes the image larger than the page, multiple pages will be printed to satisfy the request.

Adjusting Image Hue (Tint)
The -o hue=value option will adjust the hue of the printed image, much like the tint control on your television:

lp -o hue=value filename lpr -o hue=value filename

The value argument is a number from -360 to 360 and represents the color hue rotation. The following table summarizes the change you’ll see with different colors:

The pen width value specifies the pen width in micrometers. The default value of 1000 produces lines that are 1 millimeter in width. Specifying a pen width of 0 produces lines that are exactly 1 pixel wide.

Note: This option is ignored when the pen widths are set in the plot file.s