1
.\" $OpenBSD: 2.t,v 1.2 1997/01/17 15:54:16 millert Exp $
3
.\" Copyright (c) 1983, 1993
4
.\" The Regents of the University of California. All rights reserved.
6
.\" Redistribution and use in source and binary forms, with or without
7
.\" modification, are permitted provided that the following conditions
9
.\" 1. Redistributions of source code must retain the above copyright
10
.\" notice, this list of conditions and the following disclaimer.
11
.\" 2. Redistributions in binary form must reproduce the above copyright
12
.\" notice, this list of conditions and the following disclaimer in the
13
.\" documentation and/or other materials provided with the distribution.
14
.\" 3. All advertising materials mentioning features or use of this software
15
.\" must display the following acknowledgement:
16
.\" This product includes software developed by the University of
17
.\" California, Berkeley and its contributors.
18
.\" 4. Neither the name of the University nor the names of its contributors
19
.\" may be used to endorse or promote products derived from this software
20
.\" without specific prior written permission.
22
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
23
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
26
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
27
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
28
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34
.\" @(#)2.t 8.1 (Berkeley) 6/8/93
39
lpd \- line printer daemon
43
usually invoked at boot time from the /etc/rc file, acts as
44
a master server for coordinating and controlling
45
the spooling queues configured in the printcap file.
48
is started it makes a single pass through the
50
database restarting any printers that have jobs.
53
listens for service requests on multiple sockets,
54
one in the UNIX domain (named ``/dev/printer'') for
55
local requests, and one in the Internet domain
56
(under the ``printer'' service specification)
57
for requests for printer access from off machine;
58
see \fIsocket\fP\|(2) and \fIservices\fP\|(5)
59
for more information on sockets and service
60
specifications, respectively.
62
spawns a copy of itself to process the request; the master daemon
63
continues to listen for new requests.
65
Clients communicate with
67
using a simple transaction oriented protocol.
68
Authentication of remote clients is done based
69
on the ``privilege port'' scheme employed by
70
\fIrshd\fP\|(8C) and \fIrcmd\fP\|(3X).
71
The following table shows the requests
74
In each request the first byte indicates the
75
``meaning'' of the request, followed by the name
76
of the printer to which it should be applied. Additional
77
qualifiers may follow, depending on the request.
81
Request Interpretation
83
^Aprinter\en check the queue for jobs and print any found
84
^Bprinter\en receive and queue a job from another machine
85
^Cprinter [users ...] [jobs ...]\en return short list of current queue state
86
^Dprinter [users ...] [jobs ...]\en return long list of current queue state
87
^Eprinter person [users ...] [jobs ...]\en remove jobs from a queue
91
The \fIlpr\fP\|(1) command
92
is used by users to enter a print job in a local queue and to notify
95
that there are new jobs in the spooling area.
97
either schedules the job to be printed locally, or if
98
printing remotely, attempts to forward
99
the job to the appropriate machine.
100
If the printer cannot be opened or the destination
101
machine is unreachable, the job will remain queued until it is
102
possible to complete the work.
104
lpq \- show line printer queue
107
program works recursively backwards displaying the queue of the machine with
108
the printer and then the queue(s) of the machine(s) that lead to it.
110
has two forms of output: in the default, short, format it
111
gives a single line of output per queued job; in the long
112
format it shows the list of files, and their sizes, that
115
lprm \- remove jobs from a queue
117
The \fIlprm\fP\|(1) command deletes jobs from a spooling
118
queue. If necessary, \fIlprm\fP will first kill off a
119
running daemon that is servicing the queue and restart
120
it after the required files are removed. When removing
121
jobs destined for a remote printer, \fIlprm\fP acts
122
similarly to \fIlpq\fP except it first checks locally
123
for jobs to remove and then
124
tries to remove files in queues off-machine.
126
lpc \- line printer control program
130
program is used by the system administrator to control the
131
operation of the line printer system.
132
For each line printer configured in /etc/printcap,
136
disable or enable a printer,
138
disable or enable a printer's spooling queue,
140
rearrange the order of jobs in a spooling queue,
142
find the status of printers, and their associated
143
spooling queues and printer daemons.