Quote:
Originally Posted by berndbausch
Today I tried my ancient Canon FB636 on a Raspberry Pi. It's not supported under Windows 7 anymore. It took me a while to get it working, my problem being permissions. This is Debian, but perhaps Fedora does it the same way. Also check http://sane-project.org.
xsane connects to the scanner via the sane daemon, saned, which accesses the scanner's device file. It has to run under root (strongly discouraged) or as a member of group scanner. If not, it will leave messages as follows in the system log:
Code:
Apr 13 12:21:01 pi saned[26731]: io/hpmud/musb.c 2066: Invalid usb_open: Permission denied
On my system, saned is started by the xinetd. The config file, /etc/xinetd.d/sane, needs to set the daemon's group, e.g.:
Code:
$ cat /etc/xinetd.d/sane
service sane-port
{
disable = no
socket_type = stream
protocol = tcp
user = saned
group = scanner
wait = no
server = /usr/sbin/saned
}
And this is what the scanner's device file looks like. It's owned by root:root and uses an ACL to grant write access to group scanner:
Code:
$ scanimage -L
device `canon630u:libusb:001:008' is a CANON Canoscan FB630U flatbed scanner
$ ll /dev/bus/usb/001/008
crw-rw-r-T+ 1 root root 189, 7 Apr 13 12:23 /dev/bus/usb/001/008
$ getfacl /dev/bus/usb/001/008
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/001/008
# owner: root
# group: root
# flags: --t
user::rw-
group::rw-
group:scanner:rw-
mask::rw-
other::r--
scanimage -L, by the way, also works only if the user belongs to scanner (or is root).
|
Thank you for your reply. I suppose that Fedora goes somewhat different. In particular there is
no scanner group, unless you create it by hand. The saned daemon is intended to scan over a LAN, is not running by default and cannot be enabled by systemctl.
In the meantime, I found a workaround (not solution).
I disabled USB Intel xHCI from BIOS (I'm afraid that this disable USB 3.0)
In this way the scanner works.
scanimage -L reports:
device `genesys:libusb:002:003' is a Canon LiDE 210 flatbed scanner
ll /dev/bus/usb/002/003 reports:
crw-rw-r--+ 1 root root 189, 130 Apr 13 12:56 /dev/bus/usb/002/003
getfacl /dev/bus/usb/002/003 reports: (bruno is my login name)
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/002/003
# owner: root
# group: root
user::rw-
user:bruno:rw-
group::rw-
mask::rw-
other::r--
I am not satisfied of this workaround because I lose the USB 3.0 functionality, so
I will look for a true solution.
Bruno