LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 01-28-2011, 08:52 AM   #1
ToK
Member
 
Registered: Nov 2005
Posts: 107

Rep: Reputation: 17
printing with hplip doesn't work: /usr/lib/cups/backend/hp failed


Hi everyone,

I have a strange problem. I have an old HP Laserjet 5L which is connected to the parallel port of my computer. I could hp-setup to configure the printer. It is connected to
hp:/par/HP_Laserjet_5L?device=/dev/parport0

Everytime a want to print the printer is stopped with the error message
/usr/lib/cups/backend/hp failed
(tried to print as root and as a normal user doesn't work)

If I try to print directly to the device works with
echo "test" > /dev/lp0

but it does not work with
echo "test" > /dev/parport0

the permissions are set to
crw-rw---- 1 root scanner 6, 0 28. Jan 14:54 /dev/lp0
crw-rw---- 1 root scanner 99, 0 28. Jan 14:54 /dev/parport0

My Distribution is archlinux with all updates installed

Does anybody know how to fix this?

ToK
 
Old 01-28-2011, 10:59 PM   #2
Peacedog
Guru
 
Registered: Sep 2003
Location: Danville, VA
Distribution: Slackware, Windows, FreeBSD, OpenBSD, Mac OS X
Posts: 5,292

Rep: Reputation: 167Reputation: 167
Hi ToK, Are you in the lp group? What does cupsd.conf look like? Which ppd are you using?

Good luck. ;-)
 
Old 01-29-2011, 12:09 PM   #3
ToK
Member
 
Registered: Nov 2005
Posts: 107

Original Poster
Rep: Reputation: 17
Hi Peacedoc,

I am just re-installing linux, please wait. As far as I remember I was a member of the group lp...
I will report as far as I re-installed linux.

ToK
 
Old 01-29-2011, 02:06 PM   #4
Peacedog
Guru
 
Registered: Sep 2003
Location: Danville, VA
Distribution: Slackware, Windows, FreeBSD, OpenBSD, Mac OS X
Posts: 5,292

Rep: Reputation: 167Reputation: 167
We'll all be here.

Good luck. ;-)
 
Old 01-30-2011, 06:29 AM   #5
ToK
Member
 
Registered: Nov 2005
Posts: 107

Original Poster
Rep: Reputation: 17
Thanks,

it works. Don't know why. If I should guess the modules parport and parport_pc are not loaded. But I cannot say for sure. I followed the Instruction on https://wiki.archlinux.org/index.php/CUPS and it works...

Thanks anyway...

Tok
 
Old 01-30-2011, 08:25 AM   #6
Peacedog
Guru
 
Registered: Sep 2003
Location: Danville, VA
Distribution: Slackware, Windows, FreeBSD, OpenBSD, Mac OS X
Posts: 5,292

Rep: Reputation: 167Reputation: 167
Glad you got it sorted!

Good luck. ;-)
 
Old 01-31-2011, 08:02 AM   #7
ToK
Member
 
Registered: Nov 2005
Posts: 107

Original Poster
Rep: Reputation: 17
Hi,

now it's getting crazy.
As I setup my machine (archlinux), i could print. As i continue to setup other applications, i cannot print any further... i've got the message /usr/lib/cups/backend/hp failed...

So let's start debugging:
First of all: this is my /etc/cups/cups.conf
Code:
#
# "$Id: cupsd.conf.in 9310 2010-09-21 22:34:57Z mike $"
#
# Sample configuration file for the CUPS scheduler.  See "man cupsd.conf" for a
# complete description of this file.
#

# Log general information in error_log - change "warn" to "debug"
# for troubleshooting...
LogLevel warn

# Administrator user group...
SystemGroup sys root


# Only listen for connections from the local machine.
Listen localhost:631
Listen /var/run/cups/cups.sock

# Show shared printers on the local network.
Browsing On
BrowseOrder allow,deny
BrowseAllow all
BrowseLocalProtocols CUPS dnssd

# Default authentication type, when authentication is required...
DefaultAuthType Basic

# Restrict access to the server...
<Location />
  Order allow,deny
</Location>

# Restrict access to the admin pages...
<Location /admin>
  Order allow,deny
</Location>

# Restrict access to configuration files...
<Location /admin/conf>
  AuthType Default
  Require user @SYSTEM
  Order allow,deny
</Location>

# Set the default printer/job policies...
<Policy default>
  # Job-related operations must be done by the owner or an administrator...
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    Order deny,allow
  </Limit>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job CUPS-Move-Job CUPS-Get-Document>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  # All administration operations require an administrator to authenticate...
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # All printer operations require a printer operator to authenticate...
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # Only the owner or an administrator can cancel or authenticate a job...
  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Order deny,allow
  </Limit>
</Policy>

# Set the authenticated printer/job policies...
<Policy authenticated>
  # Job-related operations must be done by the owner or an administrator...
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    AuthType Default
    Order deny,allow
  </Limit>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job CUPS-Move-Job CUPS-Get-Document>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  # All administration operations require an administrator to authenticate...
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # All printer operations require a printer operator to authenticate...
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # Only the owner or an administrator can cancel or authenticate a job...
  <Limit Cancel-Job CUPS-Authenticate-Job>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Order deny,allow
  </Limit>
</Policy>

#
# End of "$Id: cupsd.conf.in 9310 2010-09-21 22:34:57Z mike $".
#
Second of all: my ppd is "HP LaserJet 5L Foomatic/ljet4 (recommended)" - and now it's getting very crazy: the cups web page shows "(grayscale, 2-sided printing)". I never switched to "2-sided printing". Does this mean i should use duplex???
If I switch to "HP LaserJet 5L Foomatic/gutenprint-ijs.5.2" I could set "Double-Sided Printing" (which it was before), and I still got the message "(grayscale, 2-sided printing)"...
I should mention: I have another printer (with duplex) which works fine...

Third of all: As I switch the LogLevel to debug an start my printer (with a testpage job in the cue) I got the following message (see attachment). There is an error "ERROR: open device failed stat=12"
I googled around and found the page https://bbs.archlinux.org/viewtopic.php?id=85454
-> I changed the SystemGroup to lp an resumed and got the same error message
-> Installing and running avahi-daemon does'nt solve the problem...


PLEEEEEAAAASE Help!

ToK
Attached Files
File Type: log error.log (104.5 KB, 1 views)
 
Old 01-31-2011, 11:28 AM   #8
Peacedog
Guru
 
Registered: Sep 2003
Location: Danville, VA
Distribution: Slackware, Windows, FreeBSD, OpenBSD, Mac OS X
Posts: 5,292

Rep: Reputation: 167Reputation: 167
Just looking into driver issues I've found this:

Quote:
For basic printing functionality use the "ljet4" or the HPIJS driver . For advanced functionality such as printer status and maintenance features, use the HPLIP driver (which includes HPIJS but works also together with "ljet4").

Remember that the 5L is more like the LaserJet 4 family than the LaserJet 5 family (as with most "L" printers from HP). For example it does not work with the "lj5gray" drivers but only with the "ljet4" or "lj4dith" drivers (and Gimp-Print or HPIJS).
Taken from: http://www.openprinting.org/printer/HP/HP-LaserJet_5L

Also are you in the "lp" group?

Good luck. ;-)
 
Old 02-01-2011, 01:00 AM   #9
ToK
Member
 
Registered: Nov 2005
Posts: 107

Original Poster
Rep: Reputation: 17
I've tried hplip and ljet4 (or lj4dith)

Yes I am a member of the group lp.

Did I already mention that I can't see the parport on the cups website when I want to configure a printer? There is only SCSI, Serial (1 and 2), HP Printer and HP Fax...

ToK
 
Old 02-02-2011, 01:49 PM   #10
ToK
Member
 
Registered: Nov 2005
Posts: 107

Original Poster
Rep: Reputation: 17
Hi,

I've got the reason: The group on the device file /dev/lp0 is set to scanner, not to lp. Everything works find if I set the the group to lp.
The group is set to scanner because I wrote a udev rule to set the permisson of my usb scanner. I don't know why it affects my parport. Since I removed the udev of my scanner the group of lp0 is set to lp and I could print again Funnily enough: the permisson of the usb port is not set to scanner (which it was not previous...)

So everything is fine now. Thanks for your help

ToK
 
Old 02-02-2011, 04:45 PM   #11
Peacedog
Guru
 
Registered: Sep 2003
Location: Danville, VA
Distribution: Slackware, Windows, FreeBSD, OpenBSD, Mac OS X
Posts: 5,292

Rep: Reputation: 167Reputation: 167
You're welcome. Glad you got it sorted!

Good luck. ;-)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
"/usr/lib/cups/filter/foomatic-rip failed" newbiesforever Linux - Hardware 1 12-10-2010 09:37 AM
Freelink debian on Buffalo NAS cups not working /usr/lib/cups/filter/hpcups failed linuxmandrake Debian 0 03-23-2010 04:45 PM
[SOLVED] cups "/usr/lib/cups/filter/foomatic-rip failed" error wufo Slackware 4 01-31-2010 02:20 PM
/usr/lib/cups/filter/ppmtospl2 failed dwpbike Red Hat 3 04-17-2007 10:02 AM
hplip backend for sane and CUPS unable to detect OfficeJet T65 on parallel port kris_kiil Linux - Hardware 2 04-23-2006 12:34 PM


All times are GMT -5. The time now is 01:40 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration