<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p><br>
</p>
<div class="moz-cite-prefix">On 2020-09-09 09:42, Ralph Little
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAFNXwePfNgc0GqWNZa7z1ZNOUoi8cLtDV_oHDJ9-JDbs6FmB=w@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">
<div>Hi,<br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Wed, Sep 9, 2020 at 8:39
AM C. Cook <<a href="mailto:c.a.cook@quantum-sci.com"
moz-do-not-send="true">c.a.cook@quantum-sci.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex"><br>
On 2020-09-09 07:31, Ralph Little wrote:<br>
> Hi,<br>
</blockquote>
<div> </div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left:1px solid
rgb(204,204,204);padding-left:1ex">
I did as Olaf suggested and "Name or service not known",
which doesn't<br>
make sense:<br>
<br>
# SANE_DEBUG_NET=128 scanimage -L<br>
[sanei_debug] Setting debug level of net to 128.<br>
[net] sane_init: authorize != null, version_code != null<br>
[net] sane_init: SANE net backend version 1.0.14
(AF-indep+IPv6) from<br>
sane-backends 1.0.27<br>
[net] sane_init: Client has little endian byte order<br>
[net] sane_init: searching for config file<br>
[net] sane_init: connect timeout set to 30 seconds<br>
[net] sane_init: trying to add scan-server<br>
[net] add_device: adding backend scan-server<br>
[net] add_device: error while getting address of host
scan-server: Name<br>
or service not known<br>
[net] sane_init: trying to add localhost<br>
[net] add_device: adding backend localhost<br>
[net] add_device: backend localhost added<br>
[net] sane_init: done reading config<br>
[net] sane_init: evaluating environment variable
SANE_NET_HOSTS<br>
[net] sane_init: evaluating environment variable
SANE_NET_TIMEOUT<br>
[net] sane_init: done<br>
[net] sane_get_devices: local_only = 0<br>
[net] connect_dev: trying to connect to localhost<br>
[net] connect_dev: [0] connection succeeded (IPv4)<br>
[net] connect_dev: sanei_w_init<br>
[net] connect_dev: net_init (user=carl, local version=1.0.3)<br>
[net] connect_dev: freeing init reply (status=Success,
remote version=1.0.3)<br>
[net] connect_dev: done<br>
[net] sane_get_devices: finished (0 devices)<br>
<br>
</blockquote>
<div> </div>
<div>So it looks from the trace that it is trying to
(unsuccessfully) resolve the scan-server host.</div>
<div>I would simplify this for the moment to just include the
IP address of scan-server in net.conf and try again.</div>
<div><br>
</div>
<div>I tried something similar here to see what we would
expect:<br>
<br>
[09:32:15.216089] [net] sane_init: searching for config file<br>
[09:32:15.216101] [net] sane_init: trying to add scan-server<br>
[09:32:15.216108] [net] add_device: adding backend
scan-server<br>
[09:32:15.218803] [net] add_device: error while getting
address of host scan-server: Temporary failure in name
resolution<br>
[09:32:15.218827] [net] sane_init: trying to add 10.1.40.6<br>
[09:32:15.218836] [net] add_device: adding backend 10.1.40.6<br>
[09:32:15.219301] [net] add_device: backend 10.1.40.6 added<br>
[09:32:15.219313] [net] sane_init: done reading config</div>
<div><br>
</div>
<div>In my net.conf I have:</div>
<div><br>
</div>
<div>#</div>
<div># Comments...<br>
</div>
<div>#<br>
</div>
<div>scan-server<br>
10.1.40.6</div>
<div><br>
</div>
<div>You can see that even though scan-server cannot be found,
it still adds the 10.1.40.6 host entry.</div>
<div><br>
</div>
<div>Alternatively, you can just specify the IP address in
SANE_NET_HOSTS env variable:</div>
<div><br>
</div>
<div>SANE_NET_HOSTS=10.1.60.4 SANE_DEBUG_NET=128 scanimage -L</div>
<div><br>
</div>
<div>.. and that IP address will be included in addition to
what is in net.conf.</div>
<div><br>
</div>
<div>Let us know what output you get. Hopefully that will give
us something to go on.<br>
</div>
<div><br>
</div>
<div>Cheers,</div>
<div>Ralph<br>
</div>
</div>
</div>
</blockquote>
<p>Changed my net.conf to:</p>
<p>scan-server<br>
127.0.0.1</p>
<p>Remember I'm using a reverse SSH tunnel to bring 6566 to the
client machine. I've used this method for years and know it
works. selinux is off on client and server, and the firewall
isn't involved on localhost. (CentOS 7.6) <br>
</p>
<p>Here's the traffic when I do the scanimage command:<br>
</p>
<p># tcpdump 'tcp port 6566' -i lo<br>
tcpdump: verbose output suppressed, use -v or -vv for full
protocol decode<br>
listening on lo, link-type EN10MB (Ethernet), capture size 262144
bytes<br>
10:19:50.050969 IP localhost.38946 > localhost.sane-port: Flags
[S], seq 1236909838, win 43690, options [mss 65495,nop,wscale 7],
length 0<br>
10:19:50.051014 IP localhost.sane-port > localhost.38946: Flags
[S.], seq 626504402, ack 1236909839, win 43690, options [mss
65495,nop,wscale 7], length 0<br>
10:19:50.051039 IP localhost.38946 > localhost.sane-port: Flags
[.], ack 1, win 342, length 0<br>
10:19:50.051407 IP localhost.38946 > localhost.sane-port: Flags
[P.], seq 1:18, ack 1, win 342, length 17<br>
10:19:50.051440 IP localhost.sane-port > localhost.38946: Flags
[.], ack 18, win 342, length 0<br>
10:19:50.063776 IP localhost.sane-port > localhost.38946: Flags
[P.], seq 1:9, ack 18, win 342, length 8<br>
10:19:50.063794 IP localhost.38946 > localhost.sane-port: Flags
[.], ack 9, win 342, length 0<br>
10:19:50.063868 IP localhost.38946 > localhost.sane-port: Flags
[P.], seq 18:22, ack 9, win 342, length 4<br>
10:19:50.070087 IP localhost.sane-port > localhost.38946: Flags
[P.], seq 9:21, ack 22, win 342, length 12<br>
10:19:50.070248 IP localhost.38946 > localhost.sane-port: Flags
[P.], seq 22:26, ack 21, win 342, length 4<br>
10:19:50.070287 IP localhost.38946 > localhost.sane-port: Flags
[F.], seq 26, ack 21, win 342, length 0<br>
10:19:50.073319 IP localhost.sane-port > localhost.38946: Flags
[F.], seq 21, ack 27, win 342, length 0<br>
10:19:50.073346 IP localhost.38946 > localhost.sane-port: Flags
[.], ack 22, win 342, length 0</p>
<p>I didn't see any traffic when not specifying the interface, so
apparently in that case lo is ignored. But now I see attempts.<br>
</p>
<p>I changed net.conf to 127.0.0.1 instead of localhost and:<br>
</p>
<p># SANE_DEBUG_NET=128 scanimage -L<br>
[sanei_debug] Setting debug level of net to 128.<br>
[net] sane_init: authorize != null, version_code != null<br>
[net] sane_init: SANE net backend version 1.0.14 (AF-indep+IPv6)
from sane-backends 1.0.27<br>
[net] sane_init: Client has little endian byte order<br>
[net] sane_init: searching for config file<br>
[net] sane_init: connect timeout set to 30 seconds<br>
[net] sane_init: trying to add scan-server<br>
[net] add_device: adding backend scan-server<br>
[net] add_device: error while getting address of host scan-server:
Name or service not known<br>
[net] sane_init: trying to add 127.0.0.1<br>
[net] add_device: adding backend 127.0.0.1<br>
[net] add_device: backend 127.0.0.1 added<br>
[net] sane_init: done reading config<br>
[net] sane_init: evaluating environment variable SANE_NET_HOSTS<br>
[net] sane_init: evaluating environment variable SANE_NET_TIMEOUT<br>
[net] sane_init: done<br>
[net] sane_get_devices: local_only = 0<br>
[net] connect_dev: trying to connect to 127.0.0.1<br>
[net] connect_dev: [0] connection succeeded (IPv4)<br>
[net] connect_dev: sanei_w_init<br>
[net] connect_dev: net_init (user=carl, local version=1.0.3)<br>
[net] connect_dev: freeing init reply (status=Success, remote
version=1.0.3)<br>
[net] connect_dev: done<br>
[net] sane_get_devices: finished (0 devices)<br>
<br>
No scanners were identified. If you were expecting something
different,<br>
check that the scanner is plugged in, turned on and detected by
the<br>
sane-find-scanner tool (if appropriate). Please read the
documentation<br>
which came with this software (README, FAQ, manpages).<br>
[net] sane_exit: exiting<br>
[net] sane_exit: closing dev 0x55f2484331e0, ctl=3<br>
[net] sane_exit: finished.</p>
<p><br>
</p>
# SANE_NET_HOSTS=127.0.0.1 SANE_DEBUG_NET=128 scanimage -L<br>
[sanei_debug] Setting debug level of net to 128.<br>
[net] sane_init: authorize != null, version_code != null<br>
[net] sane_init: SANE net backend version 1.0.14 (AF-indep+IPv6)
from sane-backends 1.0.27<br>
[net] sane_init: Client has little endian byte order<br>
[net] sane_init: searching for config file<br>
[net] sane_init: connect timeout set to 30 seconds<br>
[net] sane_init: trying to add scan-server<br>
[net] add_device: adding backend scan-server<br>
[net] add_device: error while getting address of host scan-server:
Name or service not known<br>
[net] sane_init: trying to add 127.0.0.1<br>
[net] add_device: adding backend 127.0.0.1<br>
[net] add_device: backend 127.0.0.1 added<br>
[net] sane_init: done reading config<br>
[net] sane_init: evaluating environment variable SANE_NET_HOSTS<br>
[net] sane_init: trying to add 127.0.0.1<br>
[net] add_device: adding backend 127.0.0.1<br>
[net] add_device: already in list<br>
[net] sane_init: evaluating environment variable SANE_NET_TIMEOUT<br>
[net] sane_init: done<br>
[net] sane_get_devices: local_only = 0<br>
[net] connect_dev: trying to connect to 127.0.0.1<br>
[net] connect_dev: [0] connection succeeded (IPv4)<br>
[net] connect_dev: sanei_w_init<br>
[net] connect_dev: net_init (user=carl, local version=1.0.3)<br>
[net] connect_dev: freeing init reply (status=Success, remote
version=1.0.3)<br>
[net] connect_dev: done<br>
[net] sane_get_devices: finished (0 devices)<br>
<br>
No scanners were identified. If you were expecting something
different,<br>
check that the scanner is plugged in, turned on and detected by the<br>
sane-find-scanner tool (if appropriate). Please read the
documentation<br>
which came with this software (README, FAQ, manpages).<br>
[net] sane_exit: exiting<br>
[net] sane_exit: closing dev 0x55a24edeb1e0, ctl=3<br>
<p>[net] sane_exit: finished</p>
<p><br>
</p>
<p># tcpdump 'tcp port 6566' -i lo</p>
<p>10:24:05.641919 IP localhost.38972 > localhost.sane-port:
Flags [S], seq 677410379, win 43690, options [mss 65495,nop,wscale
7], length 0<br>
10:24:05.641970 IP localhost.sane-port > localhost.38972: Flags
[S.], seq 1312293621, ack 677410380, win 43690, options [mss
65495,nop,wscale 7], length 0<br>
10:24:05.641997 IP localhost.38972 > localhost.sane-port: Flags
[.], ack 1, win 342, length 0<br>
10:24:05.642549 IP localhost.38972 > localhost.sane-port: Flags
[P.], seq 1:18, ack 1, win 342, length 17<br>
10:24:05.642571 IP localhost.sane-port > localhost.38972: Flags
[.], ack 18, win 342, length 0<br>
10:24:05.660806 IP localhost.sane-port > localhost.38972: Flags
[P.], seq 1:9, ack 18, win 342, length 8<br>
10:24:05.660838 IP localhost.38972 > localhost.sane-port: Flags
[.], ack 9, win 342, length 0<br>
10:24:05.660988 IP localhost.38972 > localhost.sane-port: Flags
[P.], seq 18:22, ack 9, win 342, length 4<br>
10:24:05.667069 IP localhost.sane-port > localhost.38972: Flags
[P.], seq 9:21, ack 22, win 342, length 12<br>
10:24:05.667238 IP localhost.38972 > localhost.sane-port: Flags
[P.], seq 22:26, ack 21, win 342, length 4<br>
10:24:05.667278 IP localhost.38972 > localhost.sane-port: Flags
[F.], seq 26, ack 21, win 342, length 0<br>
10:24:05.671261 IP localhost.sane-port > localhost.38972: Flags
[F.], seq 21, ack 27, win 342, length 0<br>
10:24:05.671287 IP localhost.38972 > localhost.sane-port: Flags
[.], ack 22, win 342, length 0</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
</body>
</html>