Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
By markush at 2010-12-02 17:04
In this tutorial I'll describe detailed which steps are necessary in order to use a scanner which is connected via USB to a Linux-computer from any other computer in the network (even Windows will work).
Software on the server (which is the computer where the scanner is installed) one has to install at least inetd (or xinetd) and sane. On any client there must be installed xsane or any sane-frontend (I'm using xsane)
Configuration for the server on the server one has to edit the /etc/saned.d/saned.conf file and insert the hosts which are allowed to use the scanner, one may insert the whole network, for example with a line.
Code:
192.168.2.0/24
When using the inetd daemon we edit the file /etc/inetd.conf and insert a line:
For an explanation please read the manpage for inetd.
When using xinetd one has to create a new file in the /etc/xinetd.d/ directory, we'll call the file saned:
Code:
# /etc/xinetd.d/saned
service sane-port
{
port = 6566
socket_type = stream
wait = no
user = daemon
group = daemon
}
After this configurations be sure to restart the daemon!
Configuration for the client on the client we'll have to edit the /etc/saned.d/net.conf file and insert the IP-adress of the server, please note that I tried it with the hostname of the server which failed.
Furthermore there is a file dll.conf in the /etc/saned directory, be sure that there is a line with the single word net in this file.
The permissions: every user which is permitted to use the scanner has to be member of the scanner group. If the scanning device is a multifunction/printer/scanner the user has also to be member of the lp group!
Now we may test our configuration. Using nmap we can check the service on the server.
Code:
Samsung ~ # nmap -p 6566 192.168.178.10
Starting Nmap 5.21 ( http://nmap.org ) at 2010-11-29 19:54 CET
Nmap scan report for srv-zuhause.home.local (192.168.178.10)
Host is up (0.0031s latency).
PORT STATE SERVICE
6566/tcp open unknown
MAC Address: xx:xx:xx:xx:xx:xx (xx Computer)
Nmap done: 1 IP address (1 host up) scanned in 0.23 seconds
Please note the line "6566/tcp open unknown", the port for saned is open.
Now on the client we may execute
Code:
scanimage -L
and if everything works we get informations about the device, for example:
Code:
markus@Samsung ~ $ scanimage -L
device `net:192.168.178.10:hpaio:/usb/PSC_1400_series?serial=CN619D724804DZ' is a Hewlett-Packard PSC_1400_series all-in-one.
There is a 32bit version of xsane for Windows available, with this one can also use the scanner from a Windows-client.
I've tested this with Slackware 13.1/inetd and as well with Gentoo/xinetd as Server and with Slackware 13.1, Gentoo, and Arch as clients.
Nice try. I can't get my KDE Neon to edit the file. Apparently it does not recognize kwrite or gedit in the terminal. I can get it to list the file (I note that my scanner is on 192.168.0.17 and the file recognizes 192.168.0.1 only). So I'm screwed until I learn how I'm supposed to edit the file (yes, I used sudo to gain root access).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.