[Go to CFHT Home Page] Man Pages
Back to Software Index  BORDER=0Manpage Top Level
    lpstat(1) manual page Table of Contents

Name

lpstat - print information about the status of the LP print service

Synopsis

lpstat [ -d ] [ -r ] [ -R ] [ -s ] [ -t ] [ -a [list] ] [ -c [list] ] [ -f [list] [ -l ] ] [ -o [list] ] [ -p [list] [ -D ] [ -l ] ] [ -P ] [ -S [list] [ -l ] ] [ -u [login-ID-list] ] [ -v [list] ]

Availability

SUNWlpu

Description

The lpstat command prints information about the current status of the LP print service.

If no options are given, then lpstat prints the status of all the user’s print requests made by lp (see lp(1) ). Any arguments that are not options are assumed to be request-IDs as returned by lp. The lpstat command prints the status of such requests. The options may appear in any order and may be repeated and intermixed with other arguments. Some of the keyletters below may be followed by an optional list that can be in one of two forms: a list of items separated from one another by a comma, or a list of items separated from one another by spaces enclosed in quotes. For example:

example% lpstat -u "user1 user2 user3"

Specifying all after any keyletter that takes list as an argument causes all information relevant to the keyletter to be printed. For example, the command:

example% lpstat -o all

prints the status of all output requests.

The omission of a list following such key letters causes all information relevant to the key letter to be printed. For example, the command:

example% lpstat -o

prints the status of all output requests.

Options

The following options are supported:
-a [list]
Reports whether print destinations are accepting requests. list is a list of intermixed printer names and class names.
-c [list]
Print name of all classes and their members. list is a list of class names.
-d
Print the system default destination for output requests.
-f [list] [-l]
Print a verification that the forms in list are recognized by the LP print service. list is a list of forms; the default is all. The -l option will list the form descriptions.
-o [list]
Print the status of output requests: list is a list of intermixed printer names, class names, and request-IDs. The keyletter -o may be omitted.
-p [list] [-D] [-l]
Print the status of printers. list is a list of printer names. If the -D option is given, a brief description is printed for each printer in list. If the -l option is given, and the printer is on the local machine, a full description of each printer’s configuration is given, including the form mounted, the acceptable content and printer types, a printer description, the interface used, and so on.
-P
Print the paper types.
-r
Print the status of the LP request scheduler.
-R
Print a number showing the position of each job in the print queue.
-s
Print a status summary, including the status of the LP scheduler, the system default destination, a list of class names and their members, a list of printers and their associated devices, a list of the machines sharing print services, a list of all forms currently mounted, and a list of all recognized character sets and print wheels.
-S [list] [-l]
Print a verification that the character sets or the print wheels specified in list are recognized by the LP print service. Items in list can be character sets or print wheels; the default for the list is all. If the -l option is given, each line is appended by a list of printers that can handle the print wheel or character set. The list also shows whether the print wheel or character set is mounted, or specifies the built-in character set into which it maps.
-t
Print all status information. This includes all the information obtained with the -s option, plus the acceptance and idle/busy status of all printers.
-u [login-ID-list]
Print the status of output requests for users. The login-ID -list argument may include any or all of the following constructs:

login-ID
a user on any system
system_name!login-ID
a user on system system_name
system_name!all
all users on system system_name
all!login-ID
a user on all systems
all
all users on all systems
-v [list]
Print the names of printers and the path names of the devices associated with them or remote system names for network printers: list is a list of printer names.

Environment

See environ(5) for descriptions of the following environment variables that affect the execution of lpstat: LC_CTYPE , LC_MESSAGES , LC_TIME , and NLSPATH .

Exit Status

The following exit values are returned:
  1. Successful completion.
    >0
    An error occurred.

    Files

    /etc/lp/*
    printer configuration files
    /var/spool/lp/*
    print queue

    See Also

    enable(1) , lp(1) , environ(5)


    Table of Contents