xref: /aosp_15_r20/external/libcups/doc/help/man-lpadmin.html (revision 5e7646d21f1134fb0638875d812ef646c12ab91e)
1*5e7646d2SAndroid Build Coastguard Worker<!DOCTYPE HTML>
2*5e7646d2SAndroid Build Coastguard Worker<html>
3*5e7646d2SAndroid Build Coastguard Worker<!-- SECTION: Man Pages -->
4*5e7646d2SAndroid Build Coastguard Worker<head>
5*5e7646d2SAndroid Build Coastguard Worker	<link rel="stylesheet" type="text/css" href="../cups-printable.css">
6*5e7646d2SAndroid Build Coastguard Worker	<title>lpadmin(8)</title>
7*5e7646d2SAndroid Build Coastguard Worker</head>
8*5e7646d2SAndroid Build Coastguard Worker<body>
9*5e7646d2SAndroid Build Coastguard Worker<h1 class="title">lpadmin(8)</h1>
10*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="NAME">Name</a></h2>
11*5e7646d2SAndroid Build Coastguard Workerlpadmin - configure cups printers and classes
12*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="SYNOPSIS">Synopsis</a></h2>
13*5e7646d2SAndroid Build Coastguard Worker<b>lpadmin</b>
14*5e7646d2SAndroid Build Coastguard Worker[
15*5e7646d2SAndroid Build Coastguard Worker<b>-E</b>
16*5e7646d2SAndroid Build Coastguard Worker] [
17*5e7646d2SAndroid Build Coastguard Worker<b>-U</b>
18*5e7646d2SAndroid Build Coastguard Worker<i>username</i>
19*5e7646d2SAndroid Build Coastguard Worker] [
20*5e7646d2SAndroid Build Coastguard Worker<b>-h </b><i>server</i>[<b>:</b><i>port</i>]
21*5e7646d2SAndroid Build Coastguard Worker]
22*5e7646d2SAndroid Build Coastguard Worker<b>-d</b>
23*5e7646d2SAndroid Build Coastguard Worker<i>destination</i>
24*5e7646d2SAndroid Build Coastguard Worker<br>
25*5e7646d2SAndroid Build Coastguard Worker<b>lpadmin</b>
26*5e7646d2SAndroid Build Coastguard Worker[
27*5e7646d2SAndroid Build Coastguard Worker<b>-E</b>
28*5e7646d2SAndroid Build Coastguard Worker] [
29*5e7646d2SAndroid Build Coastguard Worker<b>-U</b>
30*5e7646d2SAndroid Build Coastguard Worker<i>username</i>
31*5e7646d2SAndroid Build Coastguard Worker] [
32*5e7646d2SAndroid Build Coastguard Worker<b>-h </b><i>server</i>[<b>:</b><i>port</i>]
33*5e7646d2SAndroid Build Coastguard Worker]
34*5e7646d2SAndroid Build Coastguard Worker<b>-p</b>
35*5e7646d2SAndroid Build Coastguard Worker<i>destination</i>
36*5e7646d2SAndroid Build Coastguard Worker[
37*5e7646d2SAndroid Build Coastguard Worker<b>-R</b>
38*5e7646d2SAndroid Build Coastguard Worker<i>name-default</i>
39*5e7646d2SAndroid Build Coastguard Worker]
40*5e7646d2SAndroid Build Coastguard Worker<i>option(s)</i>
41*5e7646d2SAndroid Build Coastguard Worker<br>
42*5e7646d2SAndroid Build Coastguard Worker<b>lpadmin</b>
43*5e7646d2SAndroid Build Coastguard Worker[
44*5e7646d2SAndroid Build Coastguard Worker<b>-E</b>
45*5e7646d2SAndroid Build Coastguard Worker] [
46*5e7646d2SAndroid Build Coastguard Worker<b>-U</b>
47*5e7646d2SAndroid Build Coastguard Worker<i>username</i>
48*5e7646d2SAndroid Build Coastguard Worker] [
49*5e7646d2SAndroid Build Coastguard Worker<b>-h </b><i>server</i>[<b>:</b><i>port</i>]
50*5e7646d2SAndroid Build Coastguard Worker]
51*5e7646d2SAndroid Build Coastguard Worker<b>-x</b>
52*5e7646d2SAndroid Build Coastguard Worker<i>destination</i>
53*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="DESCRIPTION">Description</a></h2>
54*5e7646d2SAndroid Build Coastguard Worker<b>lpadmin</b> configures printer and class queues provided by CUPS.
55*5e7646d2SAndroid Build Coastguard WorkerIt can also be used to set the server default printer or class.
56*5e7646d2SAndroid Build Coastguard Worker<p>When specified before the <i>-d</i>, <i>-p</i>, or <i>-x</i> options, the <i>-E</i> option forces encryption when connecting to the server.
57*5e7646d2SAndroid Build Coastguard Worker<p>The first form of the command (<i>-d</i>) sets the default printer or class to <i>destination</i>.
58*5e7646d2SAndroid Build Coastguard WorkerSubsequent print jobs submitted via the
59*5e7646d2SAndroid Build Coastguard Worker<b>lp</b>(1)
60*5e7646d2SAndroid Build Coastguard Workeror
61*5e7646d2SAndroid Build Coastguard Worker<b>lpr</b>(1)
62*5e7646d2SAndroid Build Coastguard Workercommands will use this destination unless the user specifies otherwise with the
63*5e7646d2SAndroid Build Coastguard Worker<b>lpoptions</b>(1)
64*5e7646d2SAndroid Build Coastguard Workercommand.
65*5e7646d2SAndroid Build Coastguard Worker<p>The second form of the command (<i>-p</i>) configures the named printer or class.  The additional options are described below.
66*5e7646d2SAndroid Build Coastguard Worker<p>The third form of the command (<i>-x</i>) deletes the printer or class <i>destination</i>.
67*5e7646d2SAndroid Build Coastguard WorkerAny jobs that are pending for the destination will be removed and any job that is currently printed will be aborted.
68*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="OPTIONS">Options</a></h2>
69*5e7646d2SAndroid Build Coastguard WorkerThe following options are recognized when configuring a printer queue:
70*5e7646d2SAndroid Build Coastguard Worker<dl class="man">
71*5e7646d2SAndroid Build Coastguard Worker<dt><b>-c </b><i>class</i>
72*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Adds the named <i>printer</i> to <i>class</i>.
73*5e7646d2SAndroid Build Coastguard WorkerIf <i>class</i> does not exist it is created automatically.
74*5e7646d2SAndroid Build Coastguard Worker<dt><b>-m </b><i>model</i>
75*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets a standard PPD file for the printer from the <i>model</i> directory or using one of the driver interfaces.
76*5e7646d2SAndroid Build Coastguard WorkerUse the <i>-m</i> option with the
77*5e7646d2SAndroid Build Coastguard Worker<b>lpinfo</b>(8)
78*5e7646d2SAndroid Build Coastguard Workercommand to get a list of supported models.
79*5e7646d2SAndroid Build Coastguard WorkerThe model "raw" clears any existing PPD file and the model "everywhere" queries the printer referred to by the specified IPP <i>device-uri</i>.
80*5e7646d2SAndroid Build Coastguard WorkerNote: Models other than "everywhere" are deprecated and will not be supported in a future version of CUPS.
81*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o cupsIPPSupplies=true</b>
82*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-o cupsIPPSupplies=false</b>
83*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Specifies whether IPP supply level values should be reported.
84*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o cupsSNMPSupplies=true</b>
85*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-o cupsSNMPSupplies=false</b>
86*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Specifies whether SNMP supply level (RFC 3805) values should be reported.
87*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o job-k-limit=</b><i>value</i>
88*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the kilobyte limit for per-user quotas.
89*5e7646d2SAndroid Build Coastguard WorkerThe value is an integer number of kilobytes; one kilobyte is 1024 bytes.
90*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o job-page-limit=</b><i>value</i>
91*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the page limit for per-user quotas.
92*5e7646d2SAndroid Build Coastguard WorkerThe value is the integer number of pages that can be printed; double-sided pages are counted as two pages.
93*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o job-quota-period=</b><i>value</i>
94*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the accounting period for per-user quotas.
95*5e7646d2SAndroid Build Coastguard WorkerThe value is an integer number of seconds; 86,400 seconds are in one day.
96*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o job-sheets-default=</b><i>banner</i>
97*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-o job-sheets-default=</b><i>banner</i><b>,</b><i>banner</i>
98*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the default banner page(s) to use for print jobs.
99*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o </b><i>name</i><b>=</b><i>value</i>
100*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets a PPD option for the printer.
101*5e7646d2SAndroid Build Coastguard WorkerPPD options can be listed using the <i>-l</i> option with the
102*5e7646d2SAndroid Build Coastguard Worker<b>lpoptions</b>(1)
103*5e7646d2SAndroid Build Coastguard Workercommand.
104*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o </b><i>name</i><b>-default=</b><i>value</i>
105*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets a default server-side option for the destination.
106*5e7646d2SAndroid Build Coastguard WorkerAny print-time option can be defaulted, e.g., "-o number-up-default=2" to set the default "number-up" option value to 2.
107*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o port-monitor=</b><i>name</i>
108*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the binary communications program to use when printing, "none", "bcp", or "tbcp".
109*5e7646d2SAndroid Build Coastguard WorkerThe default program is "none".
110*5e7646d2SAndroid Build Coastguard WorkerThe specified port monitor must be listed in the printer's PPD file.
111*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o printer-error-policy=</b><i>name</i>
112*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the policy for errors such as printers that cannot be found or accessed, don't support the format being printed, fail during submission of the print data, or cause one or more filters to crash.
113*5e7646d2SAndroid Build Coastguard WorkerThe name must be one of "abort-job" (abort the job on error), "retry-job" (retry the job at a future time), "retry-current-job" (retry the current job immediately), or "stop-printer" (stop the printer on error).
114*5e7646d2SAndroid Build Coastguard WorkerThe default error policy is "stop-printer" for printers and "retry-current-job" for
115*5e7646d2SAndroid Build Coastguard Workerclasses.
116*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o printer-is-shared=true</b>
117*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-o printer-is-shared=false</b>
118*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the destination to shared/published or unshared/unpublished.
119*5e7646d2SAndroid Build Coastguard WorkerShared/published destinations are publicly announced by the server on the LAN based on the browsing configuration in <i>cupsd.conf</i>, while unshared/unpublished destinations are not announced.
120*5e7646d2SAndroid Build Coastguard WorkerThe default value is "true".
121*5e7646d2SAndroid Build Coastguard Worker<dt><b>-o printer-op-policy=</b><i>name</i>
122*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the IPP operation policy associated with the destination.
123*5e7646d2SAndroid Build Coastguard WorkerThe name must be defined in the <i>cupsd.conf</i> in a Policy section.
124*5e7646d2SAndroid Build Coastguard WorkerThe default operation policy is "default".
125*5e7646d2SAndroid Build Coastguard Worker<dt><b>-R </b><i>name</i><b>-default</b>
126*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Deletes the named option from <i>printer</i>.
127*5e7646d2SAndroid Build Coastguard Worker<dt><b>-r </b><i>class</i>
128*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Removes the named <i>printer</i> from <i>class</i>.
129*5e7646d2SAndroid Build Coastguard WorkerIf the resulting class becomes empty it is removed.
130*5e7646d2SAndroid Build Coastguard Worker<dt><b>-u allow:</b>{<i>user</i>|<b>@</b><i>group</i>}{<b>,</b><i>user</i>|<b>,@</b><i>group</i>}*
131*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-u deny:</b>{<i>user</i>|<b>@</b><i>group</i>}{<b>,</b><i>user</i>|<b>,@</b><i>group</i>}*
132*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-u allow:all</b>
133*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em"><dt><b>-u deny:none</b>
134*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets user-level access control on a destination.
135*5e7646d2SAndroid Build Coastguard WorkerNames starting with "@" are interpreted as UNIX groups.
136*5e7646d2SAndroid Build Coastguard WorkerThe latter two forms turn user-level access control off.
137*5e7646d2SAndroid Build Coastguard WorkerNote: The user 'root' is not granted special access - using "-u allow:foo,bar" will allow users 'foo' and 'bar' to access the printer but NOT 'root'.
138*5e7646d2SAndroid Build Coastguard Worker<dt><b>-v "</b><i>device-uri</i><b>"</b>
139*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Sets the <i>device-uri</i> attribute of the printer queue.
140*5e7646d2SAndroid Build Coastguard WorkerUse the <i>-v</i> option with the
141*5e7646d2SAndroid Build Coastguard Worker<b>lpinfo</b>(8)
142*5e7646d2SAndroid Build Coastguard Workercommand to get a list of supported device URIs and schemes.
143*5e7646d2SAndroid Build Coastguard Worker<dt><b>-D "</b><i>info</i><b>"</b>
144*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Provides a textual description of the destination.
145*5e7646d2SAndroid Build Coastguard Worker<dt><b>-E</b>
146*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">When specified before the <b>-d</b>, <b>-p</b>, or <b>-x</b> options, forces the use of TLS encryption on the connection to the scheduler.
147*5e7646d2SAndroid Build Coastguard WorkerOtherwise, enables the destination and accepts jobs; this is the same as running the
148*5e7646d2SAndroid Build Coastguard Worker<b>cupsaccept</b>(8)
149*5e7646d2SAndroid Build Coastguard Workerand
150*5e7646d2SAndroid Build Coastguard Worker<b>cupsenable</b>(8)
151*5e7646d2SAndroid Build Coastguard Workerprograms on the destination.
152*5e7646d2SAndroid Build Coastguard Worker<dt><b>-L "</b><i>location</i><b>"</b>
153*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Provides a textual location of the destination.
154*5e7646d2SAndroid Build Coastguard Worker</dl>
155*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="DEPRECATED_OPTIONS">Deprecated Options</a></h2>
156*5e7646d2SAndroid Build Coastguard WorkerThe following <b>lpadmin</b> options are deprecated:
157*5e7646d2SAndroid Build Coastguard Worker<dl class="man">
158*5e7646d2SAndroid Build Coastguard Worker<dt><b>-i </b><i>filename</i>
159*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">This option historically has been used to provide either a System V interface script or (as an implementation side-effect) a PPD file.
160*5e7646d2SAndroid Build Coastguard WorkerNote: Interface scripts are not supported by CUPS.
161*5e7646d2SAndroid Build Coastguard WorkerPPD files and printer drivers are deprecated and will not be supported in a future version of CUPS.
162*5e7646d2SAndroid Build Coastguard Worker<dt><b>-P </b><i>ppd-file</i>
163*5e7646d2SAndroid Build Coastguard Worker<dd style="margin-left: 5.0em">Specifies a PostScript Printer Description (PPD) file to use with the printer.
164*5e7646d2SAndroid Build Coastguard WorkerNote: PPD files and printer drivers are deprecated and will not be supported in a future version of CUPS.
165*5e7646d2SAndroid Build Coastguard Worker</dl>
166*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="CONFORMING_TO">Conforming To</a></h2>
167*5e7646d2SAndroid Build Coastguard WorkerUnlike the System V printing system, CUPS allows printer names to contain any printable character except SPACE, TAB, "/", or "#".
168*5e7646d2SAndroid Build Coastguard WorkerAlso, printer and class names are <i>not</i> case-sensitive.
169*5e7646d2SAndroid Build Coastguard Worker<p>Finally, the CUPS version of <b>lpadmin</b> may ask the user for an access password depending on the printing system configuration.
170*5e7646d2SAndroid Build Coastguard WorkerThis differs from the System V version which requires the root user to execute this command.
171*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="NOTES">Notes</a></h2>
172*5e7646d2SAndroid Build Coastguard WorkerCUPS printer drivers and backends are deprecated and will no longer be supported in a future feature release of CUPS.
173*5e7646d2SAndroid Build Coastguard WorkerPrinters that do not support IPP can be supported using applications such as
174*5e7646d2SAndroid Build Coastguard Worker<b>ippeveprinter</b>(1).
175*5e7646d2SAndroid Build Coastguard Worker<p>The CUPS version of <b>lpadmin</b> does not support all of the System V or Solaris printing system configuration options.
176*5e7646d2SAndroid Build Coastguard Worker<p>Interface scripts are not supported for security reasons.
177*5e7646d2SAndroid Build Coastguard Worker<p>The double meaning of the <b>-E</b> option is an unfortunate historical oddity.
178*5e7646d2SAndroid Build Coastguard Worker<p>The <b>lpadmin</b> command communicates with the scheduler (<b>cupsd</b>) to make changes to the printing system configuration.
179*5e7646d2SAndroid Build Coastguard WorkerThis configuration information is stored in several files including <i>printers.conf</i> and <i>classes.conf</i>.
180*5e7646d2SAndroid Build Coastguard WorkerThese files should not be edited directly and are an implementation detail of CUPS that is subject to change at any time.
181*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="EXAMPLE">Example</a></h2>
182*5e7646d2SAndroid Build Coastguard WorkerCreate an IPP Everywhere print queue:
183*5e7646d2SAndroid Build Coastguard Worker<pre class="man">
184*5e7646d2SAndroid Build Coastguard Worker
185*5e7646d2SAndroid Build Coastguard Worker    lpadmin -p myprinter -E -v ipp://myprinter.local/ipp/print -m everywhere
186*5e7646d2SAndroid Build Coastguard Worker
187*5e7646d2SAndroid Build Coastguard Worker</pre>
188*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="SEE_ALSO">See Also</a></h2>
189*5e7646d2SAndroid Build Coastguard Worker<b>cupsaccept</b>(8),
190*5e7646d2SAndroid Build Coastguard Worker<b>cupsenable</b>(8),
191*5e7646d2SAndroid Build Coastguard Worker<b>lpinfo</b>(8),
192*5e7646d2SAndroid Build Coastguard Worker<b>lpoptions</b>(1),
193*5e7646d2SAndroid Build Coastguard WorkerCUPS Online Help (<a href="http://localhost:631/help">http://localhost:631/help</a>)
194*5e7646d2SAndroid Build Coastguard Worker<h2 class="title"><a name="COPYRIGHT">Copyright</a></h2>
195*5e7646d2SAndroid Build Coastguard WorkerCopyright &copy; 2007-2019 by Apple Inc.
196*5e7646d2SAndroid Build Coastguard Worker
197*5e7646d2SAndroid Build Coastguard Worker</body>
198*5e7646d2SAndroid Build Coastguard Worker</html>
199