[cups] make browsed printers available on workstation commandline
Klaus Vink Slott
klaus at vink-slott.dk
Sun Aug 1 07:34:39 PDT 2021
Hi
I am currently working in a lab environment trying to understand
autoconfigure before implementing this in production.
The lab has 3 vlans; print - server - worklab. Printer is a Samsung
CLP-680ND, and server and workstations is running openSUSE 15.2 with
cups-2.2.7
I have successfully setup the server to print, although using the
generic driver I was unable to access some of the printers capabilities,
like duplex. I therefore switched to use the ppd file from Samsung and
everything bow seems to work from the server.
On the server I can print from Firefox, KDE apps, and the commandline
whitout problems. I have kept cups-browsed disabled here, to avoid
double printer registration:
klaus at raagi:~> lpstat -a
a4laser accepting requests since søn 01 aug 2021 15:07:12 CEST
klaus at raagi:~> lpr -P a4laser -o sides=two-sided-long-edge long.txt
produces a double sided printout as I would wish/expect :-)
-----------------
The goal is to share this printer via the server.
So I configured avahi on the server, allowed it trough firewall, added
avahi repeater between server lan on worklab lan on the firewall, and
enabled ipp-client on the workstation.
I can now see avahi picks up the printer on the workstation:
klaus at ituska:~> avahi-browse -rt _ipp._tcp
+ wlan0 IPv4 Samsung CLP-680ND @ raagi Internet
Printer local
= wlan0 IPv4 Samsung CLP-680ND @ raagi Internet
Printer local
hostname = [raagi.local]
address = [172.16.191.8]
port = [631]
txt = ["printer-type=0x80105E" "printer-state=4" "Copies=T"
"Duplex=T" "Color=T" "TLS=1.2"
"UUID=83cfee6a-2882-32f6-7771-e157d42a8110"
"pdl=application/octet-stream,application/pdf,application/postscript,image/jpeg,image/png,image/pwg-raster"
"product=(Samsung CLP-680 Series)" "priority=0" "note=Hobbystue"
"adminurl=https://raagi.local.:631/printers/a4laser" "ty=Samsung CLP-680
Series PS" "rp=printers/a4laser" "qtotal=1" "txtvers=1"]
Firefox and Thunderbird also happily picks up the printer, shows status
and is capable of double sided printout as well.
But I am unable to access the printer from the commandline and KDE Apps:
klaus at ituska:~> lpstat -a
lpstat: No destinations added.
Searching for this problem I have seen various howto's using lpadmin to
configuring the printer
sudo lpadmin -p a4laser -v
dnssd://Samsung%20CLP-680ND%20%40%20raagi._ipp._tcp.local/cups?uuid=83....very
long uuid here
but that seems manual, labor intensive and error prone to me. Is it not
possible to have command line printing autoconfigured?
In cups/error_log I see:
E [01/Aug/2021:13:05:11 +0200] [Client 10016] Returning IPP
client-error-bad-request for Create-Printer-Subscriptions (/) from localhost
Does this indicate that cups-browsed is missing some permission to
create the printer it found?
--
Regards
Klaus
More information about the cups
mailing list