如何让 scanbd 在 Raspberry Pi 上工作

如何让 scanbd 在 Raspberry Pi 上工作

scanbd我正在尝试将带有 Raspbian 的 Raspberry Pi 配置为适用于我的 Canon CanoScan LIDE 60 的扫描服务器。SANE由于不直接支持这些按钮,我必须手动编译最新版本,scanbd如下所述https://riptutorial.com/raspberry-pi/example/22822/configure-sane-to-scan-from-the-network使用配置,该配置有效,但我在和--enable-scanbuttond之间的连接失败了。scanbdSANE

到目前为止我得到了什么?

  1. 扫描仪工作(扫描)scanimage并显示为scanimage -L
  2. 编译和配置scanbd运行后scanbd -d7 -f显示我的扫描仪和按钮按下情况,我还可以scanbd在前台运行时触发脚本以启动扫描。

我被困在哪里了?

一旦我删除除net配置SANE和配置xinetd之外的所有内容,scanimage -L就不再列出任何扫描仪,因此我无法扫描scanimage。所以看来沟通或权利有问题。

当我scanbd -d7 -f在输出中运行时,我看到

scanbd: start dbus thread
scanbd: scbtn_poll
scanbd: Not Primary Owner (-1)
scanbd: Name Error (Connection ":1.151" is not allowed to own the service "de.kmux.scanbd.server" due to security policies in the configuration file)

看来问题的一部分是scanbm无法在 6566 上监听:

systemctl status scanbm.socket 
● scanbm.socket - scanbd/saned incoming socket
   Loaded: loaded (/lib/systemd/system/scanbm.socket; enabled; vendor preset: enabled)
   Active: failed (Result: resources)
   Listen: [::]:6566 (Stream)
 Accepted: 0; Connected: 0;

Feb 14 19:38:22 RaspberryPrinter systemd[1540]: scanbm.socket: Failed to create listening socket ([::]:6566): Address already in use
Feb 14 19:38:22 RaspberryPrinter systemd[1]: scanbm.socket: Failed to receive listening socket ([::]:6566): Input/output error
Feb 14 19:38:22 RaspberryPrinter systemd[1]: scanbm.socket: Failed to listen on sockets: Input/output error
Feb 14 19:38:22 RaspberryPrinter systemd[1]: scanbm.socket: Failed with result 'resources'.
Feb 14 19:38:22 RaspberryPrinter systemd[1]: Failed to listen on scanbd/saned incoming socket.
Feb 14 23:57:46 RaspberryPrinter systemd[16760]: scanbm.socket: Failed to create listening socket ([::]:6566): Address already in use
Feb 14 23:57:46 RaspberryPrinter systemd[1]: scanbm.socket: Failed to receive listening socket ([::]:6566): Input/output error
Feb 14 23:57:46 RaspberryPrinter systemd[1]: scanbm.socket: Failed to listen on sockets: Input/output error
Feb 14 23:57:46 RaspberryPrinter systemd[1]: scanbm.socket: Failed with result 'resources'.
Feb 14 23:57:46 RaspberryPrinter systemd[1]: Failed to listen on scanbd/saned incoming socket.

netstat -tulpn没有告诉我是谁:tcp6 0 0 :::6566 :::* LISTEN -

知道如何解决这个问题以及总体问题是什么吗?您需要查看哪些文件/日志才能获得帮助?

答案1

你需要 root 才能执行此操作:

user@box:~$ sudo ss -l -n -p | grep 6566 | xargs
tcp LISTEN 0 4096 *:6566 *:* users:((systemd,pid=1,fd=84))

相关内容