2 <!-- SECTION: References -->
4 <TITLE>printers.conf
</TITLE>
8 <P>The CUPS scheduler (cupsd) uses the
9 <VAR>/etc/cups/printers.conf
</VAR> file to store the list of
10 available printers. This file contains only locally defined
11 printers, not remote printers that are created automatically via
12 browsing. Each directive is listed on a line by itself followed
13 by its value. Comments are introduced using the number sign (
"#")
14 character at the beginning of a line.
</P>
16 <P>While the printer configuration file consists of plain text
17 and can be modified using your favorite text editor, you should
18 normally use the
<CODE>lpadmin(
8)
</CODE> command, web interface,
19 or any of the available GUIs to manage your printers instead. If
20 you do choose to edit this file manually, you will need to
21 restart the scheduler to make them active.
</P>
24 <H3 CLASS=
"title"><A NAME=
"Accepting">Accepting
</A></H3>
35 <P>The
<CODE>Accepting
</CODE> directive defines the initial state
36 of the
<VAR>printer-is-accepting-jobs
</VAR> attribute. This state
37 is also set by the
<CODE>accept(
8)
</CODE> and
38 <CODE>reject(
8)
</CODE> commands:
</P>
41 <KBD>/usr/sbin/accept printername
42 /usr/sbin/reject printername
</KBD>
45 <P>This directive must appear inside a
<A
46 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
47 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
51 <H3 CLASS=
"title"><A NAME=
"AllowUser">AllowUser
</A></H3>
62 <P>The
<CODE>AllowUser
</CODE> directive adds a username or group
63 name to the
<VAR>requesting-user-name-allowed
</VAR> attribute
64 which can be set by the
<CODE>lpadmin(
8)
</CODE> command:
</P>
67 <KBD>/usr/sbin/lpadmin -p printername -u allow:foo_user,@bar_group
</KBD>
70 <P>This directive must appear inside a
<A
71 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
72 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A> directive.
73 This directive cannot be used with
<A
74 HREF=
"#DenyUser"><CODE>DenyUser
</CODE></A>.
</P>
77 <H3 CLASS=
"title"><A NAME=
"DefaultPrinter">DefaultPrinter
</A></H3>
82 <DefaultPrinter name
>
89 <P>The
<CODE>DefaultPrinter
</CODE> directive begins a printer
90 definition as the default server destination. The default server
91 destination can be set using the
<CODE>lpadmin(
8)
</CODE>
95 <KBD>/usr/sbin/lpadmin -d printername
</KBD>
98 <P>Note that the server default destination settings can be
99 overridden by the user's default destination settings which are
100 normally set using the
<CODE>lpoptions(
1)
</CODE> command.
</P>
103 <H3 CLASS=
"title"><A NAME=
"DenyUser">DenyUser
</A></H3>
107 <PRE CLASS=
"command">
114 <P>The
<CODE>DenyUser
</CODE> directive adds a username or group
115 name to the
<VAR>requesting-user-name-denied
</VAR> attribute
116 which can be set by the
<CODE>lpadmin(
8)
</CODE> command:
</P>
118 <PRE CLASS=
"command">
119 <KBD>/usr/sbin/lpadmin -p printername -u deny:foo_user,@bar_group
</KBD>
122 <P>This directive must appear inside a
<A
123 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
124 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A> directive.
125 This directive cannot be used with
<A
126 HREF=
"#AllowUser"><CODE>AllowUser
</CODE></A></P>
129 <H3 CLASS=
"title"><A NAME=
"DeviceURI">DeviceURI
</A></H3>
133 <PRE CLASS=
"command">
134 DeviceURI socket://foo.bar.com:
9100
139 <P>The
<CODE>DeviceURI
</CODE> directive defines the value of the
140 <VAR>device-uri-attribute
</VAR> attribute. It is normally set
141 using the
<CODE>lpadmin(
8)
</CODE> command:
</P>
143 <PRE CLASS=
"command">
144 <KBD>/usr/sbin/lpadmin -p printername -v device-uri
</KBD>
147 <P>This directive must appear inside a
<A
148 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
149 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
153 <H3 CLASS=
"title"><SPAN CLASS=
"info">CUPS
1.2</SPAN><A NAME=
"ErrorPolicy">ErrorPolicy
</A></H3>
157 <PRE CLASS=
"command">
158 ErrorPolicy cancel-job
159 ErrorPolicy retry-job
160 ErrorPolicy stop-printer
165 <P>The
<CODE>ErrorPolicy
</CODE> directive defines the policy that
166 is used when a backend is unable to send a print job to the
167 printer. The
<CODE>lpadmin(
8)
</CODE> command sets the current
170 <PRE CLASS=
"command">
171 <KBD>/usr/sbin/lpadmin -p printername -o printer-error-policy=stop-printer
</KBD>
174 <P>The following values are supported:
</P>
178 <LI><CODE>cancel-job
</CODE> - Cancel the job and proceed
179 with the next job in the queue
</LI>
181 <LI><CODE>retry-job
</CODE> - Retry the job after waiting
182 for N seconds; the
<VAR>cupsd.conf
</VAR> <A
183 HREF=
"ref-cupsd-conf.html#JobRetryInterval"><CODE>JobRetryInterval
</CODE></A>
184 directive controls the value of N
</LI>
186 <LI><CODE>stop-printer
</CODE> - Stop the printer and keep
187 the job for future printing; this is the default
192 <P>This directive must appear inside a
<A
193 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
194 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
198 <H3 CLASS=
"title"><A NAME=
"Info">Info
</A></H3>
202 <PRE CLASS=
"command">
208 <P>The
<CODE>Info
</CODE> directive defines the string for the
209 <VAR>printer-info
</VAR> attribute. It is normally set using the
210 <CODE>lpadmin(
8)
</CODE> command:
</P>
212 <PRE CLASS=
"command">
213 <KBD>/usr/sbin/lpadmin -p printername -D
"My Printer"</KBD>
216 <P>This directive must appear inside a
<A
217 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
218 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
222 <H3 CLASS=
"title"><A NAME=
"JobSheets">JobSheets
</A></H3>
226 <PRE CLASS=
"command">
227 JobSheets none,standard
232 <P>The
<CODE>JobSheets
</CODE> directive specifies the default
233 banner pages to print before and after a print job. In the above
234 example, only a
<VAR>standard
</VAR> banner will print after each
235 job. The
<CODE>lpadmin(
8)
</CODE> command is normally used to set
238 <PRE CLASS=
"command">
239 <KBD>/usr/sbin/lpadmin -p printername -o job-sheets-default=none,standard
</KBD>
242 <P>If only one banner file is specified, it will be printed
243 before the files in the job. If a second banner file is
244 specified, it is printed after the files in the job.
</P>
246 <P>The available banner pages depend on the local system
247 configuration; CUPS includes the following standard banner
252 <LI><CODE>none
</CODE> - Do not produce a banner
255 <LI><CODE>classified
</CODE> - A banner page with a
256 "classified
" label at the top and bottom.
</LI>
258 <LI><CODE>confidential
</CODE> - A banner page with a
259 "confidential
" label at the top and bottom.
</LI>
261 <LI><CODE>secret
</CODE> - A banner page with a
262 "secret
" label at the top and bottom.
</LI>
264 <LI><CODE>standard
</CODE> - A banner page with no label
265 at the top and bottom.
</LI>
267 <LI><CODE>topsecret
</CODE> - A banner page with a
268 "top secret
" label at the top and bottom.
</LI>
270 <LI><CODE>unclassified
</CODE> - A banner page with an
271 "unclassified
" label at the top and bottom.
</LI>
275 <P>This directive must appear inside a
<A
276 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
277 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
281 <H3 CLASS=
"title"><A NAME=
"KLimit">KLimit
</A></H3>
285 <PRE CLASS=
"command">
291 <P>The
<CODE>KLimit
</CODE> directive defines the value of the
292 <VAR>job-k-limit
</VAR> attribute. It is normally set using the
293 <CODE>lpadmin(
8)
</CODE> command:
</P>
295 <PRE CLASS=
"command">
296 <KBD>/usr/sbin/lpadmin -p printername -o job-k-limit=
1234</KBD>
299 <P>This directive must appear inside a
<A
300 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
301 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
305 <H3 CLASS=
"title"><A NAME=
"Location">Location
</A></H3>
309 <PRE CLASS=
"command">
310 Location Building
3321
315 <P>The
<CODE>Location
</CODE> directive defines the string for the
316 <VAR>printer-location
</VAR> attribute. It is normally set using the
317 <CODE>lpadmin(
8)
</CODE> command:
</P>
319 <PRE CLASS=
"command">
320 <KBD>/usr/sbin/lpadmin -p printername -L
"Building 3321"</KBD>
323 <P>This directive must appear inside a
<A
324 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
325 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
329 <H3 CLASS=
"title"><SPAN CLASS=
"info">CUPS
1.2</SPAN><A NAME=
"OpPolicy">OpPolicy
</A></H3>
333 <PRE CLASS=
"command">
340 <P>The
<CODE>OpPolicy
</CODE> directive sets the operation policy
341 that is used for the printer. The
<CODE>lpadmin(
8)
</CODE> command
342 sets the current operation policy:
</P>
344 <PRE CLASS=
"command">
345 <KBD>/usr/sbin/lpadmin -p printername -o printer-op-policy=default
</KBD>
348 <P>The default policy is named
"default". All policies correspond
349 to those defined using the
<VAR>cupsd.conf
</VAR> <A
350 HREF=
"ref-cupsd-conf.html#Policy"><CODE>Policy
</CODE></A>
353 <P>This directive must appear inside a
<A
354 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
355 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
359 <H3 CLASS=
"title"><A NAME=
"PageLimit">PageLimit
</A></H3>
363 <PRE CLASS=
"command">
369 <P>The
<CODE>PageLimit
</CODE> directive defines the value of the
370 <VAR>job-page-limit
</VAR> attribute. It can be set using the
371 <CODE>lpadmin(
8)
</CODE> command:
</P>
373 <PRE CLASS=
"command">
374 <KBD>/usr/sbin/lpadmin -p printername -o job-page-limit=
1234</KBD>
377 <P>This directive must appear inside a
<A
378 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
379 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
383 <H3 CLASS=
"title"><SPAN CLASS=
"info">CUPS
1.2</SPAN><A NAME=
"PortMonitor">PortMonitor
</A></H3>
387 <PRE CLASS=
"command">
395 <P>The
<CODE>PortMonitor
</CODE> directive sets the filter program that
396 is used for every print job, typically to encode or package the print
397 data in a format acceptable for a particular printer interface. It is
398 set using the
<CODE>lpadmin(
8)
</CODE> command:
</P>
400 <PRE CLASS=
"command">
401 <KBD>/usr/sbin/lpadmin -p printername -o port-monitor=tbcp
</KBD>
404 <P>The following standard port monitors are included with CUPS:
</P>
408 <LI><CODE>bcp
</CODE> - Encode PostScript print data using
409 the Adobe Binary Control Protocol (BCP)
</LI>
411 <LI><CODE>none
</CODE> - Do not use a port monitor
</LI>
413 <LI><CODE>tbcp
</CODE> - Encode PostScript print data
414 using the Adobe Tagged Binary Control Protocol
419 <P>This directive must appear inside a
<A
420 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
421 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
425 <H3 CLASS=
"title"><A NAME=
"Printer">Printer
</A></H3>
429 <PRE CLASS=
"command">
437 <P>The
<CODE>Printer
</CODE> directive begins a printer
438 definition. Printers are added using the
<CODE>lpadmin(
8)
</CODE>
441 <PRE CLASS=
"command">
442 <KBD>/usr/sbin/lpadmin -p printername ...
</KBD>
446 <H3 CLASS=
"title"><A NAME=
"QuotaPeriod">QuotaPeriod
</A></H3>
450 <PRE CLASS=
"command">
456 <P>The
<CODE>QuotaPeriod
</CODE> directive defines the value of
457 the
<VAR>job-quota-period
</VAR> attribute. Typical values are
458 86400 (
1 day),
604800 (
1 week),
2592000 (
1 month), and
31536000
459 (
1 year). It is set using the
<CODE>lpadmin(
8)
</CODE>
462 <PRE CLASS=
"command">
463 <KBD>/usr/sbin/lpadmin -p printername -o job-quota-period=
604800</KBD>
466 <P>This directive must appear inside a
<A
467 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
468 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
472 <H3 CLASS=
"title"><SPAN CLASS=
"info">CUPS
1.2</SPAN><A NAME=
"Shared">Shared
</A></H3>
476 <PRE CLASS=
"command">
483 <P>The
<CODE>Shared
</CODE> directive defines the initial value of
484 the
<VAR>printer-is-shared
</VAR> attribute. The strings
485 <VAR>yes
</VAR> and
<VAR>no
</VAR> correspond to the true and false
486 values, respectively. The
<CODE>lpadmin(
8)
</CODE> command sets
487 the current state:
</P>
489 <PRE CLASS=
"command">
490 <KBD>/usr/sbin/lpadmin -p printername -o printer-is-shared=true
</KBD>
493 <P>This directive must appear inside a
<A
494 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
495 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
499 <H3 CLASS=
"title"><A NAME=
"State">State
</A></H3>
503 <PRE CLASS=
"command">
510 <P>The
<CODE>State
</CODE> directive defines the initial value of
511 the
<VAR>printer-state
</VAR> attribute. The strings
512 <VAR>idle
</VAR> and
<VAR>stopped
</VAR> correspond to the IPP
513 enumeration values
3 and
5, respectively. The
514 <CODE>cupsenable(
8)
</CODE> and
<CODE>cupsdisable(
8)
</CODE>
515 commands set the current state:
</P>
517 <PRE CLASS=
"command">
518 <KBD>/usr/sbin/cupsenable printername
</KBD>
519 <KBD>/usr/sbin/cupsdisable printername
</KBD>
522 <P>This directive must appear inside a
<A
523 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
524 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
528 <H3 CLASS=
"title"><A NAME=
"StateMessage">StateMessage
</A></H3>
532 <PRE CLASS=
"command">
533 StateMessage Ready to print.
538 <P>The
<CODE>StateMessage
</CODE> directive defines the initial
539 string for the
<VAR>printer-state-message
</VAR> attribute. The
540 following are some example messages:
</P>
542 <PRE CLASS=
"command">
543 StateMessage Connected to host_name...
544 StateMessage Connecting to printer_queue on port port_number...
545 StateMessage Network host host_name is busy; will retry in
30 seconds...
546 StateMessage Printer busy; will retry in
10 seconds...
547 StateMessage Printer is busy; retrying print job...
548 StateMessage Print file accepted - job ID id_number.
549 StateMessage Ready to print.
550 StateMessage Waiting for job to complete
553 <P>This directive must appear inside a
<A
554 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
555 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>
559 <H3 CLASS=
"title"><SPAN CLASS=
"info">CUPS
1.2</SPAN><A NAME=
"StateTime">StateTime
</A></H3>
563 <PRE CLASS=
"command">
569 <P>The
<CODE>StateTime
</CODE> directive defines the UNIX time
570 (seconds since Jan
1,
1970) for the last state change of the
571 queue. It is mapped to the
<VAR>printer-state-change-time
</VAR>
574 <P>This directive must appear inside a
<A
575 HREF=
"#Printer"><CODE>Printer
</CODE></A> or
<A
576 HREF=
"#DefaultPrinter"><CODE>DefaultPrinter
</CODE></A>