Author Topic: Sane driving me insane  (Read 6079 times)

0 Members and 1 Guest are viewing this topic.

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #45 on: April 25, 2013, 04:22:13 pm »
When saned has the correct permissions .. the output after running thise 3 commands will be something like:-

Quote
device `hpaio:/usb/ScanMagic_1200_UB_Plus_Scanner?serial=CN0CQ3B1DH05HX' is a ScanMagic_1200_UB_Plus_Scanner

Mine didn't work till I got the permissions right .. then it did :)
(but I didn't have to add a udev rule .. just added it to the lp group)

So this is all about the udev rule, and getting permission for saned to access the scanner.

[EDIT]

The problem may be that the PC needs restarting .. or the scanner replugging before the udev rules are picked up.

--
« Last Edit: April 25, 2013, 04:25:33 pm by Mark Greaves (PCNetSpec) »
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #46 on: April 25, 2013, 04:28:36 pm »
Ok Mark we'll wait till I get home and I'll restart the PC's and try again




Thanks again for your help so far :)




Graeme
If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #47 on: April 25, 2013, 04:31:53 pm »
OK, catch ya later then :)
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #48 on: April 25, 2013, 04:35:41 pm »
Slightly off topic

Quote
Ever considered adding a REALLY strict static password to Teamviewer, then setting it to autostart at bootup

How do you know I don't already have a strict password ? :)

Quote
then setting it to autostart at bootup

Autostarting at boot would be a good idea but it wouldn't have helped as in our situation today as I have a slow system fan (which I'm too lazy to fix) which causes the boot to halt and i have to press F2 to continue


Graeme

If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #49 on: April 25, 2013, 05:17:52 pm »
How do you know I don't already have a strict password ? :)

I don't .. I was just suggesting that if you're going to set a static password (as opposed to the deault which changes every time you start teamviewer) and set it to autostart, a strong password would be advisable.

Future readers/searchers may need their attention drawn to that ;)
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline SeZo

  • Hero Member
  • *****
  • Posts: 1425
  • Karma: 118
  • Gender: Male
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #50 on: April 25, 2013, 06:37:14 pm »
Quote
No scanners were identified. If you were expecting something different,
check that the scanner is plugged in, turned on and detected by the
sane-find-scanner tool (if appropriate). Please read the documentation
which came with this software (README, FAQ, manpages).

You could try to locate your scanner with:
Code: [Select]
sane-find-scanner -v
This does not guarantee that it will work with sane but worth to try.

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #51 on: April 25, 2013, 06:53:37 pm »
@ SeZo

the scanner is discovered by
scanimage -L
and
sudo scanimage -L

But NOT when using a shell owned by saned

So it's a saned permission issue...... saned doesn't appear to have permission to use the scanner  ???



@ Emegra

What's the output from:
Code: [Select]
groups

--
« Last Edit: April 25, 2013, 07:10:00 pm by Mark Greaves (PCNetSpec) »
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline SeZo

  • Hero Member
  • *****
  • Posts: 1425
  • Karma: 118
  • Gender: Male
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #52 on: April 25, 2013, 07:11:20 pm »
This thread suggest that there is a permission bug (which resurfaced again) with sane:
https://bugs.launchpad.net/ubuntu/+source/sane-backends/+bug/270185
With possible workaround.

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #53 on: April 25, 2013, 07:14:06 pm »
Hi Guys

Once more to the breech

I've just rebooted, do you want the output from groups before we try and see if saned can see the scanner ?
If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

Offline SeZo

  • Hero Member
  • *****
  • Posts: 1425
  • Karma: 118
  • Gender: Male
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #54 on: April 25, 2013, 07:21:27 pm »
Quote
I've just rebooted, do you want the output from groups before we try and see if saned can see the scanner ?

groups and then try it ;D

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #55 on: April 25, 2013, 07:25:42 pm »
Looking good, but I still can't connect with the client

Code: [Select]
graeme@Linux3 ~ $ groups
graeme adm lp cdrom sudo dip plugdev lpadmin sambashare scanner saned
graeme@Linux3 ~ $ sudo -s
[sudo] password for graeme:
Linux3 ~ # su -s /bin/bash saned
saned@Linux3 /home/graeme $ scanimage -L
device `gt68xx:libusb:003:002' is a Mustek BearPaw 1200 CU flatbed scanner
device `net:127.0.0.1:gt68xx:libusb:003:002' is a Mustek BearPaw 1200 CU flatbed scanner
device `net:localhost:gt68xx:libusb:003:002' is a Mustek BearPaw 1200 CU flatbed scanner
saned@Linux3 /home/graeme $
If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #56 on: April 25, 2013, 07:28:41 pm »
OK, is saned running?
Code: [Select]
sudo service saned status

[EDIT]

What happens now if you start xsane on the SERVER ? .. does it offer you 3 scanners to choose from ?

if so, select one of these 2

device `net:127.0.0.1:gt68xx:libusb:003:002' is a Mustek BearPaw 1200 CU flatbed scanner
device `net:localhost:gt68xx:libusb:003:002' is a Mustek BearPaw 1200 CU flatbed scanner

ie. NOT the USB one .. then try scanning something .. does it scan ?

--
« Last Edit: April 25, 2013, 07:36:43 pm by Mark Greaves (PCNetSpec) »
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #57 on: April 25, 2013, 07:48:06 pm »
Code: [Select]
graeme@Linux3 ~ $ sudo service saned status
[sudo] password for graeme:
saned is running.
graeme@Linux3 ~ $


Quote
What happens now if you start xsane on the SERVER ? .. does it offer you 3 scanners to choose from ?

Yes and it starts and scans with both the scanners you listed  :)
If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13193
  • Karma: 321
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Sane driving me insane
« Reply #58 on: April 25, 2013, 07:53:30 pm »
GREAT .. now we're getting somewhere :)

On the server, can you send the contents of:
Code: [Select]
gedit /etc/sane.d/saned.conf
and
Code: [Select]
gedit /etc/sane.d/net.conf

and can you check the IP of the server and say what it is.
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Emegra

  • Hero Member
  • *****
  • Posts: 2392
  • Karma: 53
  • Gender: Male
  • Devilishly Handsome
    • View Profile
    • Awards
Re: Sane driving me insane
« Reply #59 on: April 25, 2013, 07:58:52 pm »
Code: [Select]
# saned.conf
# Configuration for the saned daemon

## Daemon options
# Port range for the data connection. Choose a range inside [1024 - 65535].
# Avoid specifying too large a range, for performance reasons.
#
# ONLY use this if your saned server is sitting behind a firewall. If your
# firewall is a Linux machine, we strongly recommend using the
# Netfilter nf_conntrack_sane connection tracking module instead.

# data_portrange = 10000 - 10100


## Access list
192.168.2.0/24
# A list of host names, IP addresses or IP subnets (CIDR notation) that
# are permitted to use local SANE devices. IPv6 addresses must be enclosed
# in brackets, and should always be specified in their compressed form.
#
# The hostname matching is not case-sensitive.

#scan-client.somedomain.firm
#192.168.0.1
#192.168.0.1/29
#[2001:7a8:185e::42:12]
#[2001:7a8:185e::42:12]/64
192.168.255.0/24

# NOTE: /etc/inetd.conf (or /etc/xinetd.conf) and
# /etc/services must also be properly configured to start
# the saned daemon as documented in saned(8), services(4)
# and inetd.conf(4) (or xinetd.conf(5)).

Code: [Select]
# This is the net backend config file.

## net backend options
# Timeout for the initial connection to saned. This will prevent the backend
# from blocking for several minutes trying to connect to an unresponsive
# saned host (network outage, host down, ...). Value in seconds.
# connect_timeout = 60

## saned hosts
localhost
 127.0.0.1
# Each line names a host to attach to.
# If you list "localhost" then your backends can be accessed either
# directly or through the net backend.  Going through the net backend
# may be necessary to access devices that need special privileges.
# localhost
If you can keep your head while all around are losing theirs, then you're not quite grasping the situation

 


SimplePortal 2.3.3 © 2008-2010, SimplePortal