Remove advertising header from usr.sbin/
[dragonfly.git] / usr.sbin / lpr / SMM.doc / 7.t
1 .\" Copyright (c) 1983, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. Neither the name of the University nor the names of its contributors
13 .\"    may be used to endorse or promote products derived from this software
14 .\"    without specific prior written permission.
15 .\"
16 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 .\" SUCH DAMAGE.
27 .\"
28 .\"     @(#)7.t 8.1 (Berkeley) 6/8/93
29 .\"
30 .NH 1
31 Troubleshooting
32 .PP
33 There are several messages that may be generated by the
34 the line printer system.  This section
35 categorizes the most common and explains the cause
36 for their generation.  Where the message implies a failure,
37 directions are given to remedy the problem.
38 .PP
39 In the examples below, the name
40 .I printer
41 is the name of the printer from the
42 .I printcap
43 database.
44 .NH 2
45 LPR
46 .SH
47 lpr: \fIprinter\fP\|: unknown printer
48 .IP
49 The
50 .I printer
51 was not found in the
52 .I printcap
53 database.  Usually this is a typing mistake; however, it may indicate
54 a missing or incorrect entry in the /etc/printcap file.
55 .SH
56 lpr: \fIprinter\fP\|: jobs queued, but cannot start daemon.
57 .IP
58 The connection to 
59 .I lpd
60 on the local machine failed. 
61 This usually means the printer server started at
62 boot time has died or is hung.  Check the local socket
63 /dev/printer to be sure it still exists (if it does not exist,
64 there is no 
65 .I lpd
66 process running). 
67 Usually it is enough to get a super-user to type the following to
68 restart
69 .IR lpd .
70 .DS
71 % /usr/lib/lpd
72 .DE
73 You can also check the state of the master printer daemon with the following.
74 .DS
75 % ps l`cat /usr/spool/lpd.lock`
76 .DE
77 .IP
78 Another possibility is that the
79 .I lpr
80 program is not set-user-id to \fIroot\fP, set-group-id to group \fIdaemon\fP.
81 This can be checked with
82 .DS
83 % ls \-lg /usr/ucb/lpr
84 .DE
85 .SH
86 lpr: \fIprinter\fP\|: printer queue is disabled
87 .IP
88 This means the queue was turned off with
89 .DS
90 % lpc disable \fIprinter\fP
91 .DE
92 to prevent 
93 .I lpr
94 from putting files in the queue.  This is normally
95 done by the system manager when a printer is
96 going to be down for a long time.  The
97 printer can be turned back on by a super-user with
98 .IR lpc .
99 .NH 2
100 LPQ
101 .SH
102 waiting for \fIprinter\fP to become ready (offline ?)
103 .IP
104 The printer device could not be opened by the daemon. 
105 This can happen for several reasons,
106 the most common is that the printer is turned off-line.
107 This message can also be generated if the printer is out
108 of paper, the paper is jammed, etc.
109 The actual reason is dependent on the meaning
110 of error codes returned by system device driver. 
111 Not all printers supply enough information 
112 to distinguish when a printer is off-line or having
113 trouble (e.g. a printer connected through a serial line). 
114 Another possible cause of this message is
115 some other process, such as an output filter,
116 has an exclusive open on the device.  Your only recourse
117 here is to kill off the offending program(s) and
118 restart the printer with
119 .IR lpc .
120 .SH
121 \fIprinter\fP is ready and printing
122 .IP
123 The
124 .I lpq
125 program checks to see if a daemon process exists for
126 .I printer
127 and prints the file \fIstatus\fP located in the spooling directory.
128 If the daemon is hung, a super user can use
129 .I lpc
130 to abort the current daemon and start a new one.
131 .SH
132 waiting for \fIhost\fP to come up
133 .IP
134 This implies there is a daemon trying to connect to the remote
135 machine named
136 .I host
137 to send the files in the local queue. 
138 If the remote machine is up,
139 .I lpd
140 on the remote machine is probably dead or
141 hung and should be restarted as mentioned for
142 .IR lpr .
143 .SH
144 sending to \fIhost\fP
145 .IP
146 The files should be in the process of being transferred to the remote
147 .IR host .
148 If not, the local daemon should be aborted and started with
149 .IR lpc .
150 .SH
151 Warning: \fIprinter\fP is down
152 .IP
153 The printer has been marked as being unavailable with
154 .IR lpc .
155 .SH
156 Warning: no daemon present
157 .IP
158 The \fIlpd\fP process overseeing
159 the spooling queue, as specified in the ``lock'' file
160 in that directory, does not exist.  This normally occurs
161 only when the daemon has unexpectedly died.
162 The error log file for the printer and the \fIsyslogd\fP logs
163 should be checked for a
164 diagnostic from the deceased process.
165 To restart an \fIlpd\fP, use
166 .DS
167 % lpc restart \fIprinter\fP
168 .DE
169 .SH
170 no space on remote; waiting for queue to drain
171 .IP
172 This implies that there is insufficient disk space on the remote.
173 If the file is large enough, there will never be enough space on
174 the remote (even after the queue on the remote is empty). The solution here
175 is to move the spooling queue or make more free space on the remote.
176 .NH 2
177 LPRM
178 .SH
179 lprm: \fIprinter\fP\|: cannot restart printer daemon
180 .IP
181 This case is the same as when
182 .I lpr
183 prints that the daemon cannot be started.
184 .NH 2
185 LPD
186 .PP
187 The
188 .I lpd
189 program can log many different messages using \fIsyslogd\fP\|(8).
190 Most of these messages are about files that can not
191 be opened and usually imply that the
192 .I printcap
193 file or the protection modes of the files are
194 incorrect.   Files may also be inaccessible if people
195 manually manipulate the line printer system (i.e. they
196 bypass the
197 .I lpr
198 program). 
199 .PP
200 In addition to messages generated by 
201 .IR lpd ,
202 any of the filters that
203 .I lpd
204 spawns may log messages using \fIsyslogd\fP or to the error log file
205 (the file specified in the \fBlf\fP entry in \fIprintcap\fP\|).
206 .NH 2
207 LPC
208 .PP
209 .SH
210 couldn't start printer
211 .IP
212 This case is the same as when
213 .I lpr
214 reports that the daemon cannot be started.
215 .SH
216 cannot examine spool directory
217 .IP
218 Error messages beginning with ``cannot ...'' are usually because of
219 incorrect ownership or protection mode of the lock file, spooling
220 directory or the
221 .I lpc
222 program.