[sane-devel] Net Client Not Contacting Server
c.a.cook at quantum-sci.com
Sun Sep 6 16:11:34 BST 2020
On 2020-09-05 22:57, Olaf Meeuwissen wrote:
> C. Cook writes:
>> On 2020-09-02 08:35, C. Cook wrote:
>>> Scanner is an Epson Perfection V370. I have IScan installed on server
>>> and client.
>>> Have saned running on the server, listening on ipv4 *:6566. scanimage
>>> -L does see the scanner.
>>> On the client in dll.conf I have all commented out except net. In
>>> net.conf I have:
> Does the scan-server hostname resolve?
>>> In dll.d there is iscan which contains:
> This is on the server, right? Because its the server that communicates
> with the device via the epkowa backend.
This is on the server. So maybe I don't even need net on the server.
>>> On the client when I run scanimage -L it does not see the scanner.
>>> When I run tcpdump on the client watching port 6566, and then do
>>> scanimage -L, tcpdump never sees 6566 anywhere. So the client is
>>> definitely not reaching out to the net for the server.
> The 6566 port is the target port on the server. You'd want to run
> tcpdump there if at all. Why don't you start saned in debug mode
> on the server to see what's going on?
> You can also enable debugging of the net backend on the client side
> SANE_DEBUG_NET=128 scanimage -L
# SANE_DEBUG_NET=128 scanimage -L
[sanei_debug] Setting debug level of net to 128.
[net] sane_init: authorize != null, version_code != null
[net] sane_init: SANE net backend version 1.0.14 (AF-indep+IPv6) from
[net] sane_init: Client has little endian byte order
[net] sane_init: searching for config file
[net] sane_init: connect timeout set to 30 seconds
[net] sane_init: trying to add scan-server
[net] add_device: adding backend scan-server
[net] add_device: error while getting address of host scan-server: Name
or service not known
[net] sane_init: trying to add localhost
[net] add_device: adding backend localhost
[net] add_device: backend localhost added
[net] sane_init: done reading config
[net] sane_init: evaluating environment variable SANE_NET_HOSTS
[net] sane_init: evaluating environment variable SANE_NET_TIMEOUT
[net] sane_init: done
[net] sane_get_devices: local_only = 0
[net] connect_dev: trying to connect to localhost
[net] connect_dev:  connection succeeded (IPv4)
[net] connect_dev: sanei_w_init
[net] connect_dev: net_init (user=carl, local version=1.0.3)
[net] connect_dev: argument marshalling error (Invalid argument)
[net] connect_dev: closing connection to localhost
[net] sane_get_devices: ignoring failure to connect to localhost
[net] sane_get_devices: finished (0 devices)
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).
[net] sane_exit: exiting
[net] sane_exit: closing dev 0x55c68f5c76d0, ctl=-1
[net] sane_exit: finished.
It should be connecting to localhost, but many years ago someone else
found that setting:
echo 0 > /proc/sys/net/ipv6/bindv6only
... and indeed sometimes the scanner does now show up on the client.
# scanimage -L
device `net:localhost:epkowa:interpreter:001:008' is a Epson (unknown
model) flatbed scanner
# scanimage -L
device `net:localhost:epkowa:interpreter:001:008' is a Epson Perfection
V370 Photo flatbed scanner
But when I try to use it it says, "scanimage: open of device
epkowa:interpreter:001:009 failed: Device busy"
At one point on the server I did manage to get one scan with scanimage
But with this ipv6 problem still existing after so many years it's
starting to look like this is so unstable I won't be able to hve a scanner.
>>> In dll.conf I have enabled epkowa along with net, but no change.
>>> No idea what I'm doing wrong.
>> No one has any idea?
> A few more things to check:
> - Is there a firewall between the client and server programs that block
There is, but I'm using a reverse SSH tunnel for 6566 so it bypasses the
firewalls with SSH.
> - Does the saned process on the server allow communication from your
> client (check /etc/hosts.allow and /etc/hosts.deny as well as your
Yes, all commented out in .allow and .deny, and in saned.conf:
> Hope this helps,
> Olaf Meeuwissen, LPIC-2 FSF Associate Member since 2004-01-27
> GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13 F43E B8A4 A88A F84A 2DD9
> Support Free Software https://my.fsf.org/donate
> Join the Free Software Foundation https://my.fsf.org/join
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the sane-devel