The Single UNIX ® Specification, Version 2
Copyright © 1997 The Open Group

 NAME

cancel - cancel printer requests (LEGACY)

 SYNOPSIS



cancel [ID ...] printer ... 

cancel ID ...[printer ...] 

 DESCRIPTION

The cancel utility cancels printer requests that were made by an lp command. The cancellation of a request that is currently printing frees the printer to print its next available request.

Cancelling requests from other users requires appropriate privileges. For each request successfully cancelled by a user who did not submit the request, the submitter may be notified that the request was cancelled.

The cancel utility cannot reliably cancel print requests in all conceivable circumstances. When the printer is under the control of another operating system or resides on a remote system across a network, it might not be possible to affect the status of the print job after it has left the control of the local operating system. Even on local printers, spooling hardware in the printer may make it appear that the print job has been completed long before the final page is printed.

 OPTIONS

None.

 OPERANDS

The following operands are supported:
ID
A request ID, as returned by lp. Specifying a request ID cancels the associated request even if it is currently printing.
printer
A printer name (for a complete list of printer names, use lpstat). Specifying a printer cancels the request that is currently printing on that printer.

 STDIN

Not used.

 INPUT FILES

None.

 ENVIRONMENT VARIABLES

The following environment variables affect the execution of cancel:
LANG
Provide a default value for the internationalisation variables that are unset or null. If LANG is unset or null, the corresponding value from the implementation-dependent default locale will be used. If any of the internationalisation variables contains an invalid setting, the utility will behave as if none of the variables had been defined.
LC_ALL
If set to a non-empty string value, override the values of all the other internationalisation variables.
LC_CTYPE
Determine the locale for the interpretation of sequences of bytes of text data as characters (for example, single- as opposed to multi-byte characters in arguments).
LC_MESSAGES
Determine the locale that should be used to affect the format and contents of diagnostic messages written to standard error, and informative messages written to standard output.
NLSPATH
Determine the location of message catalogues for the processing of LC_MESSAGES .

 ASYNCHRONOUS EVENTS

Default.

 STDOUT

The standard output is a text file containing the status of each cancellation request, in an unspecified format.

 STDERR

Used only for diagnostic messages.

 OUTPUT FILES

If mail notification is used to inform users of their requests being cancelled by other users, mail files will be modified.

 EXTENDED DESCRIPTION

None.

 EXIT STATUS

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

 CONSEQUENCES OF ERRORS

Default.

 APPLICATION USAGE

None.

 EXAMPLES

None.

 FUTURE DIRECTIONS

None.

 SEE ALSO

lp, lpstat, mailx.

UNIX ® is a registered Trademark of The Open Group.
Copyright © 1997 The Open Group
[ Main Index | XSH | XCU | XBD | XCURSES | XNS ]