Sometimes you want to cancel a job that has already been submitted. You need to look at the print queue, select a job, and then remove it.
The command lpq shows the default print queue — for example:
[email protected]:~> lpq laserjet4l is ready no entries
This means there's nothing left in the print queue. However, if there are jobs in the queue, you will see something like this:
Rank Owner Job File(s) Total Size
Laserjet4l is ready and printing
Active roger 118 (stdin) 2725888 bytes active roger 119 bible.pdf 1354558 bytes like this:
The command lpq shows the default print queue. If there is more than one queue and you want to display another queue, you need to use the option -P to specify it, like this:
lpq -P laserjet4l
If there is more than one printer available, you can set the default printer in YaST in the main screen that displays all configured printers. Select the Other button and choose ''Set as default.''
You could now type cancel 119 or lprm 119 to remove the second of these jobs from the queue. Of course, you must be the owner of the job to do this. You may often find that you're too late — the job has gone to the printer and is in the printer's memory. Whether you can easily cancel the job at that stage depends on the printer.
Was this article helpful?