I'm looking for a way to print to a networked HP LaserJet 600 M602 in Debian Jessie and I can't seem to find a solution that does not pull in avahi as a dependency. I don't want avahi because it interferes with my networking setup.

Cups, gutenprint, foomatic, and hplip all pull in avahi. How can I get printing setup for a networked "HP LaserJet 600 M602" without avahi?

A generic printer driver that does not have all the features of my printer is acceptable. So would be a solution that only prints PDFs.


I found a minimal solution. If spooling is not needed and you have a ppd printer the following works:

ncat [ip_of_printer] 9100 < file_to_print.pdf

9100 is a port used by the HP jetdirect protocol for sending raw data to a printer. And, the printer I'm using is a PPD printer so it natively understands postscript (I don't know enough about PDF/ps to be sure, but I wouldn't be surprised if this didn't work for all PDF files, in which case I'd try doing pdf2ps first).

Though not needed (AFAICT) the PPD file for this printer can be found in the Debian source package of "hplip". I'm still looking into if that could be useful. But for now, being a minimalist, I'm happy with using ncat.


  • How is the printer networked? If it has a static IP address, print jobs can be thrown at any of a number of ports HP printers tend to listen at by CUPS, and you can specify the PPD to use in CUPS without needing avahi.
    – thrig
    Commented Aug 24, 2015 at 23:10
  • It has a static IP. I'm not that familiar with printing--would I need a PPD file for my printer or a generic HP one (or an even more generic one)? Considering that printing only pdfs is acceptable, does that mean I can just use the PPD "interface" or driver... I'm still not 100% sure what a PPD is. Commented Aug 24, 2015 at 23:19
  • I looked here for a ppd file: openprinting.org/download/PPD/HP My printer is not listed and I don't see anything that looks generic. Commented Aug 24, 2015 at 23:26
  • 2
    Hmm, actually, it's a package problem, as you'll need to compile CUPS without the avahi dep to not pull that in. Another option might be LPRng packages.debian.org/jessie/lprng but it's been a um well over a decade since I last used that. The PPD gets you the features of your printer, and is usually shipped in driver bundles from HP.
    – thrig
    Commented Aug 24, 2015 at 23:28
  • Yeah, I'm looking at using lpr/lprng and docs for "spooler-less" printing here: wiki.linuxfoundation.org/en/OpenPrinting/Database/… Commented Aug 24, 2015 at 23:30

1 Answer 1


The CUPS package only recommends the Avahi daemon, so you don't have to install (and run) it, even though it's selected for installation by default, just like strict dependencies. You can simply deselect it. The client libraries will still get installed (being strict dependencies), but those should have no effect on your system.

  • apt-get install --no-install-recommends cups hplip did the trick. Commented Aug 26, 2015 at 19:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .