- Introduction
- About this tutorial
- Assumptions
- Setting up SANE
- Step 1: Installing sane
- Step 2: Test your scanner
- Manual Scanner Installation
- Installing Network Scanners
- Scanners with AirScan Support
- Scanners with their own SANE servers
- Scanners with SANE backends
- Sharing your scanner with SANE
- Third Party Drivers
- Brother Scanners
- HP Scanners
- Samsung Scanners
- Sane linux по сети
- Сканирование документа по сети
- Настройка сервера для сканирования по сети
- Настройка клиента для сканирования по сети
Introduction
SANE (Scanner Access Now Easy) is the linux way of scanning. sane supports a great many scanners, and the community around SANE adds support for more scanners all the time. By and large, most supported scanners are plug and play simple (plug them in and your ready to scan). However, some scanners will require manual installation (see the sane Troubleshooting guide for help with manual installation).
About this tutorial
This tutorial will walk you through the basic set up of sane with plug and play scanners.
Assumptions
- This set up assumes that we are on a small home or office network and are behind a firewall.
- Our LAN is an IP4 network on subnet 192.168.0.0/24 (192.168.0.0 — 192.168.0.255)
- Our Ubuntu box is 192.168.0.23
- Our USB scanner is located at libusb:001:003
- Our SCSI scanner is at /dev/sg1
- Our network scanner is at 192.168.0.15
- Our scanner uses the example backend (example-backend)
Setting up SANE
Step 1: Installing sane
Sane should be installed as a base package in Ubuntu 11.04 and later. You can run the following command to install it (if it’s already installed, it will do nothing):
apt-get install sane sane-utils libsane-extras xsane
This will also install the xsane front end. Note that some scanners will require other packages to be installed. Those are covered in the sane Troubleshooting guide.
Step 2: Test your scanner
Run following command to test your scanner:
Applications > Graphics > XSane
You should see a dialog for scanning from your scanner. If SANE says that it can’t find the scanner, you will need to do a manual installation.
Manual Scanner Installation
Most of the time, the back-end for your scanner will be enabled by default. For some scanners, you will need to enable it manually. This usually involves enabling the back-end, and then adding your scanner to it.
For detailed instructions on manual installation, see the Ubuntu SANE Troubleshooting guide.
Installing Network Scanners
Many network scanners work with sane in one of two ways. The scanner can have its own sane server, or it can be supported by a backend.
Scanners with AirScan Support
Most modern scanners come with support for either Apple AirScan / AirPrint scanning (the official protocol name is «eSCL») OR Microsoft WSD, aka «Web Services for Devices».
These are both «driverless» scanning protocols and SANE supports both of these protocols with its sane-escl (eSCL only)and AirScan (eSCL and WSD) backends.
Both backends support network and USB scanners.
Scanners with their own SANE servers
Scanners with their own SANE server, as well as scanners connected to a computer running the saned service can be easily added to other computers on the network by enabling the NET backend and adding the servers IP address in the net.conf file.
1. To enable the net backend, edit the file /etc/sane.d/dll.conf by running the following command:
sudo gedit /etc/sane.d/dll.conf
Within that file, you need to uncomment the NET backend. In our case, change the line that reads
2. We need to add our server or servers to the /etc/sane.d/net.conf. You can edit that file as root using this command:
sudo gedit /etc/sane.d/net.conf
3. Add your SANED server address as an IP4, IP6, hosts or DNS resolvable name
192.168.0.15 ::1 localhost scan-server.office.lan
Scanners with SANE backends
SANE Backends are available for a number of network scanners. In general, all these need is to specify the protocol, address and port of your server.
1. Our example backend configuration file is /etc/sane.d/example.conf. You can edit that file as root using this command:
sudo gedit /etc/sane.d/example.conf
3. Find the line that reads:
and after it add the protocol, address and port of your network server. In our case, its
4. After you have added that line, save the file and close gedit.
Sharing your scanner with SANE
SANE allows you to easily share scanners across a network. To set up the sharing of your scanner using saned, see [https://help.ubuntu.com/community/sane.d%20tutorial]
Third Party Drivers
Many of the most popular scanners require the installation of third-party drivers.
Brother Scanners
Brother offers proprietary SANE drivers for its family of network scanners and multi-function devices.
To install, visit [http://support.brother.com/g/s/id/linux/en/download_scn.html] and download the proper driver for your scanner (brscan, brscan2, brscan3 or brscan4) and your computer (32 or 64 bit) to your desktop. NOTE: You need the 64 bit .deb version!
Run the following command to install the driver you just downloaded (note: the example below is for the brscan2 package. You will have to change the file name to match what you downloaded)
dpkg -i --force-all brscan2-0.2.4-0.i386.deb
After you have installed the scanner driver, you need to run the Brother SANE Configuration tool. When you run that tool, you need to append the device name (what you want to call it), the model number and the ip address of the scanner. In the example below, we are using the «brsaneconfig2» tool, we calling the scanner «MyScanner», the model we are installing is the MFC-660CN and the IP address is 192.168.0.15.
brsaneconfig2 -a name=MyScanner model=MFC660CN ip=192.168.0.15
NOTE: One issue that confuses a lot of users is the difference between brscan, brscan2, brscan3, brscan4 and brscan5. Each of these tools supports a different set of scanners, and you need to download the appropriate package for your scanner. Because it is possible to install many different scanners, you need to run the proper version of the brsaneconfig tool. If your scanner is supported by the brscan3 tool, you will need to run the brsaneconfig3 tool to configure it.
NOTE: Many older Brother Scanners (brscan, brscan2, brscan3) will need some manual configuration. See the Ubuntu SANE Troubleshooting guide for specific instructions on troubleshooting these scanners using the symlink and udev rules.
HP Scanners
The majority of HP scanners are supported by the hplip project. Setting up an HP scanner can be done using the following command:
This wizard will set up your scanner for use with SANE.
Samsung Scanners
Samsung scanner users are advised to install drivers via the The Samsung Unified Linux Driver Repository. See [http://www.bchemnet.com/suldr/index.html] for information on the SULDR project.
sane (последним исправлял пользователь 5g3-steven-7tv 2020-10-28 17:20:13)
The material on this wiki is available under a free license, see Copyright / License for details
You can contribute to this wiki, see Wiki Guide for details
Sane linux по сети
на сервере:
apt-get install sane
# настраиваем до работающего локального scanimage -L по документации
apt-get install sane-server
vim /etc/xinetd.d/sane # добавляем only_from = 127.0.0.1 на.ша.сет.ка/маска
chkconfig sane on
chkconfig xinetd on
service xinetd restart
Добавить заметку |
Версия для печати |
Последние заметки |
— 18.04 Перевод шифрованного раздела на LUKS2 и более надёжную функцию формирования ключа |
— 31.03 Пример правил nftables с реализацией port knoсking для открытия доступа к SSH |
— 27.02 Обновление сертификатов oVirt |
— 20.11 Решение проблемы со шрифтами в Steam после выставления времени после 2038 года |
— 18.11 Раскладка клавиатуры для ввода символов APL |
— 10.09 Настройка СУБД Postgresql для аутентификации пользователей через Active Directory |
— 09.09 Настройка СУБД PostgreSQL 13 под управлением Pacemaker/Corosync в Debian 11 |
— 08.09 Создание виртуальных машин с помощью Qemu KVM |
— 25.07 Создание программ под SynapseOS |
— 24.07 Случайная задержка в shell-скрипте, выполняемом из crontab (без башизмов) |
RSS | Следующие 15 записей >> |
Сканирование документа по сети
В данной статье рассмотрен вариант когда для сканирования по сети используется сервер сканирования, т.е к данному серверу подключен сканер, а клиенты по локальной сети подключаются к сканер-серверу и запускают сканирование.
Настройка сервера для сканирования по сети
1) установить все пакеты sane:
для РЕД ОС версии 7.1 или 7.2:
yum install sane-backends-daemon sane-frontends
для РЕД ОС версии 7.3 и старше:
dnf install sane-backends-daemon sane-frontends
2) Установить xinetd:
для РЕД ОС версии 7.1 или 7.2:
для РЕД ОС версии 7.3 и старше:
3) вписать подсеть которая может сканировать, в нашем случае — 192.168.100.0/24:
4) Проверить запись sane-port, должен быть:
sane-port 6566/tcp sane-port 6566/udp
5) сделать запись в xinetd.conf:
5) Перезапуск сервиса xinetd:
Проверить статус — не должно быть ошибок:
Настройка клиента для сканирования по сети
1) установить sane, xsane:
для РЕД ОС версии 7.1 или 7.2:
yum install sane-backends-daemon sane-frontends xsane
для РЕД ОС версии 7.3 и старше:
dnf install sane-backends-daemon sane-frontends xsane
2) прописать IP-адрес сервера
3) запустить xsane и выбрать сервер сканирования (возможно понадобится перезапуск рабочей станции)
Если в сети много сканирующих устройств, то при запуске xsane они все отобразятся в программе, чтобы запустить программу xsane с конкретно назначенным сетевым сканером, то можно воспользоваться командой:
xsane kyocera_wc3:192.168.2.190
пример приведен для сканеров марки kyocera.
Но если необходимо, чтобы сканируемая программа не опрашивала сеть на предмет поиска сетевых сканеров и не выдавала их список, то закомментируйте не нужные модели устройств в каталоге /etc/sane.d/dll.conf
Дата последнего изменения: 17.08.2022
Если вы нашли ошибку, пожалуйста, выделите текст и нажмите Ctrl+Enter.