Blog Fiasco

April 7, 2010

Solving the CUPS “hpcups failed” error

Filed under: Linux — Tags: , , , , , , — bcotton @ 7:03 am

I thought when I took my new job that my days of dealing with printer headaches were over.  Alas, it was not to be.  A few weeks ago, I needed to print out a form for work.  I tried to print to the shared laser printer down the hall.  Nothing.  So I tried the color printer. Nothing again.  I was perplexed because both printers had worked previously, so being a moderately competent sysadmin, I looked in the CUPS logs.  I saw a line in error_log that read printer-state-message="/usr/lib/cups/filter/hpcups failed". That seemed like it was the problem, so I tried to find a solution and couldn’t come up with anything immediately.

Since a quick fix didn’t seem to be on the horizon, I decided that I had better things to do with my time and I just used my laptop to print.  That worked, so I forgot about the printing issue.  Shortly thereafter, the group that maintains the printers added the ones on our floor to their CUPS server.  I stopped CUPS on my desktop and switched to their server and printing worked again, thus I had even less incentive to track down the problem.

Fast forward to yesterday afternoon when my wife tried to print a handbill for an event she is organizing in a few weeks.  Since my desktop at home is a x86_64 Fedora 12 system, too, it didn’t surprise me too much when she told me she couldn’t print.  Sure, enough, when I checked the logs, I saw the same error.  I tried all of the regular stalling tactics: restarting CUPS, power cycling the printer, just removing the job and trying again.  Nothing worked.

The first site I found was an Ubuntu bug report which seemed to suggest maybe I should update the printer’s firmware.  That seemed like a really unappealing prospect to me, but as I scrolled down I saw comment #8.  This suggested that maybe I was looking in the wrong place for my answer.  A few lines above the hpcups line, there was an error message that read prnt/hpcups/HPCupsFilter.cpp 361: DEBUG: Bad PPD - hpPrinterLanguage not found.

A search for this brought me to a page about the latest version of hplip. Apparently, the new version required updated PPD files, which are the files that describe the printer to the print server.  In this case, updating the PPD file was simple, and didn’t involve having to find it on HP’s or a third-party website.  All I had to do was use the CUPS web interface and modify the printer, keeping everything the same except selecting the hpcups 3.10.2 driver instead of the 3.9.x that it had been using.  As soon as I made that change, printing worked exactly as expected.

The lesson here, besides the ever-present “printing is evil” is that the error message you think is the clue might not always be.  When you get stuck trying to figure a problem out, look around for other clues.  Tunnel vision only works if you’re on the right track to begin with.


  1. […] This post was mentioned on Twitter by Ben Cotton. Ben Cotton said: New blog post: Solving the CUPS "hpcups failed" error — […]

    Pingback by Tweets that mention Solving the CUPS “hpcups failed” error « Blog Fiasco -- — April 7, 2010 @ 7:28 am

  2. Fedora users can download the fix here: (scroll down)

    Comment by anon — April 7, 2010 @ 3:09 pm

  3. Thank you very much man!
    I’ve got such an issue after upgrading my opensuse from 11.2 to 11.3
    When i changed hpcups driver to 3.10 everything went fine

    Comment by daniel — July 22, 2010 @ 2:44 am

  4. Same here after upgrading from opensuse 11.2 to 11.3 and your solution fixed the problem! Thanks man!

    Comment by Christian — August 16, 2010 @ 10:31 pm

  5. Thanks a lot! That post saved me a lot of time. Works the same way when moving from hplip 3.10 to 3.11 :)

    Comment by Felix — June 20, 2011 @ 4:22 am

  6. i have purchsed hp laser jet 1020 plus os is fedora 14.while i test print the massage is /usr/lib/cups/filters/hpcups fails. no printing and the next massage “printer ready to print” what should i do.

    Comment by chandrakant — November 6, 2011 @ 7:09 am

  7. Thanks a lot 4 years passed and your tips still work.
    Regards from Portugal

    Still Linux Rulez!!! :D

    Comment by Ricardo Marques — February 26, 2014 @ 9:48 am

RSS feed for comments on this post. TrackBack URL

Leave a comment

Powered by WordPress