==== UNIX Print Commands ==== === Basic commands for printing === * You would use **lpr** or **lp** to print files; for example to print the file //myLetter.ps// on the print queue //recycled//: $ lpr -Precycled myLetter.ps $ lp -precycled myLetter.ps * To check the print queue to see if your document is waiting in the queue or if it's already printed you can use: $ lpq -P If there's document waiting to be printed in the queue you selected, you can see a list of all the print job waiting (the printers are slow, no matter how many pages they can print per minute). Every document is indicated by his name and his job number. this number is useful mainly for the next command. * If you want to delete a print job that is in the print queue: $ lprm -P job_number With this command you can delete only your documents. You can't delete document in queue that are owned by other users. Only the System Administrator can delete from the queue document of others users. * Maybe you want to know the status of the printer queues, before or after sending a print job. with lpstat you can know all the informtations about the funcionality of the printers queues. $ lpstat -t You can find more advanced use of the **lpr** command in the section [[printing:lpr:advanced|Advanced Printing Command]] == The default queue == Normally the default printer used by the system is the nearer to the workstation, but sometime you can desire a different behaviour. To change your default printer you use the lpoptions command. If you want change your default printer to //cloud// you can use: $ lpoptions -d cloud From now every time you print something without specifiing the printer it will be sent to //cloud// as default. **Beware that this configuration is written in your profile**, so if you login in another computer (at the other end of corridor) your default printer is always //cloud//.