]> git.ipfire.org Git - thirdparty/cups.git/blame - doc/help/classes-conf-reference.html
Load cups into easysw/current.
[thirdparty/cups.git] / doc / help / classes-conf-reference.html
CommitLineData
ef416fc2 1<HTML>
2<!-- SECTION: References -->
3<HEAD>
4 <TITLE>classes.conf</TITLE>
5</HEAD>
6<BODY>
7
8<P>The CUPS scheduler (cupsd) uses the
9<VAR>/etc/cups/classes.conf</VAR> file to store the list of
10available classes. This file contains only locally defined
11classes, not remote classes that are created automatically via
12browsing. Each directive is listed on a line by itself followed
13by its value. Comments are introduced using the number sign ("#")
14character at the beginning of a line.</P>
15
16<P>While the class configuration file consists of plain text and
17can be modified using your favorite text editor, you should
18normally use the <CODE>lpadmin(8)</CODE> command, web interface,
19or any of the available GUIs to manage your classes instead. If
20you do choose to edit this file manually, you will need to
21restart the scheduler to make them active.</P>
22
23
24<H3 CLASS="title"><A NAME="Accepting">Accepting</A></H3>
25
26<H4>Examples</H4>
27
28<PRE CLASS="command">
29Accepting yes
30Accepting no
31</PRE>
32
33<H4>Description</H4>
34
35<P>The <CODE>Accepting</CODE> directive defines the initial state
36of the <VAR>printer-is-accepting-jobs</VAR> attribute. This state
37is also set by the <CODE>accept(8)</CODE> and
38<CODE>reject(8)</CODE> commands:</P>
39
40<PRE CLASS="command">
41<KBD>/usr/sbin/accept classname
42/usr/sbin/reject classname</KBD>
43</PRE>
44
45<P>This directive must appear inside a <A
46HREF="#Class"><CODE>Class</CODE></A> or <A
47HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
48directive.</P>
49
50
51<H3 CLASS="title"><A NAME="AllowUser">AllowUser</A></H3>
52
53<H4>Examples</H4>
54
55<PRE CLASS="command">
56AllowUser foo_user
57AllowUser @bar_group
58</PRE>
59
60<H4>Description</H4>
61
62<P>The <CODE>AllowUser</CODE> directive adds a username or group
63name to the <VAR>requesting-user-name-allowed</VAR> attribute
64which can be set by the <CODE>lpadmin(8)</CODE> command:</P>
65
66<PRE CLASS="command">
67<KBD>/usr/sbin/lpadmin -p classname -u allow:foo_user,@bar_group</KBD>
68</PRE>
69
70<P>This directive must appear inside a <A
71HREF="#Class"><CODE>Class</CODE></A> or <A
72HREF="#DefaultClass"><CODE>DefaultClass</CODE></A> directive.
73This directive cannot be used with <A
74HREF="#DenyUser"><CODE>DenyUser</CODE></A>.</P>
75
76
77<H3 CLASS="title"><A NAME="Class">Class</A></H3>
78
79<H4>Examples</H4>
80
81<PRE CLASS="command">
82&lt;Class name&gt;
83...
84&lt;/Class&gt;
85</PRE>
86
87<H4>Description</H4>
88
89<P>The <CODE>Class</CODE> directive begins a class definition.
90Classes are added using the <CODE>lpadmin(8)</CODE> command:
91
92<PRE CLASS="command">
93<KBD>/usr/sbin/lpadmin -p printername -c classname</KBD>
94</PRE>
95
96
97<H3 CLASS="title"><A NAME="DefaultClass">DefaultClass</A></H3>
98
99<H4>Examples</H4>
100
101<PRE CLASS="command">
102&lt;DefaultClass name&gt;
103...
104&lt;/Class&gt;
105</PRE>
106
107<H4>Description</H4>
108
109<P>The <CODE>DefaultClass</CODE> directive begins a class
110definition as the default server destination. The default server
111destination can be set using the <CODE>lpadmin(8)</CODE>
112command:</P>
113
114<PRE CLASS="command">
115<KBD>/usr/sbin/lpadmin -d classname</KBD>
116</PRE>
117
118<P>Note that the server default destination settings can be
119overridden by the user's default destination settings which are
120normally set using the <CODE>lpoptions(1)</CODE> command.</P>
121
122
123<H3 CLASS="title"><A NAME="DenyUser">DenyUser</A></H3>
124
125<H4>Examples</H4>
126
127<PRE CLASS="command">
128DenyUser foo_user
129DenyUser @bar_group
130</PRE>
131
132<H4>Description</H4>
133
134<P>The <CODE>DenyUser</CODE> directive adds a username or group
135name to the <VAR>requesting-user-name-denied</VAR> attribute
136which can be set by the <CODE>lpadmin(8)</CODE> command:</P>
137
138<PRE CLASS="command">
139<KBD>/usr/sbin/lpadmin -p classname -u deny:foo_user,@bar_group</KBD>
140</PRE>
141
142<P>This directive must appear inside a <A
143HREF="#Class"><CODE>Class</CODE></A> or <A
144HREF="#DefaultClass"><CODE>DefaultClass</CODE></A> directive.
145This directive cannot be used with <A
146HREF="#AllowUser"><CODE>AllowUser</CODE></A></P>
147
148
149<H3 CLASS="title"><SPAN CLASS="info">CUPS 1.2</SPAN><A NAME="ErrorPolicy">ErrorPolicy</A></H3>
150
151<H4>Examples</H4>
152
153<PRE CLASS="command">
154ErrorPolicy cancel-job
155ErrorPolicy retry-job
156ErrorPolicy stop-printer
157</PRE>
158
159<H4>Description</H4>
160
161<P>The <CODE>ErrorPolicy</CODE> directive defines the policy that
162is used when a backend is unable to send a print job to the
163printer. The <CODE>lpadmin(8)</CODE> command sets the current
164error policy:</P>
165
166<PRE CLASS="command">
167<KBD>/usr/sbin/lpadmin -p classname -o printer-error-policy=stop-printer</KBD>
168</PRE>
169
170<P>The following values are supported:</P>
171
172<UL>
173
174 <LI><CODE>cancel-job</CODE> - Cancel the job and proceed
175 with the next job in the queue</LI>
176
177 <LI><CODE>retry-job</CODE> - Retry the job after waiting
178 for N seconds; the <VAR>cupsd.conf</VAR> <A
179 HREF="cupsd-conf-reference.html#JobRetryInterval"><CODE>JobRetryInterval</CODE></A>
180 directive controls the value of N</LI>
181
182 <LI><CODE>stop-printer</CODE> - Stop the printer and keep
183 the job for future printing; this is the default
184 value</LI>
185
186</UL>
187
188<P>This directive must appear inside a <A
189HREF="#Class"><CODE>Class</CODE></A> or <A
190HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
191directive.</P>
192
193
194<H3 CLASS="title"><A NAME="Info">Info</A></H3>
195
196<H4>Examples</H4>
197
198<PRE CLASS="command">
199Info My Class
200</PRE>
201
202<H4>Description</H4>
203
204<P>The <CODE>Info</CODE> directive defines the string for the
205<VAR>printer-info</VAR> attribute. It is normally set using the
206<CODE>lpadmin(8)</CODE> command:</P>
207
208<PRE CLASS="command">
209<KBD>/usr/sbin/lpadmin -p classname -D "My Class"</KBD>
210</PRE>
211
212<P>This directive must appear inside a <A
213HREF="#Class"><CODE>Class</CODE></A> or <A
214HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
215directive.</P>
216
217
218<H3 CLASS="title"><A NAME="JobSheets">JobSheets</A></H3>
219
220<H4>Examples</H4>
221
222<PRE CLASS="command">
223JobSheets none,standard
224</PRE>
225
226<H4>Description</H4>
227
228<P>The <CODE>JobSheets</CODE> directive specifies the default
229banner pages to print before and after a print job. In the above
230example, only a <VAR>standard</VAR> banner will print after each
231job. The <CODE>lpadmin(8)</CODE> command is normally used to set
232the default banners:
233
234<PRE CLASS="command">
235<KBD>/usr/sbin/lpadmin -p classname -o job-sheets-default=none,standard</KBD>
236</PRE>
237
238<P>If only one banner file is specified, it will be printed
239before the files in the job. If a second banner file is
240specified, it is printed after the files in the job.</P>
241
242<P>The available banner pages depend on the local system
243configuration; CUPS includes the following standard banner
244files:</P>
245
246<UL>
247
248 <LI><CODE>none</CODE> - Do not produce a banner
249 page.</LI>
250
251 <LI><CODE>classified</CODE> - A banner page with a
252 &quot;classified&quot; label at the top and bottom.</LI>
253
254 <LI><CODE>confidential</CODE> - A banner page with a
255 &quot;confidential&quot; label at the top and bottom.</LI>
256
257 <LI><CODE>secret</CODE> - A banner page with a
258 &quot;secret&quot; label at the top and bottom.</LI>
259
260 <LI><CODE>standard</CODE> - A banner page with no label
261 at the top and bottom.</LI>
262
263 <LI><CODE>topsecret</CODE> - A banner page with a
264 &quot;top secret&quot; label at the top and bottom.</LI>
265
266 <LI><CODE>unclassified</CODE> - A banner page with an
267 &quot;unclassified&quot; label at the top and bottom.</LI>
268
269</UL>
270
271<P>This directive must appear inside a <A
272HREF="#Class"><CODE>Class</CODE></A> or <A
273HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
274directive.</P>
275
276
277<H3 CLASS="title"><A NAME="KLimit">KLimit</A></H3>
278
279<H4>Examples</H4>
280
281<PRE CLASS="command">
282KLimit 1234
283</PRE>
284
285<H4>Description</H4>
286
287<P>The <CODE>KLimit</CODE> directive defines the value of the
288<VAR>job-k-limit</VAR> attribute. It is normally set using the
289<CODE>lpadmin(8)</CODE> command:</P>
290
291<PRE CLASS="command">
292<KBD>/usr/sbin/lpadmin -p classname -o job-k-limit=1234</KBD>
293</PRE>
294
295<P>This directive must appear inside a <A
296HREF="#Class"><CODE>Class</CODE></A> or <A
297HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
298directive.</P>
299
300
301<H3 CLASS="title"><A NAME="Location">Location</A></H3>
302
303<H4>Examples</H4>
304
305<PRE CLASS="command">
306Location Building 3321
307</PRE>
308
309<H4>Description</H4>
310
311<P>The <CODE>Location</CODE> directive defines the string for the
312<VAR>printer-location</VAR> attribute. It is normally set using the
313<CODE>lpadmin(8)</CODE> command:</P>
314
315<PRE CLASS="command">
316<KBD>/usr/sbin/lpadmin -p classname -L "Building 3321"</KBD>
317</PRE>
318
319<P>This directive must appear inside a <A
320HREF="#Class"><CODE>Class</CODE></A> or <A
321HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
322directive.</P>
323
324
325<H3 CLASS="title"><SPAN CLASS="info">CUPS 1.2</SPAN><A NAME="OpPolicy">OpPolicy</A></H3>
326
327<H4>Examples</H4>
328
329<PRE CLASS="command">
330OpPolicy default
331OpPolicy mypolicy
332</PRE>
333
334<H4>Description</H4>
335
336<P>The <CODE>OpPolicy</CODE> directive sets the operation policy
337that is used for the printer. The <CODE>lpadmin(8)</CODE> command
338sets the current operation policy:</P>
339
340<PRE CLASS="command">
341<KBD>/usr/sbin/lpadmin -p classname -o printer-op-policy=default</KBD>
342</PRE>
343
344<P>The default policy is named "default". All policies correspond
345to those defined using the <VAR>cupsd.conf</VAR> <A
346HREF="cupsd-conf-reference.html#Policy"><CODE>Policy</CODE></A>
347directive.</P>
348
349<P>This directive must appear inside a <A
350HREF="#Class"><CODE>Class</CODE></A> or <A
351HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
352directive.</P>
353
354
355<H3 CLASS="title"><A NAME="PageLimit">PageLimit</A></H3>
356
357<H4>Examples</H4>
358
359<PRE CLASS="command">
360PageLimit 1234
361</PRE>
362
363<H4>Description</H4>
364
365<P>The <CODE>PageLimit</CODE> directive defines the value of the
366<VAR>job-page-limit</VAR> attribute. It can be set using the
367<CODE>lpadmin(8)</CODE> command:</P>
368
369<PRE CLASS="command">
370<KBD>/usr/sbin/lpadmin -p classname -o job-page-limit=1234</KBD>
371</PRE>
372
373<P>This directive must appear inside a <A
374HREF="#Class"><CODE>Class</CODE></A> or <A
375HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
376directive.</P>
377
378
379<H3 CLASS="title"><A NAME="Printer">Printer</A></H3>
380
381<H4>Examples</H4>
382
383<PRE CLASS="command">
384Printer bcp
385Printer none
386Printer tbcp
387</PRE>
388
389<H4>Description</H4>
390
391<P>The <CODE>Printer</CODE> directive adds a printer to a class.
392Printers are added to a class using the <CODE>lpadmin(8)</CODE>
393command:</P>
394
395<PRE CLASS="command">
396<KBD>/usr/sbin/lpadmin -p printername -c classname</KBD>
397</PRE>
398
399<P>This directive must appear inside a <A
400HREF="#Class"><CODE>Class</CODE></A> or <A
401HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
402directive.</P>
403
404
405<H3 CLASS="title"><A NAME="QuotaPeriod">QuotaPeriod</A></H3>
406
407<H4>Examples</H4>
408
409<PRE CLASS="command">
410QuotaPeriod 604800
411</PRE>
412
413<H4>Description</H4>
414
415<P>The <CODE>QuotaPeriod</CODE> directive defines the value of
416the <VAR>job-quota-period</VAR> attribute. Typical values are
41786400 (1 day), 604800 (1 week), 2592000 (1 month), and 31536000
418(1 year). It is set using the <CODE>lpadmin(8)</CODE>
419command:</P>
420
421<PRE CLASS="command">
422<KBD>/usr/sbin/lpadmin -p classname -o job-quota-period=604800</KBD>
423</PRE>
424
425<P>This directive must appear inside a <A
426HREF="#Class"><CODE>Class</CODE></A> or <A
427HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
428directive.</P>
429
430
431<H3 CLASS="title"><SPAN CLASS="info">CUPS 1.2</SPAN><A NAME="Shared">Shared</A></H3>
432
433<H4>Examples</H4>
434
435<PRE CLASS="command">
436Shared yes
437Shared no
438</PRE>
439
440<H4>Description</H4>
441
442<P>The <CODE>Shared</CODE> directive defines the initial value of
443the <VAR>printer-is-shared</VAR> attribute. The strings
444<VAR>yes</VAR> and <VAR>no</VAR> correspond to the true and false
445values, respectively. The <CODE>lpadmin(8)</CODE> command sets
446the current state:</P>
447
448<PRE CLASS="command">
449<KBD>/usr/sbin/lpadmin -p classname -o printer-is-shared=true</KBD>
450</PRE>
451
452<P>This directive must appear inside a <A
453HREF="#Class"><CODE>Class</CODE></A> or <A
454HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
455directive.</P>
456
457
458<H3 CLASS="title"><A NAME="State">State</A></H3>
459
460<H4>Examples</H4>
461
462<PRE CLASS="command">
463State idle
464State stopped
465</PRE>
466
467<H4>Description</H4>
468
469<P>The <CODE>State</CODE> directive defines the initial value of
470the <VAR>printer-state</VAR> attribute. The strings
471<VAR>idle</VAR> and <VAR>stopped</VAR> correspond to the IPP
472enumeration values 3 and 5, respectively. The
473<CODE>cupsenable(8)</CODE> and <CODE>cupsdisable(8)</CODE>
474commands set the current state:</P>
475
476<PRE CLASS="command">
477<KBD>/usr/sbin/cupsenable classname</KBD>
478<KBD>/usr/sbin/cupsdisable classname</KBD>
479</PRE>
480
481<P>This directive must appear inside a <A
482HREF="#Class"><CODE>Class</CODE></A> or <A
483HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
484directive.</P>
485
486
487<H3 CLASS="title"><A NAME="StateMessage">StateMessage</A></H3>
488
489<H4>Examples</H4>
490
491<PRE CLASS="command">
492StateMessage Ready to print.
493</PRE>
494
495<H4>Description</H4>
496
497<P>The <CODE>StateMessage</CODE> directive defines the initial
498string for the <VAR>printer-state-message</VAR> attribute. The
499following are some example messages:</P>
500
501<PRE CLASS="command">
502StateMessage Connected to host_name...
503StateMessage Connecting to printer_queue on port port_number...
504StateMessage Network host host_name is busy; will retry in 30 seconds...
505StateMessage Class busy; will retry in 10 seconds...
506StateMessage Class is busy; retrying print job...
507StateMessage Print file accepted - job ID id_number.
508StateMessage Ready to print.
509StateMessage Waiting for job to complete
510</PRE>
511
512<P>This directive must appear inside a <A
513HREF="#Class"><CODE>Class</CODE></A> or <A
514HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
515directive.</P>
516
517
518<H3 CLASS="title"><SPAN CLASS="info">CUPS 1.2</SPAN><A NAME="StateTime">StateTime</A></H3>
519
520<H4>Examples</H4>
521
522<PRE CLASS="command">
523StateTime 1133542425
524</PRE>
525
526<H4>Description</H4>
527
528<P>The <CODE>StateTime</CODE> directive defines the UNIX time
529(seconds since Jan 1, 1970) for the last state change of the
530queue. It is mapped to the <VAR>printer-state-change-time</VAR>
531attribute.</P>
532
533<P>This directive must appear inside a <A
534HREF="#Class"><CODE>Class</CODE></A> or <A
535HREF="#DefaultClass"><CODE>DefaultClass</CODE></A>
536directive.</P>
537
538
539</BODY>
540</HTML>