Display print queue status (UNIX)
lpq [-l] [-P name] [-q] [-s seconds] [jobnumber...] [user...]
If a server is not specified, the utility will use the spooler identified in the LPSRVR environment variable, or /qnx/spooler if LPSRVR is not set.
If a queue is not specified, lp will use the queue identified in the LPDEST environment variable, or the first queue defined in the setup file of the spooler being used if LPDEST is not set.
For more detailed discussion, see Ch.9, "Print Spooling," in the QNX Installation & Configuration manual.
The lpq utility reports on the status of jobs in a printer queue.
For each job, lpq reports the user's name, the job identifier, the ranking in the queue, and the names of files that make up the job.
If no filename is available, the file name will be displayed as "standard input".
When lpq is set for "looping," it will continue to redisplay the entries until no entries are left to display.
Display all current print jobs submitted by steve:
lpq steve
Since lpq is based on polling, it's possible that very fast jobs will completely escape its notice.