cups icon indicating copy to clipboard operation
cups copied to clipboard

Profiles and Filtering of Detected Printers

Open callegar opened this issue 2 years ago • 7 comments

In some of the sites in which I happen to work, due to the autodetection of driverless printers, the list of printers becomes huge and hard to deal with (this is also because the names by which the driverless printers are presented are often not easy to associate with the printers locations).

The problem is made worse by the fact that it seems impossible to permanently associate location information to the autodetected printers.

Would be nice to have the possibility of defining patterns to filter out printers that are known to be uninteresting.

callegar avatar Jun 20 '22 14:06 callegar

@callegar The location and name can be configured through the printer’s web interface. One thing we could do here is add a hyperlink to the printer web page to change the defaults - would require some changes to the way we load the device list but shouldn’t be too bad. GNOME print center will also be adding this functionality for a future version…

michaelrsweet avatar Jun 20 '22 16:06 michaelrsweet

Thanks for the info, being able to change the name can partially help. The biggest issue remains that in certain location (e.g. at a university site) the list of printer grows to > 30, including a lot of printers that are probably misconfigured (or more likely unconfigured) by their owners/administrators so they broadcast their existence on the network even if I do not even know where they are and if they often use other authentication mechanisms to prevent unauthorized people from printing on them.

Having a "hide" flag for them (so that they get listed in the settings interfaces, but not in the print dialogs) would be extra useful imho.

callegar avatar Jun 21 '22 09:06 callegar

Coincidentally, I had a conversation with a user last week about the issue of hiding (filtering?) printers in a dialog. My thinking was influenced by this thread. cups-browsed has BrowseFilter, which may be of use.

debiantriage avatar Jun 24 '22 17:06 debiantriage

@michaelrsweet @debiantriage what about adding this functionality into printer profiles? <name> hide into ~/.cups/profiles.

@callegar the future printer profiles functionality can be used for the issue as well - you will be able stop and disable Avahi on your machine and define the printer of your choice in ~/.cups/profiles by name and uri to connect. This should clean up your printers list and drop the dependence on Avahi, if requested.

zdohnal avatar Aug 03 '22 11:08 zdohnal

@zdohnal do you know if it is possible to only stop and disable incoming DNS-SD announcements for printers in Avahi instead of stopping and disabling the whole Avahi? Perhaps other things are still wanted to get via Avahi?

jsmeix avatar Aug 03 '22 11:08 jsmeix

@zdonal CUPS has long had support for filtering based on the printer-type bits, and we could certainly add a way to hide unwanted printers locally in /etc/cups or ~/.cups.

@jsmeix There is currently no way to disable DNS-SD/mDNS at run-time in libcups. Again, we could extend the client.conf syntax to include Browsing options (much like we've had in cupsd.conf).

michaelrsweet avatar Aug 03 '22 13:08 michaelrsweet

Note: Retitled this issue to reflect the scope...

Incorporate libcups issue 39 for profiles and filtering.

michaelrsweet avatar Sep 04 '23 19:09 michaelrsweet