Ubuntu安装CUPS服务
本文以 Ubuntu 22.04 为例, 已使用 HP smart 安装打印机驱动并有线连接打印机.
# 安装
apt install cups aptitude
aptitude install ghostscript
aptitude install foomatic
# 启用
sudo systemctl start cups
sudo systemctl enable cups
# sudo nano /etc/cups/cupsd.conf
# 修改配置
vim /etc/cups/cupsd.conf
usermod -aG lpadmin root
在 vim 中用 / 搜索关键词并更改配置:
Browsing Off或Browsing No–>Browsing OnListen localhost:631–>Listen 0.0.0.0:631Order allow,deny–> 在下面一行增加Allow all
更改后重启服务:
sudo systemctl restart cups
其后进入 ip:631 可以在 Printers 选项卡中得到打印机的服务位置.
