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.
I have a Brother MFC 240c Scanner, printer, copier, fax machine running with Ubuntu 7.10 using the Brother supplied drivers and installation instructions. The PC is a Dell Dimension 4600 P4 2.8 GHz, 2 GB RAM, 160 GB & 320 GB hard drives. The print function works great. The copy function is independent of the PC and I have not used the fax. The issue is with the scanning function.
SOMETIMES the scanning works great. I can invoke xsane and scan using the flat bed or sheet feeder. However, after doing an initial scan (or sometimes several successful scans) I get errors to the effect "Failed to start scanner: Error during device I/O" or "Failed to start scanner: Invalid argument"
Often exiting and restarting xsane will clear the problem for a couple more scans. Sometimes powering the scanner off and back on will clear it. Or, just waiting a while will clear the issue and I can again scan.
I have tried changing the USB cable to another port without success. I still have the intermittent problem. I have noticed that even when the scanning error is present I can print to the device.
sane-find-scanner gives me:
found USB scanner (vendor=0x04f9, product=0x01ab) at libusb:003:003
ken@taylor11ub:~$ scanimage -L gives me:
device `brother2:bus3;dev1' is a Brother MFC-240C USB scanner
I am not sure where to look or what to look for. Any help or suggestions appreciated.
1) are you inserting any other usb device during the troubles? if so you could look at creating persistent usb udev rules for the device.
2) I have a diff Multi function to you....I can run it as a gui or by the terminal....I suggest you run it by the terminal and see if any errors are showing up in the terminal
3) do you power this device on at boot up ....prior to boot up or after everything has loaded....try changing what you are doing....to see if you change its behaviour pls
4) I run my MFD as a normal user...so I have (dot) .sane which unpacks to xsane
do you have same? do any rc file within look funny?
5) my xsane reports to /var/log/syslog...and if I leave it off I can see an error (of course)
try posting those errors if not too large pls...or post them to a online storage site and link them ...I use www.ripway.com which is free if logs too big for those errors
Thanks for the reply aus9. I am not plugging in any other USB devices while using the scanner. In fact, the only other USB device I have attached is a UPS. I guess I could try with that unplugged. I have tried powering the MFC before and after booting. No apparent difference.
Recently I have been trying this device on a Ubuntu 8.04 upgrade. Could not even install the print capabilities on 8.0.4 so I reinstalled 7.10 and then the MFC and re-upgraded. The scanner went from scanning once to not scanning at all. I/O and invalid argument errors. A couple of times xsane seemed to "reboot" the MFC - sort of a power cycle process.
I will have a look at the logs etc. as you suggest. First let me see what else 8.04 has broken - and wait for some upgraded drivers from Brother. If all else fails I can run the MFC from within an XP virtual machine which I built for the purpose of running my old Visioneer scanner which would not run at all under Linux. I may also try a couple of other distros just for the heck of it.
I am running the MFC on Ubuntu 7.10 - working reasonably well and this is what I am seeing in the log
Quote:
Apr 27 10:55:11 taylor11ub kernel: [ 946.031594] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 10:55:12 taylor11ub kernel: [ 946.810212] usb 3-2: usbfs: interface 0 claimed by usblp while 'xsane' sets config #1
Apr 27 10:55:12 taylor11ub kernel: [ 946.810261] usb 3-2: usbfs: process 9838 (xsane) did not claim interface 1 before use
Apr 27 10:55:12 taylor11ub kernel: [ 947.438877] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
I scanned several pages until xsane threw a device I/O error. I did not see anything different in the log. I tried scanning several times more, got the same error and finally the MFC rebooted. I got the same block of log entries as when I manually power it off and on. The log for that evolution is as follows:
Quote:
Apr 27 11:15:20 taylor11ub kernel: [ 2152.704538] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:21 taylor11ub kernel: [ 2154.113487] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:22 taylor11ub kernel: [ 2155.323035] usb 3-2: USB disconnect, address 5
Apr 27 11:15:22 taylor11ub kernel: [ 2155.324346] /build/buildd/linux-source-2.6.22-2.6.22/drivers/usb/class/usblp.c: usblp0: removed
Apr 27 11:15:22 taylor11ub hal_lpadmin: remove
Apr 27 11:15:22 taylor11ub hal_lpadmin: Found configured printer: MFC240C
Apr 27 11:15:22 taylor11ub hal_lpadmin: Disabled printer MFC240C, as the corresponding device was unplugged or turned off
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.904345] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial_printer_noserial').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.906423] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.917216] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if1').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.924251] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host_scsi_device_lun0_scsi_generic').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.933240] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host_scsi_device_lun0').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.934960] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.942262] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_usbraw').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.947695] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.951928] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562').
Apr 27 11:15:22 taylor11ub NetworkManager: <debug> [1209309322.957227] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/storage_serial_Brother_MFC_240C_BROJ7F408562_0_0').
Apr 27 11:15:36 taylor11ub kernel: [ 2169.443334] usb 3-2: new full speed USB device using uhci_hcd and address 6
Apr 27 11:15:37 taylor11ub kernel: [ 2169.616330] usb 3-2: configuration #1 chosen from 1 choice
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.143684] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562').
Apr 27 11:15:37 taylor11ub kernel: [ 2169.623258] /build/buildd/linux-source-2.6.22-2.6.22/drivers/usb/class/usblp.c: usblp0: USB Bidirectional printer dev 6 if 0 alt 0 proto 2 vid 0x04F9 pid 0x01AB
Apr 27 11:15:37 taylor11ub kernel: [ 2169.623499] scsi8 : SCSI emulation for USB Mass Storage devices
Apr 27 11:15:37 taylor11ub kernel: [ 2169.623652] usb-storage: device found at 6
Apr 27 11:15:37 taylor11ub kernel: [ 2169.623655] usb-storage: waiting for device to settle before scanning
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.223207] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial').
Apr 27 11:15:37 taylor11ub hal_lpadmin: add
Apr 27 11:15:37 taylor11ub hal_lpadmin: URIs: ['usb://Brother/MFC-240C', 'hal:///org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial_printer_noserial']
Apr 27 11:15:37 taylor11ub hal_lpadmin: HPLIP Fax URIs: None
Apr 27 11:15:37 taylor11ub hal_lpadmin: Not adding printer: MFC240C already exists
Apr 27 11:15:37 taylor11ub hal_lpadmin: Re-enabling printer MFC240C
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.407260] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial_printer_noserial').
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.439286] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if1').
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.491273] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2').
Apr 27 11:15:37 taylor11ub NetworkManager: <debug> [1209309337.568222] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_usbraw').
Apr 27 11:15:38 taylor11ub kernel: [ 2170.680804] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:39 taylor11ub kernel: [ 2172.093993] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:41 taylor11ub kernel: [ 2173.507260] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:42 taylor11ub kernel: [ 2174.615788] usb-storage: device scan complete
Apr 27 11:15:42 taylor11ub kernel: [ 2174.649728] scsi 8:0:0:0: Direct-Access Brother MFC-240C 1.00 PQ: 0 ANSI: 2
Apr 27 11:15:42 taylor11ub kernel: [ 2174.690684] sd 8:0:0:0: [sdc] Attached SCSI removable disk
Apr 27 11:15:42 taylor11ub kernel: [ 2174.690736] sd 8:0:0:0: Attached scsi generic sg3 type 0
Apr 27 11:15:42 taylor11ub NetworkManager: <debug> [1209309342.266440] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host').
Apr 27 11:15:42 taylor11ub NetworkManager: <debug> [1209309342.268431] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host_scsi_device_lun0').
Apr 27 11:15:42 taylor11ub NetworkManager: <debug> [1209309342.318468] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_4f9_1ab_BROJ7F408562_if2_scsi_host_scsi_device_lun0_scsi_generic').
Apr 27 11:15:42 taylor11ub kernel: [ 2174.915538] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:42 taylor11ub NetworkManager: <debug> [1209309342.482211] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/storage_serial_Brother_MFC_240C_BROJ7F408562_0_0').
Apr 27 11:15:43 taylor11ub kernel: [ 2176.329346] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:45 taylor11ub kernel: [ 2177.738189] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
Apr 27 11:15:46 taylor11ub kernel: [ 2179.146605] usb 3-2: usbfs: interface 0 claimed by usblp while 'brscan-skey-0.2' sets config #1
so its gets messier but since you have had no luck its
turn off brother
download the lpr and cups wrapper drivers from brother
disable selinux ....in fact turn off the net to be safe
use your package manager to remove the current cups and lpr
install lpr with the ack of the brother link advice
install brother
reboot
turn on brother and see what happens
Thanks aus9. At first glance these items seem to relate only to printing. My MFC is printing OK at least as far as I have tested it. I looked at their scanner FAQ and found an item related to "Error during device I/O". I have already made the specified changes to /etc/udev/rules.d/45-libsane.rules. Otherwise I don't think I would have been able to scan at all.
According to their FAQ I need to restart the OS to read the rules. If the OS somehow forgot the rule and thus stopped scanning I would not expect it to relearn the rule until it was rebooted. However, if I restart xsane I can (usually) again scan.
I guess I can disable selinux and try installing all the scanner stuff and see what happens.
Well, I disabled selinux and installed the Brother scanning drivers for the MFC 240c. I did not bother with the printing drivers for the moment. I then re-enabled selinux and fired up xsane. Works a whole lot better. Not 100% but a couple of random I/O errors were overcome by retrying the scan. I was so pleased I forgot most of what I had figured out about xsane and how to set the configuration to my liking.
Thanks again aus9. I guess I owe you a Fosters for this one!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.