LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices



Reply
 
Search this Thread
Old 03-07-2010, 10:53 AM   #1
disturbed1
Senior Member
 
Registered: Mar 2005
Location: USA
Distribution: Slackware
Posts: 1,133
Blog Entries: 6

Rep: Reputation: 223Reputation: 223Reputation: 223
Cups 1.4.2 and common problems


Since 1.4.x Cups no longer prefers usblp, and is built with libusb as the only backend. If your printer is not found by cups, you can try to remove usblp, and restart cups.

Code:
rmmod usblp
/etc/rc.d/rc.cups restart
Make this perminant either by rebuilding your kernel, or adding usblp to /etc/modprobe.d/blacklist
This worked for our Epson IJP printers.

If your printer is not supported by libusb, you can rebuild cups to use usblp instead of libusb. Add --disable-libusb to the SlackBuild and rebuild cups.
There is a patch on the cups bug list to enable both backends, but does not apply cleanly on 1.4.2. Debian has a mega patch, which includes a patch to enable both backends.

For HP printers (which I do not own). There have been threads here about new cups and hplip. Hplip has had some changes to the configure script as well.
Code:
--enable-pp-build    enable parallel port build (default=no)
--enable-new-hpcups Has nothing to do with cups 1.4.x This is only for internal HP testing.

The --enable-pp-build was changed from default=yes to default=no in version 3.9.6
 
Old 03-07-2010, 11:38 AM   #2
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Thanks, this is very useful information.
One question, though: How do I know, if my printer is supported by libusb?

EDIT: or if my problems are caused by something else...

gargamel
 
Old 03-07-2010, 12:03 PM   #3
Zielony
LQ Newbie
 
Registered: Mar 2010
Posts: 17

Rep: Reputation: 1
Who knows the real solution for this:
Code:
Mar  7 17:57:31 zielony hp[1289]: io/hpmud/musb.c 1026: bulk_write failed buf=0xbfa03424 size=50 len=-5: Success
Mar  7 17:57:31 zielony hp[1289]: io/hpmud/musb.c 1393: unable to write data hp:/usb/DeskJet_840C?serial=CN0CE1B288KV: Success
Mar  7 17:57:31 zielony kernel: usb 2-1.8: BOGUS urb flags, 1 --> 0
?

It's HP printer connected via USB.

What hplip options could help?
 
Old 03-07-2010, 12:23 PM   #4
disturbed1
Senior Member
 
Registered: Mar 2005
Location: USA
Distribution: Slackware
Posts: 1,133
Blog Entries: 6

Original Poster
Rep: Reputation: 223Reputation: 223Reputation: 223
I looked for a list, but all I found were bug reports against cups and usblp.

HP has this to say http://hplipopensource.com/node/128
Quote:
With HPLIP 0.9.9 all USB I/O takes place with libusb. Libusb allows USB drivers to be written in user mode instead of kernel mode. Kernel modules "printer" and "usblp" are no longer required. Libusb allows unique low level control that was not available in the kernel modules. Without libusb full I/O support is not available for many HP devices.
The way I handled it, was test if cups 1.4.2 without usblp works, and so far it has for our Epson IJPs (CS120x2, R260) and our Samsung ML-1740's with jbigkit and splix.
 
Old 03-07-2010, 12:31 PM   #5
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Quote:
Originally Posted by disturbed1 View Post
I looked for a list, but all I found were bug reports against cups and usblp.

[...]
That was the reason behind my question: I didn't find a list, either, but it would be VERY useful. So, if anyone knows where to find such a list, please, post it here!

EDIT: Any reliable method to find out, if a particular model is supported, would be equally good, of course!

The problem with trial and error is, that it (1) is very time-consuming and (2) is only useful in case of positive results. If your printer works, you know it's supported. But if it doesn't the causes can be manifold, and you won't know, if it's lack of libusb support or something else, why it's not working.

gargamel
 
Old 03-09-2010, 09:55 AM   #6
allend
Senior Member
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware-current
Posts: 3,520

Rep: Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876
I would like to share my experience with my Brother DCP-110C scanner/printer on -current with CUPS-1.4.2.
With the standard Slackware CUPS package, then scanning worked but printing did not work.
To get printing to work, I needed to blacklist usblp in /etc/modprobe.d and recompile CUPS by adding --disable-libusb (or --enable-libusb=no) to the cups.Slackbuild script. I also needed to change the group on the device entry /dev/bus/usb/<Bus>/<Device> from 'scanner' to 'lp'.
This is a problem for multifunction devices.
At boot, udev will assign the device to the 'scanner' group due to the rules in /lib/udev/rules.d/80-libsane.rules.
CUPS will not recognise the printer unless the group on the device is changed to 'lp', at which point the scanner is not available to skanlite or xsane until the group is changed back to 'scanner'.
Any ideas on how to make both scanning and printing available without reverting to CUPS 1.3.1 where everything worked?
 
Old 03-09-2010, 11:51 AM   #7
Zielony
LQ Newbie
 
Registered: Mar 2010
Posts: 17

Rep: Reputation: 1
For me even compiling CUPS with '--disable-usb' doesn't help, though I have lp group at the printer USB port set by udev.
 
Old 03-09-2010, 02:48 PM   #8
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Quote:
Originally Posted by allend View Post
I would like to share my experience with my Brother DCP-110C scanner/printer on -current with CUPS-1.4.2.
With the standard Slackware CUPS package, then scanning worked but printing did not work.
I have exactly the same problem with my Brother MFC-290C.

Quote:
Originally Posted by allend View Post
To get printing to work, I needed to blacklist usblp in /etc/modprobe.d and recompile CUPS by adding --disable-libusb (or --enable-libusb=no) to the cups.Slackbuild script. I also needed to change the group on the device entry /dev/bus/usb/<Bus>/<Device> from 'scanner' to 'lp'.
This is a problem for multifunction devices.
At boot, udev will assign the device to the 'scanner' group due to the rules in /lib/udev/rules.d/80-libsane.rules.
CUPS will not recognise the printer unless the group on the device is changed to 'lp', at which point the scanner is not available to skanlite or xsane until the group is changed back to 'scanner'.
Any ideas on how to make both scanning and printing available without reverting to CUPS 1.3.1 where everything worked?
I haven't tried it, but as workaround it might work to set the group to 'lp' in /lib/udev/rules.d/80-libsane.rules and make yourself a member of this group. Not sure, though, if this works, as 'scanner' might be hard-coded somewher in SANE or Skanlite.

BTW, I find the new web UI of CUPS confusing. Not exactly what I had expected from UI expert Apple...

gargamel
 
Old 03-10-2010, 06:25 AM   #9
allend
Senior Member
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware-current
Posts: 3,520

Rep: Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876
Having slept on it, I now have the answer to my own question.
Copy /lib/udev/rules.d/80-libsane.rules to /etc/udev/rules.d.
Add OWNER="lp" to the line for the scanner device in /etc/udev/rules.d/80-libsane.rules.
Quote:
# Brother DCP-110C
ATTR{idVendor}=="04f9", ATTR{idProduct}=="0169", MODE="0664", OWNER="lp", GROUP="scanner", ENV{libsane_matched}="yes"
On boot, the /dev/bus/usb/<Bus>/<Device> entry now has owner "lp" and is recognised by CUPS and has group "scanner" and is recognised for scanning. :-)
 
Old 03-10-2010, 03:53 PM   #10
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Two questions:
1. Is blacklisting usblp still required with this solution?
2. Is the order of parameters important? Because, I added OWNER="lp" at the end of the ATTR line, not before the GROUP, as you did.

It doesn't yet work here, the answers to the questions above would help me to track it further down. Thanks!

gargamel
 
Old 03-10-2010, 04:39 PM   #11
allend
Senior Member
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware-current
Posts: 3,520

Rep: Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876
Quote:
1. Is blacklisting usblp still required with this solution?
Yes, it was for me. The usblp kernel module creates a /dev/usb/lp0 device entry which does not appear to be recognised by CUPS-1.4.2.
Quote:
2. Is the order of parameters important? Because, I added OWNER="lp" at the end of the ATTR line, not before the GROUP, as you did.
I do not think the order is important.
 
Old 03-10-2010, 04:58 PM   #12
gargamel
Senior Member
 
Registered: May 2003
Distribution: Slackware, SLAX, OpenSuSE
Posts: 1,629

Rep: Reputation: 142Reputation: 142
Great, it works now!
I just had to reinstall the driver files provided by Brother and to manually select the PPD file.

Excellent! Thanks!

gargamel
 
Old 05-11-2010, 08:32 AM   #13
phi11ip
Member
 
Registered: Jul 2007
Location: Nottingham, UK
Distribution: Slackware64-current
Posts: 56

Rep: Reputation: 15
Quote:
Originally Posted by disturbed1 View Post
Since 1.4.x Cups no longer prefers usblp, and is built with libusb as the only backend. If your printer is not found by cups, you can try to remove usblp, and restart cups.

Code:
rmmod usblp
/etc/rc.d/rc.cups restart
Make this perminant either by rebuilding your kernel, or adding usblp to /etc/modprobe.d/blacklist
Thanks a lot for that. Worked a charm with my Canon PIXMA ip6700D printer.

Phil
 
  


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
xfree86-common xserver-common xfonts-base missing in etch/lenny unev_21 Debian 2 09-11-2009 03:12 AM
LXer: Setup CUPS (Common UNIX Printing System) Server and Client in Debian LXer Syndicated Linux News 0 09-23-2007 08:50 AM
Looking for common problems to learn from bhierons Linux - General 2 08-12-2007 10:10 PM
Help : Some Very Common Problems With LFS rushadrenaline Linux From Scratch 6 06-02-2007 02:32 PM
Where do I find CUPS (Common Unix Printing)? 87stang Linux - General 1 02-27-2007 12:06 PM


All times are GMT -5. The time now is 05:59 AM.

Main Menu
Advertisement
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