CUPS Configuration: Difference between revisions

From Elvanör's Technical Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
Line 28: Line 28:


* By adding -o to the lpr command, you can specify options. This is not very convenient though as you need to know the names of the options you want to set... [http://printing.kde.org/faq/cups.php#HowdoIgetanicelyformattedlistingofavailableoptionsforagivenprinterorPPD This KDE link] may help you.
* By adding -o to the lpr command, you can specify options. This is not very convenient though as you need to know the names of the options you want to set... [http://printing.kde.org/faq/cups.php#HowdoIgetanicelyformattedlistingofavailableoptionsforagivenprinterorPPD This KDE link] may help you.
= Canon Printers =
* You can print on some Canon printers by installing the Gutenprint package in addition to CUPS. For instance, my Canon Pixma TS-5040 printer seems to be relatively well supported by Gutenprint.

Latest revision as of 14:03, 27 May 2020

CUPS (Common UNIX Printing System) is the standard Linux printing subsystem. It is relatively advanced and generally quite easy to configure.

Basics

  • Once you install cups in Gentoo (and start the daemon cupsd), the web interface is accessible at http://localhost:631/.
  • From the interface, you can add printers. The most important thing to understand is how your computer is connected to the printer, and which protocols the printer supports (CUPS support all but the most exotic protocols so this should not be a problem).
  • The most common protocols are IPP, lpd/lpr and direct access on port 9100. CUPS recommends IPP if it is available, however I have not yet fully understood what's the address of an IPP printer. So try lpr:/ or socket:/ protocols if IPP does not work.

PPD file

  • The PPD file is *extremely* important to get your printer correctly working. If you don't supply it the right PPD file, features such as Duplex Printing (two-sided printing) may not work at all. Other features like color choice (BW or color), number of copies etc won't be available.
  • Be sure you downloaded the correct PPD file for your printer (this file is quite platform independant, so you can use the Windows file if the manufacturer is stupid enough not to provide a Linux one). Then move it to /usr/share/cups/model and restart CUPS. You can then normally choose it when configuring your printer.
  • The PPD file will be used by the configuration web application. Just choose Printer Settings in CUPS and you should get a list of all the options your printer supports. Configure important ones such as Duplex Printing, etc.
  • Duplex printing should be "Top-Top".

Options

  • Note that all printer options (that can be visualized via lpoptions or the cups web interface) are actually saved to the PPD file. So (at least on Gentoo) CUPS maintains a list of PPD files in /etc/cups/ppd. They are associated to a printer via the name of the file.
  • The "base" PPD files are /usr/share/cups/model/ but these just contain defaults. Once the printer is defined in CUPS, the chosen PPD file is copied over to /etc/cups/ppd and then all modifications are done to that file.

Command Line Options

  • By adding -o to the lpr command, you can specify options. This is not very convenient though as you need to know the names of the options you want to set... This KDE link may help you.

Canon Printers

  • You can print on some Canon printers by installing the Gutenprint package in addition to CUPS. For instance, my Canon Pixma TS-5040 printer seems to be relatively well supported by Gutenprint.