Setting up a scanner in Slackware
I just got my first Linux scanner, and need some help setting it up to work under Slackware.
sane-find-scanner gives: Code:
found USB scanner (vendor=0x04a9 [Canon], product=0x221c [CanoScan], chip=GL841) at libusb:001:008 Code:
device `genesys:libusb:001:008' is a Canon LiDE 60 flatbed scanner dmesg shows activity when I plug/unplug, and lsusb gives Code:
Bus 001 Device 008: ID 04a9:221c Canon, Inc. I have not done any changes to /etc/sane.d/* files, but /etc/sane.d/genesys.conf contains my scanner, uncommented. I'm on 2.6.15.7 vanilla on Slackware-current. Anyone? -Y1 |
Is your user a member of the group "scanner"?
|
Yes.
The problem is though that I don't know which devicefile the scanner corresponds to, and how to manipulate the permissions on that file. /dev/usb contains only lp0 So my question remains - can I manipulate this with udev? -Y1 |
You could try this to mount the usbfs:
Code:
mount none -t usbfs /proc/bus/usb -o devgid=10,devmode=0660 Code:
usbfs /proc/bus/usb usbfs devgid=10,devmode=0660 0 0 Eric |
Hey Yalla, if you can please. Let us know how you make out. I'm looking to buy a scanner so I can use it with slackware, and they have that model here for 79 bux at a local store. Seems like a nice every day scanner to use. Thanks.
|
Thanks for the input Eric,
I guess I could be blamed for putting the standards too high, but what I'd really really like is to be able to just have the scanner work automagically whenever it's plugged in, just like other USB devices... Mounting it means it'll be more complex than in Windows, and my (silly?) quest is to prove my Linux system is both easier and more userfriendly than Windows... I added the following line to my /etc/udev/rules.d/10-local.rules Code:
BUS="usb", SYSFS{product}="CanoScan", MODE="0666", SYMLINK="scanner" However, the scanner still only works for the super-user, which leads me to believe this is a userspace/sane problem rather than a udev/file permission problem. I noticed that Slackware comes with 0.1.8 rather than the latest 0.1.12 (which according to Pat is because the lates version breaks kernel 2.4), so maybe that's where the problem is. Will investigate and reporat back when/if I find something. This is an *annoying* problem, as permission-based issues such as programmes/systems functioning as root but breaking as normal users are normally so lame... -Y1 |
Quote:
Please be patient with me... I know I'm not answering your udev question and maybe I'm missing the point. My understanding is that hotplug uses the entries in libsane.usermap to detect the scanner, and then the libusbscanner script changes the device ownership to root:scanner. Why not just add an entry for your scanner to libsane.usermap and let hotplug take care of this? |
This sounds like the problem that I encountered with my Brother DCP-110C scanner/copier/printer. In my case the problem was resolved by adding this line to my /etc/fstab file.
scanner /proc/bus/usb usbfs auto,devmode=0666 0 0 |
I havent' done scanners before, but allend this line you typed
Quote:
|
Once again plenty thanks to Alien_Bob and allend and the rest for coming to the rescue.
Adding a line to fstab was all it took and now the scanner works perfectly well for all users! I guess I read the initial advise wrong, thinking each user would have to manually "mount" the scanner before it would function.. As I still don't understand the underlaying fundamentals of this, I would greatly appreciate if someone could point me towards where i can read up on how the architecture behind this system is designed, and why the scanner must be "mounted"... Also - I noticed that the /etc/hotplug/usb/libsane.usermap does not contain an entry for my precice scanner, but /etc/sane.d/genesys.conf does - could this cause problems, or is one selectd over the other? The sane.conf contains both my model (LiDE 60) as well as LiDE 50, 25 and 30. However, the libsane.usermap contains only the LiDE 50. Thanks again! -Y1 |
Quote:
I think that the sane.d stuff recognizes your scanner but doesn't change any permissions. Hotplug does. Would you be up for confirming this? I'd be interested in knowing what happens if you comment out the new fstab line, add your scanner to libsane.usermap, and then plug the scanner in again. Anyway, I'm glad it works for you now. |
Quote:
When you plug in a USB scanner, hotplug searches thru the libsane.usermap file. If it finds a match, then it'll change the associated device's ownership to 'root:scanner'. This obviously wasn't happening in your case, hence the inability to use the scanner as a normal user. Personally, all I had to do was add my user to the 'scanner' group and it worked without having to do anything else. Our scanner is a CanoScan N1240U. |
Guys,
Can someone summarize what needs to be done for Slackware 12? I have read this thread, and want to setup a USB Canoscan N 656U under Slackware 12. Many thanks |
Try adding yourself to the groups 'scanner' and 'plugdev' and see if it works.
Code:
gpasswd -a your_account scanner Don't forget to logoff and login again after you added yourself to these groups if you are logged in at the time you run the commands. After that, also restart the messagebus: Code:
/etc/rc.d/rc.messagebus reload Eric |
I have been sharing a scanner from a slackware server for awhile now. The server is running Slack-11.0 with a 2.6 kernel. I have no doubt that the way I set up sane in 11.0 will work in 12.0. HPLIP worked just fine for my hp psc2355 on a single machine but sane with hpoj was the way I went for a shared scanner. After it's working on one box its not to hard to share it. Here are my notes (below) for setinng up the first box. The complete networking setup is here: http://www.turtlespond.net/scripts/s...t_server_notes.
Quote:
|
All times are GMT -5. The time now is 04:50 PM. |