tes*_*ode 7 arch-linux cups systemd
为了在 Arch Linux 中进行打印,我安装了 cups、cups-filters 和 hpilp(ghostscript 和 gs-fonts 已经安装)。但是,当我尝试使用以下命令在启动时运行 CUPS 服务时:
systemctl enable cups.service
Run Code Online (Sandbox Code Playgroud)
我收到此错误:
Failed to issue method call: No such file or directory
Run Code Online (Sandbox Code Playgroud)
cupsd 也会发生同样的事情。是否有需要安装的软件包?为什么我没有 CUPS 服务?
ene*_*ene 12
尽管 Hugues Chabot 提供了一个链接,但该链接的解决方案后来才出现。因此,我将引用提供更新且简单的解决方案的答案:
ArchWiki 写道:对于cups 2.0.0,服务名称已更改为org.cups.cupsd.service 而不是cups.service。此包自2014年10月31日起额外提供。升级到2.0.0版本时,需要手动禁用旧服务,否则会在/etc/systemd/system/子目录中留下损坏的符号链接,systemd会发出警告关于不存在的服务。
所以解决办法是:
systemctl enable org.cups.cupsd.service
Run Code Online (Sandbox Code Playgroud)
小智 8
首先检查是否可以直接启动CUPS。
systemctl start cups
Run Code Online (Sandbox Code Playgroud)
如果这个工作,检查是否/usr/lib/systemd/system/cups.socket存在。如果没有,这就是问题所在。
/etc/systemd/system/cups.socket使用以下内容创建。
[Unit]
Description=CUPS Printing Service Sockets
[Socket]
ListenStream=/var/run/cups/cups.sock
[Install]
WantedBy=sockets.target
Run Code Online (Sandbox Code Playgroud)
然后,安装 CUPS 服务。
systemctl enable cups
Run Code Online (Sandbox Code Playgroud)
其他可能的解决方法可以在https://bbs.archlinux.org/viewtopic.php?id=146154找到。