Bug 1628255 - cups-filters: Sticky EOF behavior in glibc breaks descriptor concatenation using dup2 (breaks printing)
Summary: cups-filters: Sticky EOF behavior in glibc breaks descriptor concatenation us...
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: cups-filters
Version: 29
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Zdenek Dohnal
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: RejectedBlocker https://fedoraproject...
Keywords: CommonBugs
Depends On:
Blocks: 1626996
TreeView+ depends on / blocked
 
Reported: 2018-09-12 14:59 UTC by Zdenek Dohnal
Modified: 2018-10-02 19:31 UTC (History)
20 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2018-10-02 19:31:37 UTC


Attachments (Terms of Use)
Bad strace (3.38 MB, text/plain)
2018-09-12 14:59 UTC, Zdenek Dohnal
no flags Details
Good strace (3.54 MB, text/plain)
2018-09-12 15:00 UTC, Zdenek Dohnal
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Github /OpenPrinting cups-filters issues 58 None None None 2018-09-12 14:59 UTC
Sourceware 23636 None None None 2018-09-12 14:59 UTC

Description Zdenek Dohnal 2018-09-12 14:59:01 UTC
Created attachment 1482708 [details]
Bad strace

Printing stopped working with several filters (f.e. foomatic-rip) after glibc update to 2.27.9000-10. Print jobs get stuck in print queue as pending-held.

The problem is caused by upstream commit https://sourceware.org/git/?p=glibc.git;a=commit;h=2cc7bad0ae0a412e75270be5ed41d45c03e7a931 - which made EOF sticky, but it changed pipe concatenation behavior, which broke printing filters at least.

Steps to reproduce:
0) install cups and foomatic
1) Add 'FileDevice Yes' into /etc/cups/cups-files.conf
2) $ sudo systemctl restart cups
3) $ sudo lpadmin -p test -v file:/tmp/printout -m foomatic:Canon-imageRunner_C5185i-Postscript.ppd -E
4) $ lp -d test /etc/fstab
5) '$ lpstat -o test' produces an output - there is pending job

Comment 1 Zdenek Dohnal 2018-09-12 15:00 UTC
Created attachment 1482709 [details]
Good strace

Comment 2 Fedora Blocker Bugs Application 2018-09-14 11:51:23 UTC
Proposed as a Blocker for 29-final by Fedora user eischmann using the blocker tracking app because:

 This bug breaks printing over network for many printers, thus have a big impact on users.
To reproduce it, you need to set up a network printer the default way via printers panel in GNOME Control Center. It doesn't affect cups-browsed.

Comment 3 Zdenek Dohnal 2018-09-14 12:21:36 UTC
To be precise, 
1) it can be reproduced even by creating the printer by lpadmin (with any device uri, even file device uri), through CUPS web interface and system-config-printer. Essential part for reproducing is to have file which needs to be run through filters before it is send to printer. This can be done by creating a printer with ppd.

2) printing from client through print queues discovered by cups-browsed will not work if server, which shares printers, is F29+ (or if it has glibc-2.28 or backported patch mentioned above), because filtering is affected.

Cups-browsed uses design in which it sends unfiltered data to server, where filtering happens. So if server is affected by this issue, then printing through cups-browsed queues is no-go too.

Only other way to avoid this issue is send the print data to a printer as unfiltered, e.g. raw. But this is unrecommended and shouldn't be used for other purposes than debugging.

$ lp -d <printer> -o raw <file>

Comment 4 Geoffrey Marr 2018-09-17 20:16:07 UTC
Discussed during the 2018-09-17 blocker review meeting: [1]

The decision to classify this bug as a "RejectedBlocker" was made as this is obviously an annoying bug for some, but the release criteria don't cover printing in any way and therefore this bug cannot be classified as a blocker.

[1] https://meetbot.fedoraproject.org/fedora-blocker-review/2018-09-17/f29-blocker-review.2018-09-17-16.02.txt

Comment 6 Kamil Páral 2018-09-20 12:48:10 UTC
Geof, when you reject a high-profile annoying bug, please make sure it's at least tagged as a common bug. Thanks. Adding it now.

Comment 7 Florian Weimer 2018-09-21 09:56:09 UTC
glibc upstream will not revert this change and suggests that cups-filters should be fixed instead.  Reassigning accordingly.

Comment 8 Fedora Update System 2018-09-21 12:47:01 UTC
cups-filters-1.20.3-8.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-4f7176aa5c

Comment 9 Fedora Update System 2018-09-22 20:03:55 UTC
cups-filters-1.20.3-8.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-4f7176aa5c

Comment 10 Fedora Update System 2018-09-24 15:00:44 UTC
cups-filters-1.20.3-9.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-26b38a126f

Comment 11 Fedora Update System 2018-09-27 02:09:23 UTC
cups-filters-1.20.3-9.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-26b38a126f

Comment 12 Fedora Update System 2018-10-02 19:31:37 UTC
cups-filters-1.20.3-9.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.