OpenPrinting / cups

OpenPrinting CUPS Sources
https://openprinting.github.io/cups
Apache License 2.0
1.01k stars 182 forks source link

Access Log Reports Cancel-Subscription client-error-not-found #776

Closed FosterSM closed 1 year ago

FosterSM commented 1 year ago

A few weeks ago I had a problem creating temporary print queues, this was resolved see: https://github.com/OpenPrinting/cups/issues/771

Version cups 2.4.6. LFS/BLFS Version 11.3 Linux Kernels remote print server 5.15.127 local client 6.4.11.

The print queues have disapeared on the client systems and the access log reports typically: localhost - - [22/Aug/2023:12:04:18 +0100] "POST / HTTP/1.1" 200 356 Create-Printer-Subscriptions successful-ok localhost - - [22/Aug/2023:12:04:18 +0100] "POST / HTTP/1.1" 200 148 Cancel-Subscription successful-ok localhost - - [22/Aug/2023:12:04:18 +0100] "POST / HTTP/1.1" 200 148 Cancel-Subscription client-error-not-found localhost - - [23/Aug/2023:07:14:42 +0100] "POST / HTTP/1.1" 200 356 Create-Printer-Subscriptions successful-ok localhost - - [23/Aug/2023:07:14:43 +0100] "POST / HTTP/1.1" 200 148 Cancel-Subscription successful-ok localhost - - [23/Aug/2023:07:14:43 +0100] "POST / HTTP/1.1" 200 148 Cancel-Subscription client-error-not-found

There is no error log. The permanant printers on the print server are present and working correctly. mDNS is working (avahi-resolve-host-name moira.local resolves) but lpstat -l -e returns nothing.

Any suggestions what has gone wrong? Thanks

zdohnal commented 1 year ago

Hi,

does avahi-browse -avrt see the IPP services from the server?

FosterSM commented 1 year ago

No it reports other things but not the server IPP printers. = eth0 IPv4 Moira _sftp-ssh._tcp local hostname = [Moira.local] address = [192.168.0.1] port = [22] txt = [] = eth0 IPv4 MOIRA _smb._tcp local hostname = [Moira.local] address = [192.168.0.1] port = [445] txt = [] = eth0 IPv4 MOIRA _device-info._tcp local hostname = [Moira.local] address = [192.168.0.1] port = [0] txt = ["model=MacSamba"] = eth0 IPv4 Moira _ssh._tcp local hostname = [Moira.local] address = [192.168.0.1] port = [22] txt = []

zdohnal commented 1 year ago

Ok, what cupsd logs say on the server?

Turn on debug2 logging there, restart cupsd, wait several seconds and then try avahi-browse -avrt on a client again. If no printers are seen, get the cupsd logs from the server and attach their file here.

FosterSM commented 1 year ago

The printers are now visable. error_log.txt

FosterSM commented 1 year ago

./rc4.d/S34avahi ./rc4.d/S25cups It looks like cupsd is started before avahi could that be the reason for the failure ?

zdohnal commented 1 year ago

It depends on your system - if you have other means how to start avahi-daemon (like systemd socket), avahi-daemon can be started later, when cupsd actually does the request to it (to f.e. register the service). If not, avahi-daemon has to be started and running before cupsd.

To cut it short, avahi-daemon has to be accessible (running or started by demand) when cupsd wants and has to run to keep sharing the services.

FosterSM commented 1 year ago

I will talk with BLFS people, thanks for the help.