Edgy only offers a binary GUI control for printer sharing: Either all printers are shared to the local network, or no sharing happened at all. We both want to make this more flexible and also support sharing printers through Samba.


Printer sharing is very common in both commercial and home environments, thus it should be easy to set it up.

Use cases

  • Martin wants to make his Laser printer automatically available to other Ubuntu boxes in the LAN (IPP LAN printer detection), but does not want to share the color inkjet, since printing on it is expensive.
  • John wants to share his printer with others using Windows Sharing Protocol, so that Windows automatically finds the printer.


This applies to Ubuntu and Xubuntu. KDE has its own printer management GUI, which is not covered here.


Configuration GUI

As specified in the PrinterDrake specification, we want to replace gnome-cups-manager by Printerdrake. Printerdrake offers a much more flexible configuration of ACLs and sharing:

  • Also offers global on/off switch for the common home user use case.
  • Can configure arbitrary network ACLs.
  • Currently offers to hide particular printers from network announcement. However, this is not strong enough, this needs to be changed to forbid remote access to this printer altogether.

Sharing printers to Windows

There are two principal methods of sharing a printer to Windows:

  • Windows 2000 and up have builtin support for the Internet Printing Protocol standard (IPP). As soon as cups (which is IPP compatible) allows sharing a printer, Windows clients can immediately use it by specifying the URL to that printer in the "add printer" wizard (e. g. http://cups.server:631/printers/dj520). This requires no further software on either the client nor the server, but since Windows does not understand the Cups browsing protocol, such printers are never automatically announced to the Clients. An improvement here is to show the IPP URL in the configuration GUI so that administrators can carry it to the Windows client.

  • Printers can also be shared over the SMB protocol, which all Windows versions support. This has the advantage of being automatically advertised in Windows' "Add printer" wizard, but it requires Samba to be installed on the cups server side. Ubuntu's samba is linked to the cups library, so that it automatically picks up printer configuration changes. To make this work out of the box, the default samba configuration needs to be changed to export printers by default.

In either case, the printer is not automatically available on the Windows client, it needs to be manually added using the printer wizard. You also need to supply a driver for it (usually by using the driver CD shipped with the printer). Samba allows to automatically supply printer drivers to the Windows clients, but this currently requires shipping and installing Windows specific DLLs on the print server. This case is not handled here; the cups developers plan a free solution for this in a future version.



  • When disabling sharing of a particular printer, this not only has to disable browsing announcement, but also needs to add a localhost-only ACL to this printer.
  • Show IPP URL when switching on sharing of a printer.


  • Change the default configuration according to man cupsaddsmb. No dynamic configuration changes are necessary.

Data preservation and migration

None required. Printers are never switched to be shared automatically on upgrades.


How about linking to http://localhost:631/ for users to configure CUPS? You can share printers quite easily that way, but only between Linux/BSD/Mac/Solaris/whatever else uses CUPS. It'd be useful to add some Samba-related printer options to the CUPS page if possible. -Junx


PrinterSharing (last edited 2008-08-06 16:29:23 by localhost)