From 8a9a66302f0c2705d8d42f2a8a60d46e37042ea1 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 10 Jul 2012 11:04:24 -0400 Subject: [PATCH] Add remote CUPS delegation example to the lpadmin post. --- posts/Adding_a_network_printer_with_lpadmin.mdwn | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/posts/Adding_a_network_printer_with_lpadmin.mdwn b/posts/Adding_a_network_printer_with_lpadmin.mdwn index d672919..b381f12 100644 --- a/posts/Adding_a_network_printer_with_lpadmin.mdwn +++ b/posts/Adding_a_network_printer_with_lpadmin.mdwn @@ -51,7 +51,7 @@ To fix this, I had to emerge `net-print/gutenprint`. Putting it all together, add and enable the new printer: - $ lpadmin -E -p afmlab -v socket://123.45.67.89 -m gutenprint.5.2://hp-lj_4240/expert -L "LaserJet 4240, Disque 927" -E + # lpadmin -E -p afmlab -v socket://123.45.67.89 -m gutenprint.5.2://hp-lj_4240/expert -L "LaserJet 4240, Disque 927" -E Note the two `-E` options. The first one (before `-p`) forces encryption when connecting to the server. The last one enables the @@ -59,12 +59,22 @@ destination and starts accepting jobs. You'll probably also want to make the new printer the default: - $ lpadmin -d afmlab + # lpadmin -d afmlab The CUPS daemon will eventually (i.e. after a few seconds) flush these configuration changes into `/etc/cups/printers.conf` if you prefer editing text files to the command line or GUI tools ;). +If you want to add a printer to your local CUPS server that is already +configured from another CUPS server (e.g. printing from your laptop +(local CUPS) to a USB printer plugged into your desktop (another +CUPS)), you can just drop the model info: + + # lpadmin -E -p afmlab -v http://my-desktop:631/printers/afmlab -L "LaserJet 4240, Disque 927" -E + +where `my-desktop` should be the domain name or IP address of the +remote CUPS server. + [CUPS]: http://www.cups.org/ [documentation]: http://www.cups.org/documentation.php [options]: http://www.cups.org/documentation.php/doc-1.4/options.html -- 2.26.2