LPC(8) | MidnightBSD System Manager's Manual | LPC(8) |
lpc
— line printer
control program
lpc |
[command [argument ...]] |
The lpc
utility is used by the system
administrator to control the operation of the line printer system. For each
line printer configured in /etc/printcap,
lpc
may be used to:
Without any arguments, lpc
will prompt for
commands from the standard input. If arguments are supplied,
lpc
interprets the first argument as a command and
the remaining arguments as parameters to the command. The standard input may
be redirected causing lpc
to read commands from
file. Commands may be abbreviated; the following is the list of recognized
commands.
?
[command ...]help
[command ...]abort
{all
| printer}bottomq
printer [jobspec ...]clean
{all
| printer}tclean
command.
disable
{all
| printer}down
{all
| printer ...}
-msg
message ...down
{all
| printer}
message ...-msg
argument is
required to separate the list of printers from the text that will be the
new status message. The message does not need to be quoted, the remaining
arguments are treated like
echo(1). This is normally
used to take a printer down, and let other users find out why it is down
(the lpq(1) utility will
indicate that the printer is down and will print the status message).
enable
{all
| printer}exit
quit
lpc
.
restart
{all
| printer}setstatus
{all
| printer}
-msg
message ...-msg
argument is required to separate the list of
printers from the text that will be the new status message. This is
normally used to change the status message when the printer queue is no
longer active after printing has been disabled, and you want to change
what users will see in the output of the
lpq(1) utility.
start
{all
| printer}status
{all
| printer}stop
{all
| printer}tclean
{all
| printer}clean
command. All
the same checking is done, but the command will only print out messages
saying what a similar clean
command would do if
the user typed it in. It will not remove any files. Note that the
clean
command is a privileged command, while the
tclean
command is not restricted.
topq
printer [jobspec ...]up
{all
| printer}down
.Commands such as topq
and
bottomq
can take one or more
jobspec to specify which jobs the command should
operate on. A jobspec can be:
The values for userid and host name can also include
pattern-matching characters, similar to the pattern matching done for
filenames in most command shells. Note that if you enter a
topq
or bottomq
command as
parameters on the initial lpc
command, then the
shell will expand any pattern-matching characters that it can (based on what
files in finds in the current directory) before lpc
processes the command. In that case, any parameters which include
pattern-matching characters should be enclosed in quotes, so that the shell
will not try to expand them.
lpq(1), lpr(1), lprm(1), printcap(5), chkprintcap(8), lpd(8)
The lpc
utility appeared in
4.2BSD.
July 16, 2002 | midnightbsd-3.1 |