TopherC n00b
Joined: 29 Oct 2003 Posts: 47 Location: Cornell University
|
Posted: Thu Dec 18, 2014 4:20 am Post subject: Got printer working, but need permanent fix |
|
|
I have an old HP Photosmart C4680, a multifunction printer/scanner. I use it for both, but for several months it hasn't been working as a printer in Gentoo -- only as a scanner.
At loooong last I found a temporary solution. The USB device was being added to the scanner group, not the lp group. I think the solution is using ACLs to set multiple group membership. I can fix this manually, but is there a way I can do this inside /etc/udev/rules.d/?
For reference, here's my symptom:
In /var/log/messages I get:
Code: | Dec 17 20:47:52 kryton hp[24591]: io/hpmud/musb.c 589: invalid usb_open: Permission denied
Dec 17 20:47:52 kryton hp[24591]: io/hpmud/musb.c 1142: unable to open hp:/usb/Photosmart_C4600_series?serial=CN9AUF20FC05G0
Dec 17 20:47:52 kryton hp[24591]: prnt/backend/hp.c 745: ERROR: open device failed stat=12: hp:/usb/Photosmart_C4600_series?serial=CN9AUF20FC05G0 |
And here's my temporary solution:
Code: | # lsusb
Bus 001 Device 006: ID 03f0:7411 Hewlett-Packard
# ls -l /dev/bus/usb/001/006
crw-rw-r--+ 1 root scanner 189, 5 Dec 17 20:37 006
# setfacl -m g:lp:rw /dev/bus/usb/001/006
# getfacl /dev/bus/usb/001/006
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/001/006
# owner: root
# group: scanner
user::rw-
user:heather:rw-
group::rw-
group:lp:rw-
mask::rw-
other::r-- |
The setfacl command is the winner. |
|