Problems getting my Samsung SCX-4100 to run as a scanner
Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Problems getting my Samsung SCX-4100 to run as a scanner
Hello,
first of all, this is my first post on this forum, so I'm not 100% sure whether this is the right subforum if not, please move my thread.
I'm using a Scientific Linux 7.2 64-bit distribution, which is based on RedHat Enterprise Linux, so everything that works for RedHat should work out for me too.
Basicly I want to get my Samsung SCX-4100 printer and scanner to work. The printing function works perfectly fine, but I have trouble getting the scanning functions to work. I figured out that I'm gonna need SANE and CUPS packages to use the printer as a scanner. To make sure that I have all required packages, I used:
Code:
sudo yum install *sane*
to install sane and I also used:
Code:
sudo yum update
to make sure everything is up to date.
I also checked that the Samsung SCX-4100 is supported by the current version of SANE.
Following some guides from the internet, I learned that I'd need an official Samsung driver too, to get the printer to work properly, so I installed the "Samsung Unified Linux driver" from the official Samsung website.
Up to this point everything worked out perfectly, but now the problems begin to start. First of all the scanner is being detected properly by scanimage:
Code:
scanimage -L
gives me:
Quote:
device `smfp:usb;04e8;3413;8J21BAKY926596L ' is a Samsung Samsung SCX-4100 Series on USB Scanner
But it is not being detected by sane-find-scanner:
Code:
sudo sane-find-scanner
gives me:
Quote:
found USB scanner (vendor=0x138a, product=0x0011) at libusb:001:003
which has a different vendor and product id than the Samsung SCX-4100, so I guess it's something else.
Furthermore I'm not able to scan anything:
Code:
scanimage
always gives me:
Quote:
scanimage: open of device smfp:usb;04e8;3413;8J21BAKY926596L failed: Device busy
I get the same error when I use xsane insead of scanimage and simple-scan wont work eigther.
First I thought it was a problem with my rights, so I checked:
Code:
ls -l /dev/usb/lp0
which gives me:
Quote:
crw-rw----. 1 root lp 180, 0 29. Mai 14:03 /dev/usb/lp0
so I added myself to the lp-group to get rw access, but that didnt fix anything. After that I tried to scan with full root-access, but even that resulted in the device busy error.
My question is whether any of you know similar errors and their fixes or have basicly any idea of whats going wrong here. I know the printer is pretty old, but I read that many guys on the internet already got the scanner to work, and I thing it should be possible cause according to http://www.sane-project.org/sane-mfgs.html#Z-SAMSUNG the Samsung SCX-4100 is still supported.
I've already seen this instruction before, but I was not able to follow it, because the entry "usb 0x04e8 0x3413" already existed in my "/etc/sane.d/xerox_mfp.conf". Furthermoe the file "/lib/udev/rules.d/40-libsane.rules" doesnt exist. I checked the /lib64 folder too and it doesnt exist there eigther. The only file I found in the rules.d directory, that has something to do with SANE is "/lib/udev/rules.d/65-sane-backends.rules", but I doubt thats the same file. Last point is that the service saned doesnt exist on my system.
Code:
sudo service saned restart
always gives me:
Quote:
Failed to restart saned.service: Unit saned.service failed to load: No such file or directory.
And it doesnt work with start instead of restart eigther. I guess the ubuntu instructions use a different SANE package than me.
Thanks for your answers.
Actually I'd like to stay with SL, cause its the distribution I use at university too. When I saw that SCX-4100 is included in xerox_mfp package, I thought it would be easy to get it working, but despite the driver package being installed, it just wont work. Without having the Samsung Unified Linux driver package installed, the scanner isnt even recognized, so there seems to be something wrong with my SANE. I really hope someone had the same problem before or has a brilliant idea how to get it working.
Your scanner has to show up in lsusb properly, if it does not then it cannot be found and made to work. I personally use ethernet connected printers/scanners only. Can yours be connected over ethernet?
Your scanner has to show up in lsusb properly, if it does not then it cannot be found and made to work. I personally use ethernet connected printers/scanners only. Can yours be connected over ethernet?
Sadly the printer has no ethernet connection. But I guess it's showing up properly in lsusb, cause it gives me:
Quote:
Bus 001 Device 008: ID 04e8:3413 Samsung Electronics Co., Ltd SCX-4100 Scanner
which is the same vendor and product id as in sane-xerox_mfp.conf
It may be something else is claiming it, I'd unplug the scanner, run tail -f /var/log/messages and plug it back in ...
Thanks for the advice. I did plug it back in and got:
Quote:
May 29 18:28:00 localhost kernel: usb 1-2: new full-speed USB device number 17 using xhci_hcd
May 29 18:28:00 localhost kernel: usb 1-2: New USB device found, idVendor=04e8, idProduct=3413
May 29 18:28:00 localhost kernel: usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
May 29 18:28:00 localhost kernel: usb 1-2: Product: Samsung SCX-4100 Series
May 29 18:28:00 localhost kernel: usb 1-2: Manufacturer: Samsung
May 29 18:28:00 localhost kernel: usb 1-2: SerialNumber: 8J21BAKY926596L
May 29 18:28:00 localhost kernel: usblp 1-2:1.0: usblp0: USB Bidirectional printer dev 17 if 0 alt 0 proto 2 vid 0x04E8 pid 0x3413
May 29 18:28:00 localhost systemd: Reached target Printer.
May 29 18:28:00 localhost systemd: Starting Printer.
May 29 18:28:00 localhost systemd: Started Configure Plugged-In Printer.
May 29 18:28:00 localhost systemd: Starting Configure Plugged-In Printer...
May 29 18:28:01 localhost kernel: usblp0: removed
May 29 18:28:01 localhost kernel: usblp 1-2:1.0: usblp0: USB Bidirectional printer dev 17 if 0 alt 0 proto 2 vid 0x04E8 pid 0x3413
May 29 18:28:02 localhost udev-configure-printer: Re-enabled printer ipp://localhost:631/printers/SCX-4100
After some time it gave me:
Quote:
May 29 18:28:33 localhost dbus-daemon: dbus[871]: [system] Activating service name='org.fedoraproject.Setroubleshootd' (using servicehelper)
May 29 18:28:33 localhost dbus[871]: [system] Activating service name='org.fedoraproject.Setroubleshootd' (using servicehelper)
May 29 18:28:34 localhost dbus[871]: [system] Successfully activated service 'org.fedoraproject.Setroubleshootd'
May 29 18:28:34 localhost dbus-daemon: dbus[871]: [system] Successfully activated service 'org.fedoraproject.Setroubleshootd'
May 29 18:28:34 localhost dbus-daemon: 'list' object has no attribute 'split'
May 29 18:28:34 localhost setroubleshoot: Plugin Exception restorecon_source
May 29 18:28:34 localhost setroubleshoot: SELinux is preventing /usr/sbin/cupsd from write access on the file printers.conf.O. For complete SELinux messages. run sealert -l ac547b3a-0ed3-4c09-943c-d11fce0a9e41
May 29 18:28:34 localhost python: SELinux is preventing /usr/sbin/cupsd from write access on the file printers.conf.O.#012#012***** Plugin catchall (100. confidence) suggests **************************#012#012If you believe that cupsd should be allowed write access on the printers.conf.O file by default.#012Then you should report this as a bug.#012You can generate a local policy module to allow this access.#012Do#012allow this access for now by executing:#012# grep cupsd /var/log/audit/audit.log | audit2allow -M mypol#012# semodule -i mypol.pp#012
Actually I got to admit that I have no idea what this is telling me. Maybe you could translate it for me. I suspect that it has something to do with the fact that the printer is a printer and scanner in one device and by deafualt it's loaded as a printer and trying to scan anything isnt able to switch it to the scan mode. I dont know if that makes any sense.
TBH SELinux is terra incognita for me. I know there can be some conflicts between USB drivers and CUPS, but this is something I never experienced myself, thus I have no details on this. Nor have I experience with CUPS locking up a multifunction device and denying access to SANE. You could shut down CUPS as troubleshooting measure and see if you get access to the scanner.
Even with cups deactivated (sudo service cups stop) scanimage issues "Device busy". Somehow cups is restarting itself. Because it starts running without using sudo service cups start. I really dont get, cause I really dont know which application could be blocking the scanner.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.