OpenPrinting / cups

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

CUPS UI (631) fails to update the default printer in /etc/cups/lpoptions #818

Closed ToddAndMargo closed 10 months ago

ToddAndMargo commented 10 months ago

Dear Cups Developers,

Fedora 38 cups-2.4.7-1.fc38.x86_64

/etc/cups/lpoptions

This has taken me over two year to figure this out. Please do not blow me off.

For the last two years, my default printer, when opening programs, has been “Print to LPR”. The Web UI (https://127.0.0.1:631, a.k.a 631) had my default printer set to B4350 (Okidata B4350). I could not figure out why.

After my Oki B4350 died, I replaced it with a Brother HL-L2300D. I remove the old printer and install the new printer in 631. Everything went well, except my default printer kept coming up as Cups-PDF in all my programs. Well at least it changed.

Troubleshooting it, I found that CUPS had failed to upgrade the new default printer in /etc/cups/lpoptions. (My system has been through several reboots.) I even removed and reinstall the HLL2300D several times to make sure it was the default.

To correct the issue: vi /etc/cups/lpoptions changed from Default B4350 to Default HLL2300D

Now all my programs, including those Windows programs running under Wine 8.19, recognize my default printer as the HLL2300D. (Well, except Simple Scan, which still thinks the default is “Print to LPR”.)

Since the WEB UI (631)/lpadmin and lpoptions are ALL part of the CUPS project, they should interact properly with each other and not leave the uses pulling their hair out trying to figure out why the default printer in not working. If 631 says a particular printer is the default, then is sure as dang tooting should actually be the default.

And now if you look at my /etc/cups/printers.conf, you will see that the default is set correctly there. It also show the HLL2300D as the default in 631.

<Printer Cups-PDF>
PrinterId 4
UUID urn:uuid:8d86be01-61b0-3452-6e91-ee3dcc9adb2b
Info Cups-PDF
...
</Printer>

<DefaultPrinter HLL2300D>
PrinterId 15
UUID urn:uuid:19a617e6-961d-36e7-6618-e6d37a74bd43
Info HLL2300D
...
</DefaultPrinter>

Companion bug on Fedora Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2247186

Last on the companion bug was "I'll reopen the ticket if upstream acknowledges this as a bug."

Many thanks, -T

michaelrsweet commented 10 months ago

This is expected.

The "lpoptions" default is client-side. The web interface/lpadmin default is server-side.

ToddAndMargo commented 9 months ago

The "lpoptions" default is client-side. The web interface/lpadmin default is server-side.

That makes sense. But it is not intuitively obvious to the lay user. It took me two years to figure it out. Would you consider removing the confusion for lay people by adding some wording to the Web UI to the affect that "This is the service side default printer. For your local computer, set the default printer with lpoptions: lpoptions -d printer-name."

Okay, and I know I may be pushing it here, but it would be capitol if you added a client side setting for default printer to the Web UI too.