BSD 4_4 development
[unix-history] / usr / share / man / cat1 / lprm.0
LPRM(1) BSD Reference Manual LPRM(1)
N\bNA\bAM\bME\bE
l\blp\bpr\brm\bm - remove jobs from the line printer spooling queue
S\bSY\bYN\bNO\bOP\bPS\bSI\bIS\bS
l\blp\bpr\brm\bm [-\b-P\bP_\bp_\br_\bi_\bn_\bt_\be_\br] [-\b-] [job # ...] [_\bu_\bs_\be_\br _\b._\b._\b.]
D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
L\bLp\bpr\brm\bm will remove a job, or jobs, from a printer's spool queue. Since the
spooling directory is protected from users, using l\blp\bpr\brm\bm is normally the
only method by which a user may remove a job. The owner of a job is de-
termined by the user's login name and host name on the machine where the
lpr(1) command was invoked.
Options and arguments:
-\b-P\bP_\bp_\br_\bi_\bn_\bt_\be_\br
Specify the queue associated with a specific _\bp_\br_\bi_\bn_\bt_\be_\br (otherwise
the default printer is used).
-\b- If a single `-\b-' is given, l\blp\bpr\brm\bm will remove all jobs which a user
owns. If the super-user employs this flag, the spool queue will
be emptied entirely.
_\bu_\bs_\be_\br Causes l\blp\bpr\brm\bm to attempt to remove any jobs queued belonging to
that user (or users). This form of invoking l\blp\bpr\brm\bm is useful only
to the super-user.
_\bj_\bo_\bb _\b# A user may dequeue an individual job by specifying its job num-
ber. This number may be obtained from the lpq(1) program, e.g.
% lpq -l
1st:ken [job #013ucbarpa]
(standard input) 100 bytes
% lprm 13
If neither arguments or options are given, L\bLp\bpr\brm\bm will delete the currently
active job if it is owned by the user who invoked l\blp\bpr\brm\bm.
L\bLp\bpr\brm\bm announces the names of any files it removes and is silent if there
are no jobs in the queue which match the request list.
L\bLp\bpr\brm\bm will kill off an active daemon, if necessary, before removing any
spooling files. If a daemon is killed, a new one is automatically
restarted upon completion of file removals.
E\bEN\bNV\bVI\bIR\bRO\bON\bNM\bME\bEN\bNT\bT
If the following environment variable exists, it is utilized by l\blp\bpr\brm\bm.
PRINTER If the environment variable PRINTER exists, and a printer has
not been specified with the -\b-P\bP option, the default printer is
assumed from PRINTER.
F\bFI\bIL\bLE\bES\bS
/etc/printcap Printer characteristics file.
/var/spool/* Spooling directories.
/var/spool/*/lock Lock file used to obtain the pid of the current dae-
mon and the job number of the currently active job.
S\bSE\bEE\bE A\bAL\bLS\bSO\bO
lpr(1), lpq(1), lpd(8)
D\bDI\bIA\bAG\bGN\bNO\bOS\bST\bTI\bIC\bCS\bS
``Permission denied" if the user tries to remove files other than his
own.
B\bBU\bUG\bGS\bS
Since there are race conditions possible in the update of the lock file,
the currently active job may be incorrectly identified.
H\bHI\bIS\bST\bTO\bOR\bRY\bY
The l\blp\bpr\brm\bm command appeared in 3.0BSD.
4.2 Berkeley Distribution June 6, 1993 2