You are not logged in.

#1 2015-12-25 10:08:54

poseidon
Member
Registered: 2012-06-07
Posts: 66

[SOLVED] CUPS on an Arch Linux Client: "Filter failed"

I've an archlinux computer run as server. Connected to it via USB is a HP LaserJet P2055d. I've added the printer using the CUPS web interface and everything is fine.

The troubles start, wehen I want to add that printer to an other archlinux machine (run as a client). Printing the test page I get a bare "Filter failed".

Server: The printer is shared and I even seem to have managed to install this DNSSD thing to publish the printer so that it is displayed under "Discovered Network Printers" on the client. cups-filters installed.

Client: I've added the printer as HP_LaserJet_P2055d and HP_LaserJet_P2055d_2.

1st variant: Connection:    ipp://sohoserverarchlinux.local:631/printers/HP_LaserJet_P2055d

2nd variant: dnssd://HP%20LaserJet%20P2055d%20%40%20sohoserverarchlinux._ipp._tcp.local/cups?uuid=...

I've appended ".local" to the server's host name, because the 2nd variant complained that it cannot find sohoserverarchlinux.local.

I'm stuck. What else do I have to do (on the server?) to be able to use the server's printer from Linux clients (and later from Windows clients and Apple hardware)?

Cheers Paul

Last edited by poseidon (2015-12-27 09:38:05)

Offline

#2 2015-12-25 18:46:59

pypi
Wiki Maintainer
Registered: 2014-04-22
Posts: 250

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

So what do the logs say (on the client and the server)? Can you print just from the server?

Offline

#3 2015-12-25 19:26:13

paulkerry
Member
From: Sheffield, UK
Registered: 2014-10-02
Posts: 611

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

You could also try another variant on your server which would start with "usb://" - some details are given on #9 at https://bbs.archlinux.org/viewtopic.php?id=199882

Edit /etc/cups/cupsd.conf on your server to grant access to your client(s) in the relevant section and check any firewall settings so connections work between the machines.

On your client, all you should need to do is edit/create /etc/cups/client.conf with the ip address or name of your server...

ServerName x.x.x.x

Then on your client...

lpstat -t

should show your printer and you should be able to print.

Cheers Paul.

Offline

#4 2015-12-26 07:05:37

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

pypi wrote:

So what do the logs say (on the client and the server)? Can you print just from the server?

The log on the client doesn't show anything excdept when I cancel the failed job.

The log on the server starts with a line marked by an "E", reading "Job stopped due to filter errors; please consilt the error_log file for details." The a bunch of "D"-lines follows most of them showing env vars. Some of the lines after those seem to be interesting, especially the one telling about the backend:

E [26/Dec/2015:07:52:46 +0100] [Job 32] Job stopped due to filter errors; please consult the error_log file for details.
D [26/Dec/2015:07:52:46 +0100] [Job 32] The following messages were recorded from 07:52:45 to 07:52:46
D [26/Dec/2015:07:52:46 +0100] [Job 32] Adding start banner page "none".
D [26/Dec/2015:07:52:46 +0100] [Job 32] Queued on "HP_LaserJet_P2055d" by "remroot".
D [26/Dec/2015:07:52:46 +0100] [Job 32] File of type application/vnd.cups-raster queued by "remroot".
D [26/Dec/2015:07:52:46 +0100] [Job 32] Adding end banner page "none".
D [26/Dec/2015:07:52:46 +0100] [Job 32] time-at-processing=1451112766
D [26/Dec/2015:07:52:46 +0100] [Job 32] 1 filters for job:
D [26/Dec/2015:07:52:46 +0100] [Job 32] hpcups (application/vnd.cups-raster to printer/HP_LaserJet_P2055d, cost 0)
D [26/Dec/2015:07:52:46 +0100] [Job 32] job-sheets=none,none
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[0]="HP_LaserJet_P2055d"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[1]="32"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[2]="remroot"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[3]="Test Page"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[4]="1"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[5]="job-uuid=urn:uuid:3daebb9c-e035-3b78-59a6-e8b4db59b05f job-originating-host-name=10.0.0.15 date-time-at-creation= date-time-at-processing= time-at-creation=1451112765 time-at-processing=1451112766"
D [26/Dec/2015:07:52:46 +0100] [Job 32] argv[6]="/var/spool/cups/d00032-001"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[0]="CUPS_CACHEDIR=/var/cache/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[1]="CUPS_DATADIR=/usr/share/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[2]="CUPS_DOCROOT=/usr/share/cups/doc"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[3]="CUPS_FONTPATH=/usr/share/cups/fonts"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[4]="CUPS_REQUESTROOT=/var/spool/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[5]="CUPS_SERVERBIN=/usr/lib/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[6]="CUPS_SERVERROOT=/etc/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[7]="CUPS_STATEDIR=/run/cups"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[8]="HOME=/var/spool/cups/tmp"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[9]="PATH=/usr/lib/cups/filter:/usr/bin:/usr/bin:/bin:/usr/bin"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[10]="SERVER_ADMIN=root@sohoserverarchlinux.local"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[11]="SOFTWARE=CUPS/2.1.2"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[12]="TMPDIR=/var/spool/cups/tmp"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[13]="USER=root"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[14]="CUPS_MAX_MESSAGE=2047"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[15]="CUPS_SERVER=/run/cups/cups.sock"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[16]="CUPS_ENCRYPTION=IfRequested"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[17]="IPP_PORT=631"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[18]="CHARSET=utf-8"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[19]="LANG=en_US.UTF-8"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[20]="PPD=/etc/cups/ppd/HP_LaserJet_P2055d.ppd"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[21]="RIP_MAX_CACHE=128m"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[22]="CONTENT_TYPE=application/vnd.cups-raster"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[23]="DEVICE_URI=hp:/usb/HP_LaserJet_P2055d?serial=S14144Z"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[24]="PRINTER_INFO=HP LaserJet P2055d"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[25]="PRINTER_LOCATION=SOHO"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[26]="PRINTER=HP_LaserJet_P2055d"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[27]="PRINTER_STATE_REASONS=none"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[28]="CUPS_FILETYPE=document"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[29]="FINAL_CONTENT_TYPE=printer/HP_LaserJet_P2055d"
D [26/Dec/2015:07:52:46 +0100] [Job 32] envp[30]="AUTH_I****"
D [26/Dec/2015:07:52:46 +0100] [Job 32] Started filter /usr/lib/cups/filter/gziptoany (PID 6163)
D [26/Dec/2015:07:52:46 +0100] [Job 32] Started filter /usr/lib/cups/filter/hpcups (PID 6164)
D [26/Dec/2015:07:52:46 +0100] [Job 32] Started backend /usr/lib/cups/backend/hp (PID 6165)
D [26/Dec/2015:07:52:46 +0100] [Job 32] prnt/hpcups/HPCupsFilter.cpp 565: cupsRasterOpen failed, fd = 0
D [26/Dec/2015:07:52:46 +0100] [Job 32] prnt/backend/hp.c 919: ERROR: null print job total=0
D [26/Dec/2015:07:52:46 +0100] [Job 32] PID 6164 (/usr/lib/cups/filter/hpcups) stopped with status 1.
D [26/Dec/2015:07:52:46 +0100] [Job 32] Hint: Try setting the LogLevel to "debug" to find out more.
D [26/Dec/2015:07:52:46 +0100] [Job 32] PID 6163 (/usr/lib/cups/filter/gziptoany) did not catch or ignore signal 13.
D [26/Dec/2015:07:52:46 +0100] [Job 32] PID 6165 (/usr/lib/cups/backend/hp) exited with no errors.
D [26/Dec/2015:07:52:46 +0100] [Job 32] End of messages
D [26/Dec/2015:07:52:46 +0100] [Job 32] printer-state=3(idle)
D [26/Dec/2015:07:52:46 +0100] [Job 32] printer-state-message="Filter failed"
D [26/Dec/2015:07:52:46 +0100] [Job 32] printer-state-reasons=none

Paul

Offline

#5 2015-12-26 07:17:46

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

paulkerry wrote:

You could also try another variant on your server which would start with "usb://" - some details are given on #9 at https://bbs.archlinux.org/viewtopic.php?id=199882

Edit /etc/cups/cupsd.conf on your server to grant access to your client(s) in the relevant section and check any firewall settings so connections work between the machines.

Quite a few sections contain "Allow all", which hopefully should do it. Not sure, though.

On your client, all you should need to do is edit/create /etc/cups/client.conf with the ip address or name of your server...

ServerName x.x.x.x

Then on your client...

lpstat -t

should show your printer and you should be able to print.

Ok, here's my /etc/cups/client.conf:

# see 'man client.conf'
#ServerName /run/cups/cups.sock #  alternative: ServerName hostname-or-ip-address[:port] of a remote server
ServerName sohoserverarchlinux.local

And lpstat -t yields after having restarted cups on the client:

scheduler is running                                                                                                                                                                                                                                                           
no system default destination                                                                                                                                                                                                                                                  
device for HP_LaserJet_P2055d: hp:/usb/HP_LaserJet_P2055d?serial=S14144Z                                                                                                                                                                                                       
HP_LaserJet_P2055d accepting requests since Sat 26 Dec 2015 07:52:46 CET                                                                                                                                                                                                       
printer HP_LaserJet_P2055d is idle.  enabled since Sat 26 Dec 2015 07:52:46 CET                                                                                                                                                                                                
        Filter failed

Paul

Offline

#6 2015-12-26 07:54:18

tom.ty89
Member
Registered: 2012-11-15
Posts: 897

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Do you have ghostscript installed? It might be needed for the "raster" backend.

Offline

#7 2015-12-26 09:02:13

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

tom.ty89 wrote:

Do you have ghostscript installed? It might be needed for the "raster" backend.

Yes:

extra/ghostscript 9.18-4 [installed]

Offline

#8 2015-12-26 09:25:41

paulkerry
Member
From: Sheffield, UK
Registered: 2014-10-02
Posts: 611

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Have you had a look through https://wiki.archlinux.org/index.php/CU … leshooting as there are a few items that might be pertinent?

Also just to check, have you configured your printer to use the hplip driver via the cups web interface?

Offline

#9 2015-12-26 09:49:10

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

paulkerry wrote:

Have you had a look through https://wiki.archlinux.org/index.php/CU … leshooting as there are a few items that might be pertinent?

Also just to check, have you configured your printer to use the hplip driver via the cups web interface?

How do I do that? The drivers offered by the web interface contain the string "hpijs" or "hpcups". I tried both and have activated the hpcups version for now, on both the server and the client.

I tried  a generic printer driver on another archlinux box working as a client (have 3 boxes on my desk now, 1 server, 2 clients, all arch). Again: "Filter failed".

Offline

#10 2015-12-26 10:31:47

paulkerry
Member
From: Sheffield, UK
Registered: 2014-10-02
Posts: 611

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Sorry for the confusion: hpcups is the one you should be using.

Why "on both the server and the client"? There is no need to set anything up on the client apart from /etc/cups/client.conf

As pypi said in #2, can you print OK from the server itself?

Last edited by paulkerry (2015-12-26 10:33:48)

Offline

#11 2015-12-26 12:33:24

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

paulkerry wrote:

Sorry for the confusion: hpcups is the one you should be using.

Why "on both the server and the client"? There is no need to set anything up on the client apart from /etc/cups/client.conf

My understanding for years has been that you need a full cups installation on both the server and the client. Always have done it this way to connect to remote printers be it ipp (at home) or smb (at work). How else would I be able to start the web interface at localhost:631 on a client to add a network printer? Had I started the cups web interface by pointing the client to sohoserverarchlinux.local:631 I would have been able to add a printer to the server, which I already did on the server  itself.

Hope I am not completely wrong here.


As pypi said in #2, can you print OK from the server itself?

Sorry, yes, have mentioned this in my 1st post: "Everything is fine" means "printer added on the server to the server w/o any problems and printing works as expected if I print the test page or an other page shown by the cups web interface (yes, I've for now installed a desktop env on my server)".

I'm afraid this looks so strange to some of you, that I have to clearify what I have done:

Box 2 and box 3 are working client machines w/ fully installed cups.

On box 1 I intalled archlinux, too, to replace a now defunct headless archlinux server (there the very same printer worked well). As I'm not an admin guy, I decided to install KDE full despite the fact, that it is a server. There, on box 1 (named sohoserverarchlinux.local), I pointed firefox to localhost:631 and added the printer being connected via USB. I guess, I could have done this by pointing firefox on a client (box 2 or 3) to sohoserverarchlinux.local:631. But as the server has a GUI...

On box 2 (client) I pointed firefox to localhost:631, to add a network printer to te client box 2, i.e. the one just added on the server (box 1).

Paul

Offline

#12 2015-12-26 18:09:45

pypi
Wiki Maintainer
Registered: 2014-04-22
Posts: 250

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

According to at least a CUPS dev, having a CUPS server on the client is the way to go.
See this answer on the ubuntu lists for the difference between hpcups and hpijs.
It seems that you have set up printing from a client correctly; can you print to a different printer on the server (ie a PDF output using cups-pdf?).

Also, this bug report seems relevant. You seem to say that you have added hp's drivers on the client; according to the bug report, they should only be on the server's print queue (to avoid processing the print job twice, once on the client and once on the server).

Offline

#13 2015-12-26 20:46:45

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

pypi wrote:

According to at least a CUPS dev, having a CUPS server on the client is the way to go.
See this answer on the ubuntu lists for the difference between hpcups and hpijs.
It seems that you have set up printing from a client correctly; can you print to a different printer on the server (ie a PDF output using cups-pdf?).


Tried it: Works, i.e. on the server I can view the test page printed from the client!


Also, this bug report seems relevant. .

The bug report looks similar, especially the backend error. I'll go thru it tomorrow, thank you.


You seem to say that you have added hp's drivers on the client; according to the bug report, they should only be on the server's print queue (to avoid processing the print job twice, once on the client and once on the server).

Yes, added the driver on the client side, too. I always have done this, because the web interface always has forced the user to do so: You enter the connection (ipp, smb, ...), then yo're asked for the printer's description, thean for the manufacturer and then for the driver.

Paul

Offline

#14 2015-12-26 22:11:15

paulkerry
Member
From: Sheffield, UK
Registered: 2014-10-02
Posts: 611

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

poseidon wrote:

My understanding for years has been that you need a full cups installation on both the server and the client. Always have done it this way to connect to remote printers be it ipp (at home) or smb (at work). How else would I be able to start the web interface at localhost:631 on a client to add a network printer? Had I started the cups web interface by pointing the client to sohoserverarchlinux.local:631 I would have been able to add a printer to the server, which I already did on the server  itself.

Hope I am not completely wrong here.

Not wrong no, but the way I've always done it which has worked for years (but is now starting to be deprecated) is just to add printers on the server and then setup /etc/cups/client.conf on every client and then all of the printers setup and added on the server are available to every client.

On each client, you just need libcups installed and don't need a local cups server running. This method is shown at https://wiki.archlinux.org/index.php/CU … UPS_server

Of course now having read pypi's link to the cups dev page, I'll have to migrate!

Last edited by paulkerry (2015-12-26 22:14:57)

Offline

#15 2015-12-27 08:46:08

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Probably of help: Connected my son's Windows box to the server (box 1, which the printer is connected to via USB): Entered http://sohoserverarchlinux.local:631/pr … Jet_P2055d. Had to use the driver for the P2015, because the P2055d is not offered (will go for the right driver today). Anyway, the result is: No CUPS errors, works like a charm!

Paul

Offline

#16 2015-12-27 09:37:46

poseidon
Member
Registered: 2012-06-07
Posts: 66

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

poseidon wrote:
pypi wrote:

Also, this bug report seems relevant. .

The bug report looks similar, especially the backend error. I'll go thru it tomorrow, thank you.

Yep, that seems to have done it: Had to define the printer queue as raw (which is possible even using the web interface).

Many thanks to all for your help these(!) days and especially to pypi for the link to the bug report @redhat!

Paul, being happy again ;-)

P.S.: Next construction site will be the upgrade to Plasma 5. Anyone done this already? Smooth? Well, I'll see...

Offline

#17 2015-12-27 18:47:27

pypi
Wiki Maintainer
Registered: 2014-04-22
Posts: 250

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Glad to have been able to help smile

Offline

#18 2015-12-29 16:53:25

zenlord
Member
From: Belgium
Registered: 2006-05-24
Posts: 1,221
Website

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

paulkerry wrote:
poseidon wrote:

My understanding for years has been that you need a full cups installation on both the server and the client. Always have done it this way to connect to remote printers be it ipp (at home) or smb (at work). How else would I be able to start the web interface at localhost:631 on a client to add a network printer? Had I started the cups web interface by pointing the client to sohoserverarchlinux.local:631 I would have been able to add a printer to the server, which I already did on the server  itself.

Hope I am not completely wrong here.

Not wrong no, but the way I've always done it which has worked for years (but is now starting to be deprecated) is just to add printers on the server and then setup /etc/cups/client.conf on every client and then all of the printers setup and added on the server are available to every client.

On each client, you just need libcups installed and don't need a local cups server running. This method is shown at https://wiki.archlinux.org/index.php/CU … UPS_server

Of course now having read pypi's link to the cups dev page, I'll have to migrate!

Hmmm... I have ran for approx. 9 years in three offices using the 'endorsed by the devs'-method, and this has proven very inefficient to me. Most of that timespan I believed (as did Paul Kerry) that every client needed its own full installation of cupsd. Last July I made the switch to the server/client-model and administration has been a breeze eversince. If something goes awry, you only have one location to troubleshoot and it is very easy to allow the users to restart the cups-server in a worst case scenario. Before the switch, several users had to restart their own instance of cupsd multiple times per day...

Deprecated or not: I will stick to server/client as long as possible - this is of course just my 0.02€...

Enjoy!

Offline

#19 2015-12-29 19:46:04

paulkerry
Member
From: Sheffield, UK
Registered: 2014-10-02
Posts: 611

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

zenlord wrote:

Hmmm... I have ran for approx. 9 years in three offices using the 'endorsed by the devs'-method, and this has proven very inefficient to me. Most of that timespan I believed (as did Paul Kerry) that every client needed its own full installation of cupsd.

I think you mean poseidon and not me zenlord! I have run cupsd for several years on a single server and just used /etc/cups/client.conf on every client without cupsd running on each client and everything has worked perfectly for tens of thousands of printer jobs.

I also hope that this deprecation does not go away...

Offline

#20 2018-09-28 20:02:48

diguliu
Member
Registered: 2018-09-28
Posts: 1

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

I had the same problem here and was able to solve it with solution proposed with some extra steps. I'll leave it here in case someone stumbles on the same issue.

After seeing the problem with doubling the driver on the server and the client I tried to follow the solution and selected the "Raw" option on the Device field on my clients. But the "Filter Failed" continued. I noticed that ven though I was choosing Raw on the setup when the printer was saved it displayed the driver defined on the server instead of "Raw". After many arbitrary tests I was able to solve the issue just by using http protocol instead of ipp. When I configured the clients with http the "Raw" configuration was set properly and everything worked fine. I don't really know much about cups but it seems that the cups server using ipp was providing the driver configuration to the cups client which was overriding the "Raw" device with that information causing the "Filter Failed" issue again.

PS: My setup uses Debian Stretch on both client and servers.
PS2: I'd love to just use the dnssd protocol instead of configuring manually with ipp/http but I couldn't make it work either.

Last edited by diguliu (2018-09-28 20:06:33)

Offline

#21 2018-09-28 20:47:29

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED] CUPS on an Arch Linux Client: "Filter failed"

Please don't necrobump, especially solved threads: https://wiki.archlinux.org/index.php/Co … bumping.22


Closing


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

Board footer

Powered by FluxBB