[sane-devel] improve scanbd for Debian

Rolf Leggewie foss at rolf.leggewie.biz
Wed Dec 17 08:47:31 UTC 2014


On 12.12.2014 13:58, Wilhelm wrote:
> Be sure that scanbd uses the correct location of libsane config files
> (see ReadMe). In most cases this will be a seperate directory (e.g.
> /etc/scanbd) where all configs and dll.conf are. This dll.conf must not
> contain the net-backend.
> 
> On the other hand the standard libsane config location (/etc/sane) has
> to contain a dll.conf with only the net backend.
> 
> I changed trunk to include an additional debug output to log the env-var
> SANE_CONFIG_DIR. Please check the startup-script if the right dir ist
> set ...

SANE_CONFIG_DIR is set to /etc/scanbd.  The dll.conf files were not set
up according to above requirements but when I changed them that way
everything stopped working, including scanbd from the command line or
even "scanimage -L".  sane-find-scanner would continue to find the
device, though.

Before I attempted to change things, /etc/scanbd/dll.conf contained ONLY
the net backend and /etc/sane.d/dll.conf contained a whole bunch of
backends including genesys and net.

I've managed to get /etc/scanbd/dll.conf to contain ONLY the genesys
backend (dropped the net backend) without breaking anything that was
previously working.  Now it's on to get saned to work over the network
which I remember from a few years ago when I did this for actually
scanning across the LAN to be a horrible config nightmare.

I will need to look into how to make that part work as expected and then
I will need to figure out how to make sure that the Debian users have a
proper setup.  This will be complicated since it involves the
configuration files for a separate package.

On 12.12.2014 15:32, Simon Matter wrote:
>> Given that you were unable to see any difference I started a re-run and
>> inserted some markers into syslog with the logger command to make sure I
>> will be able to gather what happened when this time.  From what I
>> understand now, it seems that the scanner is indeed NOT recognized.  How
>> can that come about, especially given that on a call from the
>> command-line things work just fine with the same configuration?
> 
> That sounds like a kind of permission problem. Is there something like
> udev granting access to the device for locally logged in users which does
> not happen when started iva init?

Simon, permissions problem was my first thought as well.  But I had run
a few tests already and kind of ruled that out.  This included setting
user and group in scanbd.conf to root.root.  I verified with ps that
scanbd was indeed running as the root user but even then the buttons did
not trigger a reaction.

When I call scanbd from the command line the script does not switch to
the saned user.  It only does this (for understandable reasons) when
called as "sudo scanbd -f".  But even then, the buttons work.




More information about the sane-devel mailing list