11

I'm new to Linux and installed Ubuntu 15.10 few days ago. I can successfully print on my Canon i-SENSYS MF4890dw, but when trying to scan with Xsane I get the following:

Failed to open device 'pixma:MF4800_10.237.93.145': invalid argument

As I have read some feeds from other similar threads, I've tried on Xterm:

scanimage -T 

which returns:

scanimage: open of device pixma:MF4800_10.237.93.145 failed: Invalid argument

and

uname -r

which returns 4.2.0-25-generic.

cat
  • 1,632
  • 1
  • 24
  • 47
eugeniosql
  • 111
  • 1
  • 1
  • 4
  • I've found a way out: I've given roots privilege to the application with gksudo. So I can now scan, but I wonder whether this is the rights approach. Shall I give roots privileges to all the apps which have to access the network? – eugeniosql Jan 24 '16 at 19:51

4 Answers4

5

There was a bug in the scanning library that affected wireless scanning using some devices. Upgrade libsane to 1.0.26 or newer. If it isn't available in the software centre, install it from this ppa:

sudo add-apt-repository ppa:rolfbensch/sane-git
sudo apt-get update
sudo apt-get dist-upgrade
3

We had similar problems with our Canon scanner. Installing updated versions of xsane and its libraries from the SANE daily ppa got us mostly functional, although the document feeder still does not work.

Another problem we encountered was that the ufw firewall was blocking access to the networked scanner. If you are using ufw and the scanner is networked, try disabling ufw and trying a scan again. If this works, it is pretty easy to allow the scanner through ufw so you don't have to turn it off completely.

Organic Marble
  • 22,803
  • 12
  • 65
  • 118
  • Thank you for you reply. UFW is disabled ("sudo ufw status verbose" returned "inactive"). I have taken onboard the PPA ("sudo add-apt-repository ppa:rolfbensch/sane-git") and performed the update ("sudo apt-get update"). But I still have the same error message from XSane. Also SYMPLE SCAN returns "Unable to connect to scanner" even if my scanner is displyed as unique option if I press on "Change Scanner". ANy other tip? – eugeniosql Jan 22 '16 at 20:08
  • I have another request. Can you tell me how to disable the 3rd parties repositories? It looks like the installation of the above mentioned ppa causes some crashes in the system. There is a window popping up to ask to disable "3rd parties repositories" and run on a terminal "apt-get install -f" – eugeniosql Jan 22 '16 at 20:42
  • Assuming you have Ubuntu 14.04, you can type "Software" into the Dash, and an icon with a world and box will appear called "Software and Updates". If you click on that, you will get a dialog box with taps along the top. Click on the Other Software tab and scroll down to the repos you want to get rid of. Uncheck their boxes and click the Close button. – Organic Marble Jan 22 '16 at 21:41
  • *tabs, not taps – Organic Marble Jan 22 '16 at 21:41
  • Actually I'm on 15.10 but I find out. Thank you for having tried to solve my issue! – eugeniosql Jan 23 '16 at 14:07
  • 1
    @eugeniosql maybe you forgot to `sudo apt-get upgrade` after you did `sudo apt-get update` ? – cipher Apr 18 '17 at 08:32
3

This is usually a permissions issue.

Use lsusb to see what bus and dev your printer/scanner is on (assuming it's connected via usb).

$ lsusb
Bus 003 Device 006: ID 0400:0132 Brother Industries, Ltd

This device is on Bus 003, device 006... which corresponds to this file:

$ ls -l /dev/bus/usb/003/006
crw-rw-r-- 1 root lp   189, 261 Jan 21 17:18 006

Notice the group is 'lp'.

Add yourself to the 'lp' group using:

sudo usermod -a -G lp {your-username-goes-here}

Log out and back in... try xsane.

Zanna
  • 69,223
  • 56
  • 216
  • 327
Jay Marm
  • 141
  • 4
0

Sometimes, a bad USB cable can cause this "invalid argument" error. Try swapping out your cable with a known-good one.

Kaz Wolfe
  • 33,802
  • 20
  • 111
  • 168
MartijnvdB
  • 131
  • 2