# hp 930c stopped working [solved]

## Poff

I found out today that my hp deskjet 930c does not print in gentoo any longer. It still works in windows and lsusb gives: 

Bus 002 Device 004: ID 03f0:1204 Hewlett-Packard DeskJet 930c

If I unplug the printer and then plug it back, dmesg returns: 

usb 2-10: USB disconnect, address 4

drivers/usb/class/usblp.c: usblp0: removed

usb 2-10: new full speed USB device using ohci_hcd and address 5

usb 2-10: configuration #1 chosen from 1 choice

drivers/usb/class/usblp.c: usblp0: USB Bidirectional printer dev 5 if 0 alt 1 proto 2 vid 

0x03F0 pid 0x1204

I removed the printer and tried to add it again through localhost:631, but the printer name was not appended to the device name as it should according to the gentoo printing guide. I use hpijs. I have no idea why the printer does not work, please help me and please be clear since I am quite an inexperienced gentoo user.Last edited by Poff on Tue Jul 25, 2006 7:03 pm; edited 1 time in total

----------

## turtles

Welcome to gentoo

Doubble check emerge to see if you have the latest versions (sounds like you do)

```
emerge -pvu cups
```

```
emerge -pvu foomaticdb
```

```
emerge -pvu hpijs
```

```
emerge -pvu coldplug
```

I think we need the log of cups_errors (debug option): 

Open up /etc/cups/cupsd.conf in your favorite text editor as root (kate, nano, xemacs)

scan it for errors:

```
nano /etc/cups/cupsd.conf
```

Set log level to debug:

```
# LogLevel: controls the number of messages logged to the ErrorLog

# file and can be one of the following:

#

#     debug2   Log everything.

#     debug   Log almost everything.

#     info      Log all requests and state changes.

#     warn      Log errors and warnings.

#     error     Log only errors.

#     none      Log nothing.

#

LogLevel debug
```

Save the file. 

EDIT: Try to print a job

then check the output of

```
nano /var/log/cups/error_log
```

Paste the output of the file here however if you scan the file it may give you clues as to where it is hanging up try googleing anything that is not working.

 *Quote:*   

> please be clear since I am quite an inexperienced gentoo user.

 

Hope that is clear enough

----------

## Poff

Thank you for your reply turtles,

Yes, your post was clear enough - thank you! It seems as if I have the latest versions of the programs that you listed, except for foomaticdb. I could actually not find that program in portage. I guess that you meant foomatc-db. I do not have foomatic-db installed, but I do have foomatic-db-engine-3.0.2

I removed the printer again in localhost:631 and reinstalled it just to know where in /var/log/cups/error_log to start and not list the entire file. This is it:

I [02/Jul/2006:21:56:34 +0200] Started "/usr/lib64/cups/cgi-bin/printers.cgi" (pid=9985)

I [02/Jul/2006:21:56:37 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9986)

I [02/Jul/2006:21:56:40 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9987)

I [02/Jul/2006:21:56:40 +0200] Printer 'hpdeskjet930c' deleted by 'root'.

I [02/Jul/2006:21:56:40 +0200] Saving printers.conf...3.0.2

I [02/Jul/2006:21:56:41 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9988)

I [02/Jul/2006:21:56:42 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9989)

I [02/Jul/2006:21:57:03 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9990)

I [02/Jul/2006:21:57:10 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9991)

I [02/Jul/2006:21:57:13 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9992)

I [02/Jul/2006:21:57:22 +0200] Started "/usr/lib64/cups/cgi-bin/admin.cgi" (pid=9993)

I [02/Jul/2006:21:57:22 +0200] Setting hpdeskjet930c device-uri to "usb:/dev/usb/lp0" (was "file:/dev/null".)

I [02/Jul/2006:21:57:22 +0200] Setting hpdeskjet930c printer-is-accepting-jobs to 1 (was 0.)

I [02/Jul/2006:21:57:22 +0200] Setting hpdeskjet930c printer-state to 3 (was 5.)

I [02/Jul/2006:21:57:22 +0200] Saving printers.conf...

I [02/Jul/2006:21:57:22 +0200] New printer 'hpdeskjet930c' added by 'root'.

I [02/Jul/2006:21:57:27 +0200] Started "/usr/lib64/cups/cgi-bin/printers.cgi" (pid=9994)

I [02/Jul/2006:21:57:43 +0200] Adding start banner page "none" to job 3.

I [02/Jul/2006:21:57:43 +0200] Adding end banner page "none" to job 3.

I [02/Jul/2006:21:57:43 +0200] Job 3 queued on 'hpdeskjet930c' by 'myusername'.

I [02/Jul/2006:21:57:43 +0200] Started filter /usr/lib64/cups/filter/pstops (PID 9998) for job 3.

I [02/Jul/2006:21:57:43 +0200] Started filter /usr/lib64/cups/filter/foomatic-rip (PID 9999) for job 3.

I [02/Jul/2006:21:57:43 +0200] Started backend /usr/lib64/cups/backend/usb (PID 10000) for job 3.

From what I see I would guess that the line 

I [02/Jul/2006:21:57:22 +0200] Setting hpdeskjet930c device-uri to "usb:/dev/usb/lp0" (was "file:/dev/null".)

ought to give me a hint. Please let me know if I am right or wrong since I am trying to learn gentoo. However, I am not sure how to proceed. I checked /dev and it contains a link called HPDeskJet930C pointing at usbdev2.4

----------

## --D_S--

Hi

Same problem here just upgraded my sistem with:

```

emerge -uDN world

```

and after emerging everything I updated all config files with:

```

etc-update

```

I noticed that in the file etc/conf.d/rc the new file had RC_DEVICE_TARBALL="no" and many other addons, so I overwrote it and forgot to change it.

After rebooting all /dev/usb* devices where gone including /dev/usb/lp0 wich is used by cups to print, I checked the rules and suposedly it should be created with: 

 */etc/udev/rules.d/50-udev.rules wrote:*   

> 
> 
> # usb devices
> 
> KERNEL=="hiddev*",              NAME="usb/%k"
> ...

 

I already tried rebooting and adding a rule for it but nothing is done. 

Thanks.

----------

## --D_S--

It's fixed, just reemerged udev(087-r1) colplug(20040920-r1) and hotplug(20040923-r2) and restarted each:

```

/etc/init.d/colplug restart

/etc/init.d/hotplug restart

udevcontrol reload_rules

udevstart

```

And the simlinks where created, the strage thing is why they where not beeing created before.

----------

## Poff

Thanks --D_S--

However, your suggestions do not fix the problem for me. I do not have /dev/usb, but udev does create a node called /dev/lp0 and writing

```
udevinfo -q path -n /dev/lp0
```

 returns

/class/usb/lp0

```
udevinfo -a -p /sys/class/lp0
```

 gives

udevinfo starts with the device the node belongs to and then walks up the

device chain, to print for every device found, all possibly useful attributes

in the udev key format.

Only attributes within one device section may be used together in one rule,

to match the device for which the node will be created.

I do not know what to do, please help me!

----------

## --D_S--

Sadly the fix above worked untill I rebooted, today there where no /dev/usbs anymore.

udev does create the device file in /dev/usbdev?.? when I turn on my printer, the following rule works too.

 */etc/udev/rules.d/10-udev.rules wrote:*   

> 
> 
> BUS=="usb", DRIVER=="usb", SYSFS{serial}=="FGG010601181357480", SYSFS{product}=="USB Printer", SYSFS{manufacturer}=="EPSON", NAME="%k" SYMLINK="custom/epson-c67"
> 
> 

 

So the printer is working and is detected by the sistem and custom udev rules work so I really don't know what's happening here, 50-udev.rules has the entry for usb lp devices.

I modified the above rule to:

 */etc/udev/rules.d/10-udev.rules wrote:*   

> 
> 
> BUS=="usb", DRIVER=="usb", SYSFS{serial}=="FGG010601181357480", SYSFS{product}=="USB Printer", SYSFS{manufacturer}=="EPSON", NAME="%k" SYMLINK="usb/lp%n"
> 
> 

 

```

udevcontrol reload_rules

udevstart

```

And udev created 2 symlinks /dev/usb/lp0 --> /dev/lp0 and /dev/usb/lp2 --> /dev/usbdev2.2 .

Now that it did create the simlinks I tried to remove the rule and restarted udev and now it creates /dev/usb/lp0.

I'll try to reboot to see if this change is permanent and post in some time.

----------

## Poff

Thank you --D_S--! 

You just solved my problem. I added the following line to /etc/udev/rules.d/10-local.rules

BUS=="usb", DRIVER=="usb", SYSFS{serial}=="HU11F1H0K3JJ", SYSFS{product}=="USB Printer", NAME="%k" SYMLINK="usb/lp%n"

Still, it would be nice to know what update made the printer stop working and why? It feels as though something is wrong since udev did not automatically create a node that "worked" with localhost:631, or did it? Is it possible to choose which device node to use for the printer so that it does not have to be /dev/usb/lp0? I hope that someone will be kind enough to post answers to my, most likely very dumb, questions.

Nevertheless, since my printer seems to be working now I guess I ought to put [solved] to this thread. --D_S--, please post whether you managed to solve your issue or not, so I know if I can put [solved] to this thread.

----------

## turtles

I guess this might be a bug of sorts It seems hplip depends on somthing in hotplug. the new udev probably had you remove hotplug.

see middle of this post.

https://forums.gentoo.org/viewtopic-t-476733.html

Seems like a open bug report  you may be able to help.

----------

## Poff

Thank you turtles,

Very interesting post indeed. I checked whether I have hotplug and coldplug installed and both are.

If I write:

```
emerge -pv hotplug
```

the system wants to rebuild hotplug. It does not say anything about udev blocking it. I did get the same result for coldplug as well. 

```
equery depends hotplug
```

returns:

[ Searching for packages depending on hotplug... ]

sys-apps/coldplug-20040920-r1

and 

```
equery depends coldplug
```

gives:

[ Searching for packages depending on coldplug... ]

I guess that the blocking issue is arch dependent (I use an amd64 system). I believe that you still might be right though. Perhaps udev has taken care of what hotplug and coldplug used to do even though it does not force me to uninstall hotplug and coldplug.

--D_S--, you said that your printer worked after reemerging and restarting udev(087-r1) colplug(20040920-r1) and hotplug(20040923-r2), but then stopped working after a reboot. Did you try to save your device nodes instead of letting udev create them each time? I do not remember what the file that needs to be edited is called, but I am quite sure that I read a thread on the forum where someone had the same problem with the nvidia nodes disappearing after each reboot.

----------

## Poff

Just a question about the appearance. Why are the posts in this thread much wider than the posts in other threads. Do I have to manually break lines when I am writing?

----------

## --D_S--

Hi

Sorry been a little busy. I left the varible RC_DEVICE_TARBALL="no" and thought that the nodes would be made at next boot but they weren't. 

When I updated the sistem there where uptdates for the /etc/conf.d/rc file wich add many more varibles one of them:

 */etc/conf.d/rc wrote:*   

> 
> 
> # Do we allow services to be hotplugged? If not, set to RC_HOTPLUG="no"
> 
> # NOTE: This does not affect anything hotplug/udev related, just the
> ...

 

I don't know i this has something to do with the problem but there's an ambiguity there and apparently hotplug/colplug is used at boot.

Whell the printer works by the custom rule but I don't think its working well because it makes two symlinks /dev/usb/lp0 --> /dev/lp0 and /dev/usb/lp2 --> /dev/usbdev2.2.

This bug? is a little odd, udev works, the printer works, cups works(althoug it would be better to use a custom symlink for each printer) It just leaves a conflict with coldplug or hotplug.

They seem safe to unmerge I'll try and post later.

Thanks

----------

## --D_S--

Well unfortunately still doesn't work although the devices /dev/lp0 and /dev/usbdev?.? are still created.

I unmerged coldplug and hotplug, rebooted and everything is fine with the system.

I'll leave the rule for /dev/usb/lp0 for now. Is there a way to tell cups to point to a custom symlink like /dev/printers/epson that way the printers would be better identified and would follow udev guidelines, I tried to edit the /etc/cups/printers.conf file but it's overwritten every time cups starts.

----------

## Jkay

Welcome to Gentoo, indeed!! LOL ... the distro where obscure world/system updates can break anything!  :Cool: 

Just kidding, I love you all   :Razz: 

Anyway, my HP printer stopped working June 12th as well, and this thread got me thinking about what the problem was.

My printer is a *wireless* model tho, so messing about with usb devices wasn't going to help .. I took the other troubleshooting advice here, and found that the socket: address (socket://192.168.1.120:9100) to the printer had been deleted when the hotplug/etc system apps were updated. I re-ran the CUPS:631 interface for printer configuration and this re-added the printer to the address database.

The HP began printing a month's worth of queue as soon as I completed this.

----------

## Poff

Thank you for your reply Jkay! (and for your confidence-inspiring joke about Gentoo   :Very Happy:  ) 

I am sorry I did not respond earlier, but I have been away for a couple of days. How did you do in order to re-add the printer to the address data base? How do you change the device uri so that you do not have to use usb:/dev/usb/lp0?

----------

## Jkay

HP printers have a semi-HP supported driver suite called HPLIP, which is available as an ebuild for Gentoo.

Problems came up when the hjip ebuild, which Linux users use to access HP All In One printer's scanners, FLASH readers, and FAX elements, was depreciated, and all of it's functionality was rolled into HPLIP, so instead of needing 2 portage packages, you now needed one, but you ALSO needed to re-configure everything to understand the new HPLIP version and also HPLIP needed to be compiled with new USE variables, like "SNMP" if your HP printer was a Networked printer.

If you just ran "# emerge -uavDN world" and wondered why your HP printer stopped working ... well, that's why. 

CUPSd has an automatic web page interface at http://localhost:631 .. from here you can add and configure all of your printers. You can set URIs, drivers, set Default system printers, view the print queue, edit the print queue, etc. The HPLIP utility suite reads the configs set up by the CUPSd web page, and uses the data to communicate with HP printer/fax/scanner/flashreader combo units or other HP printers.

Since my printer is on the network, I don't use a USB URI, I use "socket://<ip address of printer>:<port number>" .. that's the syntax for CUPSd and HPLIP.

Here's the HP Device manager on Gentoo .. as you can see, it can control everything in an All-In-One HP printer.

http://members.cox.net/jkay/images/hpdevicemanager_hplip.png

----------

## Poff

Very instructive post Jkay. I thank you very much!

After I had read your post I had to check whether I use hpijs or hplip, and currently I only have hpijs installed. It makes sense since my printer does not include neither a scanner nor a fax. However, it makes me wonder if my problem arose when everything was rolled into hplip, or because of something else.

Just another question about the uri. Let us suppose that I wanted to write an udev rule for my usb printer so that a node called for example /dev/HP is created. How should I do in order to make this the device uri connected to my printer and hence seen when I look at the printer in http://localhost:631 ?

Right now my printer works, but I had to manually create an udev rule creating the node /dev/usb/lp0.

----------

## Jkay

I'm not certain how the CUPSd senses USB printers. All I see in the CUPSd admin tool regarding USB is simply an area to say that you HAVE a USB printer, and nothing more about URIs .. perhaps someone else will know.

I wonder if the "Browsing" option in the /etc/cups/cupsd.conf file works for USB, as well as the Network ... this option tells the daemon to listen for and identify any printers it can find.

----------

## turtles

Well on my "outdated" and perfectly stable working gentoo x86 desktop system emerge tells me

```
[blocks B     ] net-print/hpijs (is blocking net-print/hplip-0.9.7-r3)                                                                  
```

As well as masking xorg 7.0 (6.9 works fine) I will mask hplip. I would  try net-print/hpijs and masking net-print/hplip-0.9.7-r3 to see if you get a working stable system. I also have cups, foomatic-db, and a hp deskjet 932 C attached to a netgear FM114P print server all work great except you can't turn off printer or you have to reset netgears server.

----------

## Jkay

hpijs is depreciated, and will not be supported at all eventually. hplip is the way to go.

----------

## Poff

Hello everyone,

Since my issue is solved I guess that I had better add [solved] to this post. I dare not mess around and change the driver from hpijs to hplip now when the printer works. However, I will keep Jkay's words in mind and give hplip a shot when I feel I have time to mess with it. Perhaps I will have to create a new thread on the forum then.

Thanks for all help!

----------

