Comment 57 for bug 1731417

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

According to the attached log files hp-setup has created a print queue with the same name as a queue created by cups-browsed, overwriting this queue. As cups-browsed removes all the queues it created when it shuts down, it also has removed this queue.

Normally cups-browsed gets a notification from CUPS on any queue modification and if one overwrites one of cups-browsed's queues, cups-browsed releases the queue from its control and so it does not get deleted on shutdown. Only here cups-browsed got shut down too quickly after the queue got overwritten, leaving no time for cups-browsed to receive the notification from CUPS and release the queue from its control. Probably hp-setup restarts CUPS right after creating a queue and this makes systemd restart cups-browsed.

To overcome this problem I have now added an additional check to cups-browsed that if it removes a print queue, independent on whether on shutdown or when a printer disappears from DNS-SD (printer turned off or so), it checks whether it perhaps got overwritten and refrains from removing in such a case.

I have committed the fix to the upstream GIT of cups-filters:

https://github.com/OpenPrinting/cups-filters/commit/4814a2238

If you are familiar with building software from source, please test.