You are not logged in.
Hi all,
for quite some time, I am using my old HP Laserjet 5L - which only has a parallel port - over a USB-parallel adapter cable. Up to now, I have needed cups-usblp to get this to work. However, with a recent change in USB handling in upstream cups (1.5.2), many people seem not to need cups-usblp any longer. But when I was trying plain cups 1.5.2, I had the problems again. If I remember correctly, it was printing one page (if at all) and then the printer does not respond any more. The cups-usblp maintainer suggested I should ask here for help since the problems should not depend on which of the two packages I am using...
Anyone any ideas?
Thanks a lot in advance
Andreas
Last edited by awagner (2012-03-09 11:51:43)
Offline
Have a look if thishelp you to set it up again with plain cups. The method is referred to from the German archlinux cups wiki btw.
Offline
Thanks to both of you for your efforts. Unfortunately, it doesn't work yet.
I have installed cups 1.5.2, blacklisted usblp and added the udev rule mentioned in the posting Strike0 linked to. Now it prints the first job fine, but on every subsequent job, nothing happens on the printer while the printer status on the cups web interface says something like 'verarbeitet seit
Sa 25 Feb 2012 15:32:38 CET "Printing page 1, 42%"'. The job is not printed until I replug the printer and re-run the job in the web interface. Neither /var/log/messages.log nor /var/log/cups/error_log say anything suspicious.
More ideas?
Offline
Maybe I should have said that this need to replug the printer also occured with cups-usblp, only it seemed to happen only after sleep/hibernate mode and I didn't have to relaunch the job.
dmesg does not show anything related to the printer. I have now set loglevel to debug, and I hope I have captured the relevant parts of the log here: http://pastebin.com/JBRqzc9q (I have snipped something in-between and at the end which I think was just repeating).
Offline
Have you tried deleting the old installed printer after adding the udev rule?
If you delete it, it should show the printer at the top above the cups connection options. I'm asking since your printer log shows ipp://localhost ..... hp5L (Don't have cups debug here, so cant compare it)
After installation the printer should show connection in cups as: parallel:/dev/lp0
Offline
I have now deleted and re-added the printer. When adding, the printer showed on the top of the list (under local printers) with a plain text identification "HP Laserjet 5L". I chose this and it turned out to be connected to port usb://HP/LaserJet%205L. I think that this was what was used before, too. In the log, there still shows an ipp:// at some places and the problem persists...
Offline
Pity. In my cups conf, it reads:
MakeModel HP Color LaserJet Series PCL 6 CUPS
DeviceURI usb:/dev/usb/lp0
If you print that one page, does the printer respond to a test page (via the printer's button (press and hold) and also through cups) afterwards at all?
Does it blink?
edit: two more things to try:
1. try using the next Laserjet driver (not 5L - LJ 6 PCL, same as mine but not colour obviously)
2. look if your user is member of the group "lp"
and one linki googled that may interest you.
Last edited by Strike0 (2012-02-26 00:12:09)
Offline
My printers.conf:
<Printer hplaserjet5l>
UUID urn:uuid:bf1ee688-5212-3cab-5a1c-1a8e6120a1d4
Info HP LaserJet 5L
Location
MakeModel HP LaserJet 5L - CUPS+Gutenprint v5.2.7
DeviceURI usb://HP/LaserJet%205L
State Idle
StateTime 1330201244
Type 4116
Accepting Yes
Shared No
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
OpPolicy default
ErrorPolicy stop-printer
</Printer>
BTW, I don't have any lp (nor usb) entry in my /dev directory, should there be one? or should I check at another place?
After that one page, it does not even blink when I print anything else - pdf, cups test page. Except for the printer's own test page - that works fine.
Offline
Look at my edit in #9, we cross-posted at the same time.
I re-check the cups.conf line when and come back with that (I'm not near the printer). You could look what happens in dmesg when you it in.
Offline
I have tried with HP LaserJet Series PCL 4/5 and 6, but that wouldn't help. Also, I am member of the lp group.
I have to go to bed, dunno when I will be able to get back to this, possibly not tomorrow. Thank you a lot so far.
Offline
Ok. I re-checked the config and quoted it wrong above. The working printers.conf has DeviceURI parallel:/dev/lp0 in it. The one with usb:/ possibly was one of my own tries back then which I did not delete.
Apart from that udev rule should create a /dev/usb/lp0 (from detecting the printer) and the extra rule a symlink dev/lp0 to /dev/usb/lp0 at boot time.
Offline
Here's the current status, which is more or less bearable: I am on cups 1.5.2, which sees my printer as connected to usb://HP/LaserJet%205L. Printing for the first time after boot is okay, on subsequent tries, nothing happens. When I pull and re-plug the usb cable, printing resumes. Each time, the complete queue is printed, not just a single job. Only when there is nothing to print for some time, and then I want to print something again, the re-plugging is necessary. Re-launching the queue/job is not necessary, depending on when I find the right timing of un-/re-plugging, I assume.
At no time do I see either /dev/lp* or /dev/us*. But I only tried with 'ls'. Maybe there is some sort of command that would keep watching device nodes being created and removed when I plug/unplug a device?
Thanks so far,
Andreas
Edit: It's actually not the complete queue. I can't tell - more than a single job but at one point it hangs.
Last edited by awagner (2012-03-01 11:57:41)
Offline
Edit: It's actually not the complete queue. I can't tell - more than a single job but at one point it hangs.
That means it is not working really so far, pity.
At no time do I see either /dev/lp* or /dev/us*. But I only tried with 'ls'. Maybe there is some sort of command that would keep watching device nodes being created and removed when I plug/unplug a device?
Here is my dmesg after I un-/plug the printer:
[ 556.974443] usb 3-4: USB disconnect, device number 3
[ 556.974600] usblp0: removed
[ 562.673353] usb 3-4: new high-speed USB device number 8 using ehci_hcd
[ 562.798922] usblp0: USB Bidirectional printer dev 8 if 0 alt 0 proto 2 vid 0x04E8 pid 0x328C
And this is the udev symlink created by the rule after re-plugging in dev/usb (ls -la):
crw-rw---- 1 root lp 180, 0 1. Mär 19:54 lp0
If you don't see the latter, there is something wrong with the rule or the cups assignment of it still. Hm. I keep wondering if the issue is connected with the adapter you use. But no idea why cups-blb should have worked with it better.
Offline
Aargh! Now all local interfaces are gone. I thought since I don't even have any /dev/usb* or /dev/lp* files or directories, maybe the problem is in udev. I have edited some of my rules - while I was at it, mainly for automounting - and now cups cannot connect to anything anymore.
kernel modules:
"lsmod | grep lp" gives only some *-helper* modules, no parallel, lp or usblp module. usblp is even blacklisted in /etc/modprobe.d/usblp.conf.
lsusb shows the usb-parallel adapter cable:
Bus 001 Device 014: ID 067b:2305 Prolific Technology, Inc. PL2305 Parallel Port
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 8
idVendor 0x067b Prolific Technology, Inc.
idProduct 0x2305 PL2305 Parallel Port
bcdDevice 2.02
iManufacturer 1 Prolific Technology Inc.
iProduct 2 IEEE-1284 Controller
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 78
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xa0
(Bus Powered)
Remote Wakeup
MaxPower 100mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 7 Printer
bInterfaceSubClass 1 Printer
bInterfaceProtocol 1 Unidirectional
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 1
bNumEndpoints 2
bInterfaceClass 7 Printer
bInterfaceSubClass 1 Printer
bInterfaceProtocol 2 Bidirectional
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 2
bNumEndpoints 3
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 0
bInterfaceProtocol 255
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0004 1x 4 bytes
bInterval 1
Device Status: 0x0000
(Bus Powered)
Besides one udev rules file for memory sticks, I have only this one line/rule:
ACTION=="add", ATTRS{model}=="IEEE-1284 Controller", SYMLINK+="lp0", GROUP="lp"
Edit: when I remove these 2 rulefiles, the behaviour stays just the same.
When I manually modprobe usblp, I get a /dev/usb/lp0 file at least. But then, when I manually specify parallel://dev/usb/lp0 or usb:/dev/usb/lp0 or usb://dev/usb/lp0 as DeviceURI in printers.conf, nothing happens: Cups seems to see the printer and sends some percentage of a job to it, but the printer does not even blink its led.
I am rather desperate now, since not printing at all is definitely much worse than having to re-plug the printer every now and then...
Any ideas? TIA
I have re-installed cups and udev
Can you verify if your DeviceURI contains one or two slashes in usb:/dev... and if you have usblp blacklisted or loaded?
Last edited by awagner (2012-03-02 11:45:31)
Offline
I think now we got it. You want usblb loaded and not blacklisted. I am not sure why you added the ATTRS{model} in that rule above, but ok. We want the /dev/lp symlink through it.
That is my printers.conf line, after letting cups add it:
DeviceURI parallel:/dev/lp0
So it is one slash.
Undo the blacklist, delete the printer conf, un-/replug it and let cups add it again, I would suggest.
Offline
Undo the blacklist, delete the printer conf, un-/replug it and let cups add it again, I would suggest.
Okay, it is printing right now (Cups test page). I had undo the blacklisting and tried to remove the printer from printers.conf, replug the cable, restart cups and then let cups add my printer. That didn't work: Cups did not see any local port at all. So I stopped cups, re-opened the printers.conf and re-used my old hplaserjet5l entry and edited the DeviceURI to parallel:/dev/usb/lp0 (with the /usb in the tree that you don't seem to have/need). Then re-started cups and the printer was there and, as I said, is printing again.
Now it remains to be seen if the initial problem is solved. Thanks so much for now. I was really panicking when I didn't have any printer left and couldn't seem to add/find it again.
Offline
Ok, sounds cool for now. I think the inital cups problem might have been due to a missing restart of cupsd. But you got around it. So, lets hope it does the job now.
Offline
Okay. Some reboots/hibernate/sleep/kernel upgrade cycles later, it still works without a hitch. I hereby declare this solved
Thanks a thousand times for your help, Strike0 and pyther.
Andreas
Offline