xref: /csrg-svn/usr.sbin/lpr/lpq/lpq.1 (revision 61845)
1*61845Sbostic.\" Copyright (c) 1983, 1990, 1993
2*61845Sbostic.\"	The Regents of the University of California.  All rights reserved.
319726Smckusick.\"
449513Scael.\" %sccs.include.redist.roff%
519726Smckusick.\"
6*61845Sbostic.\"     @(#)lpq.1	8.1 (Berkeley) 06/06/93
735749Sbostic.\"
844722Scael.Dd
944722Scael.Dt LPQ 1
1044722Scael.Os BSD 4.2
1144722Scael.Sh NAME
1244722Scael.Nm lpq
1344722Scael.Nd spool queue examination program
1444722Scael.Sh SYNOPSIS
1544722Scael.Nm lpq
1644722Scael.Op Fl l
1749513Scael.Op Fl P Ns Ar printer
1844722Scael.Op  job # ...
1944722Scael.Op  user ...
2044722Scael.Sh DESCRIPTION
2144956Scael.Nm Lpq
2219726Smckusickexamines the spooling area used by
2344722Scael.Xr lpd  8
2430997Sbosticfor printing files on the line printer, and reports the status of the
2544722Scaelspecified jobs or all jobs associated with a user.
2644956Scael.Nm Lpq
2744722Scaelinvoked
2844722Scaelwithout any arguments reports on any jobs currently in the queue.
2944722Scael.Pp
3044722ScaelOptions:
3144722Scael.Pp
3249513Scael.Bl -tag -width indent
3349513Scael.It Fl P
3444722ScaelSpecify a particular printer, otherwise the default
3544722Scaelline printer is used (or the value of the
3644722Scael.Ev PRINTER
3744722Scaelvariable in the
3830997Sbosticenvironment). All other arguments supplied are interpreted as user
3930997Sbosticnames or job numbers to filter out only those jobs of interest.
4049513Scael.It Fl l
4144722ScaelInformation about each of the files comprising the job entry
4244722Scaelis printed.
4344722ScaelNormally, only as much information as will fit on one line is displayed.
4449513Scael.El
4544722Scael.Pp
4644722ScaelFor each job submitted (i.e. invocation of
4744722Scael.Xr lpr  1  )
4844722Scael.Nm lpq
4919726Smckusickreports the user's name, current rank in the queue, the
5019726Smckusicknames of files comprising the job, the job identifier (a number which
5119726Smckusickmay be supplied to
5244722Scael.Xr lprm  1
5319726Smckusickfor removing a specific job), and the total size in bytes.
5419726SmckusickJob ordering is dependent on
5519726Smckusickthe algorithm used to scan the spooling directory and is supposed
5649513Scaelto be
5749513Scael.Tn FIFO
5849513Scael(First in First Out).
5919726SmckusickFile names comprising a job may be unavailable
6019726Smckusick(when
6144722Scael.Xr lpr  1
6219726Smckusickis used as a sink in a pipeline) in which case the file
6349513Scaelis indicated as ``(standard input)''.
6444722Scael.Pp
6519726SmckusickIf
6644722Scael.Nm lpq
6719726Smckusickwarns that there is no daemon present (i.e. due to some malfunction),
6819726Smckusickthe
6944722Scael.Xr lpc  8
7019726Smckusickcommand can be used to restart the printer daemon.
7144722Scael.Sh ENVIRONMENT
7244722ScaelIf the following environment variable exists, it is used by
7344722Scael.Nm lpq :
7449513Scael.Bl -tag -width PRINTER
7549513Scael.It Ev PRINTER
7644722ScaelSpecifies an alternate default printer.
7749513Scael.El
7844722Scael.Sh FILES
7949513Scael.Bl -tag -width /usr/share/misc/termcap -compact
8049513Scael.It Pa /etc/printcap
8149513ScaelTo determine printer characteristics.
8249513Scael.It Pa /var/spool/*
8349513ScaelThe spooling directory, as determined from printcap.
8449513Scael.It Pa /var/spool/*/cf*
8549513ScaelControl files specifying jobs.
8649513Scael.It Pa /var/spool/*/lock
8749513ScaelThe lock file to obtain the currently active job.
8849513Scael.It Pa /usr/share/misc/termcap
8949513ScaelFor manipulating the screen for repeated display.
9049513Scael.El
9144722Scael.Sh SEE ALSO
9244722Scael.Xr lpr 1 ,
9344722Scael.Xr lprm 1 ,
9444722Scael.Xr lpc 8 ,
9544722Scael.Xr lpd 8
9644722Scael.Sh HISTORY
9744956Scael.Nm Lpq
9849513Scaelappeared in
9949513Scael.Bx 3 .
10044722Scael.Sh BUGS
10119726SmckusickDue to the dynamic nature of the information in the spooling directory
10249513Scael.Nm lpq
10349513Scaelmay report unreliably.
10419726SmckusickOutput formatting is sensitive to the line length of the terminal;
10519726Smckusickthis can results in widely spaced columns.
10644722Scael.Sh DIAGNOSTICS
10719726SmckusickUnable to open various files.  The lock file being malformed.  Garbage
10819726Smckusickfiles when there is no daemon active, but files in the spooling directory.
109