New issue
Advanced search Search tips

Issue 89122 link

Starred by 7 users

Issue metadata

Status: WontFix
Owner: ----
Closed: May 2012
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug

  • Only users with Commit permission may comment.

Sign in to add a comment

Printing fails - Brother HL-4040CDN printer using Brother drivers and ppd file and CUPS

Reported by, Jul 13 2011

Issue description

Chrome Version       : 12.0.742.100
OS Version: 
URLs (if applicable) : Many, including this page
Other browsers tested:
  Add OK or FAIL after other browsers where you have tested this issue:
     Safari 5: Untested
  Firefox 4.x: OK
     IE 7/8/9: Untested

What steps will reproduce the problem?
1. Bring up a page (this one, for example)
2. Select Print from the tools menu - select a CUPS supported printer
3. Click Print

What is the expected result?
The expected result is the printing of the page.

What happens instead?
The printer almost immediately displays an E1 ("Print Unable") error
message and has to be powered off and on before it will print any
documents. Documents originating from google-chrome are never actually printed although documents originating from firefox (including the same page which produces the E1 error if google-chrome is used), acroread,
openoffice etc. print properly.

The E1 error is typically generated if the file sent to the printer is 
corrupted or contains instruction sequences which cannot be interpreted by the printer. Note that this printer has 256 MB of installed memory
which should be sufficient to print this page.

Please provide any additional information below. Attach a screenshot if

UserAgentString: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.100 Safari/534.30

Labels: -Area-Undefined Area-Internals Action-FeedbackNeeded Feature-Printing
If you instead print to PDF. Then send the PDF to the printer with lp, does that work?

Comment 2 by, Jul 15 2011

If I send the pdf file (output.pdf) directly to the printer (lpr -Plp0 output.pdf), I get the E1 error.
Note that I normally do not send pdf files directly to the printer; I only send ps and text files directly.

If I open output.pdf with acroread, it is displayed normally and printing from acroread works OK.

If you want me to send you output.pdf or do any other tests, just let me know. I will be at the PC which is connected to the HL-4040CDN printer this week through Friday; then I will be away for about a week - so, I cannot test next week.
Additional information:

output.pdf generated by google-chrome causes the E1 "print unable" error.
Examination of this file indicates that it is a pdf Ver 1.4 file.

Another pdf Ver 1.4 file generated by another program prints directly OK.

This indicates that, possibly, google-chrome is generating pdf Ver 1.4 files which are either corrupt or which the printer cannot properly interpret.

Can you attach output.pdf here? Also, what's the paper size in the printer? (assuming only 1 paper source)

Comment 4 by, Jul 15 2011

Here is output.pdf.
Paper size is standard letter (8.5" x 11")
150 KB Download
Labels: -Action-FeedbackNeeded
Printed output.pdf just fine here with "lp" and a HP Laserjet.

Comment 6 by, Jul 15 2011

I have seen other isolated cases of pdf files throwing this error (2 or 3 out of 1000s in the last 3 years) but, out of about 20 google-chrome attempts with different pages, every one causes the error.

Is there any way for google-chrome to generate ASCII pdf files or can you convert the binary file to ASCII? If so, I can help you since I have the actual printer and you probably don't. I might be able to find the offending command in the pdf stack if I have an editable file.

If you can email me an ASCII pdf file I can work with it; that way, I won't have to install a special version of google-chrome to do these tests.
In 12.x we use Cairo backend to generate the PDF to send the printer. In 13.x and beyond, we use a Skia PDF backend instead of Cairo. You may want to try the beta or dev channel (with print preview) and see if it has the same problem. Be sure to backup your profile when switching channels.

Comment 8 by, Jul 15 2011

Thanks for the information.
As I said, I'll be out of town for about a week but after I get back, I'll look into this further, testing with the beta and dev channels. If these don't look promising, I'll write a few test programs using cairo and Skia (which I'm not familiar with yet).  I'll tell you what I find out.

Comment 9 by, Jul 16 2011

I made a quick test with beta (13.0.782.56 beta, x86-64 from yum repository).
The print preview came up but, when I sent it to the printer, I still got the Brother E1 ("print unable") error. 
I have this exact problem printing from Firefox under Ubuntu 11.04 with CUPS 1.4.6.  I'm not sure if this is a browser bug or something with Cups or the Brother drivers.

Comment 11 by, Jul 23 2011


I'm still trying to figure out if this is possibly a Brother bug. Do you know your firmware version? The Brother web site has an newer version than mine but they only support upgrading from a Windows PC; since I am limited in terms of Windows PCs, I am approaching this task carefully and slowly. I would rather not attempt the firmware upgrade if you have already verified that it does no good. 
Printer Firmware Version : 1.21
Printer Sub Firmware Version : 1.09
Engine Firmware Version : 1.16 

Comment 13 by, Jul 23 2011

Mine is:

Main Controller Main ROM Version: 1.24
Main Controller Sub ROM Version: 1.10
Engine Controller ROM Version: 1.20
PictBridge Program Version: 1.03

It looks like I'll be attempting a firmware upgrade
Updated firmware to:
Printer Firmware Version : 1.24
Printer Sub Firmware Version : 1.10
Engine Firmware Version : 1.21 

Still have the same problem.

Comment 15 by, Jul 23 2011

It looks like you have the latest firmware; so, I'll stay where I am for now.
Just upgraded to google-chrome 13.0.782.99 beta --> same problem

Comment 16 by, Jul 23 2011

I have just used

gs -- toolbin/ output.pdf decompress_cairo.pdf

to produce an ascii pdf file

and done the same thing for output.pdf from the google-chrome beta version.

Both decompressed files produce the E1 error but at least they can be read and (hopefully) analyzed.

Files are attached; but, I'll try with a very simple web page to make analysis

993 KB Download
353 KB Download

Comment 17 by, Jul 24 2011

A tiny bit of progress:

I was able to create a page which can be printed. Unfortunately, it is very minimal.
Since it includes my email addresses, I am not posting the actual page. Here is the procedure to create it.

1) Have (or create) a yahoo! email account.
2) Send a minimal email (Subject line only) to that account.
3) log into the email account using google-chrome.
4) open and print the email.

Apparently, this minimal page does not have the pdf code which triggers the error.

Unfortunately, still leaves a lot of binary in the pdf file. I was hoping
to create an editable file in order to home in on the offending code. Is there any way google-chrome can be configured (or a special build created) to create ASCII pdf files???

Comment 18 by, Jul 24 2011

Some more clues and a very ugly workaround:

Starting with this page (which gives the E1 error if trying to print directly)

1) Print to a pdf file.
2) Open the pdf file with Acroread (Version 9)
   It is displayed properly in Acroread
   but if an attempt to print from Acroread is made, printing fails with a message:
     "The document could not be printed"
3) The ugly workaround part:
   Open the pdf file with xpdf
   It is displayed properly and CAN be printed from xpdf.

I don't know if I can do much more to figure this out without the ability to access
an ASCII pdf print file; but it is still a bug.
scm, I appreciate your efforts in trying to track down this problem.

The specs for this printer seem to indicate that it only understands PCL.  This means that CUPS has to translate PDF (and PS for that matter) into PCL before sending it to the printer.  Since other PCL printers generally work, there may be a problem with your CUPS configuration (most likely), or (unlikely) there's a bug in the PCL interpreter in the printer that is only tickled by the PDF->PCL filter used by CUPS.

FYI: the PDF file format is sensitive to actual byte position - there's a table of contents at the end of the file that indicates the byte offsets of the objects in the file.  But that doesn't mean you can't edit it, removing attributes by changing the value to whitespace should work just fine.

Stream objects in PDFs can be compressed.  The dictionary for the stream will include a "Filter" attribute if the stream is compressed. If you want to create a custom build with PDF compression disabled, you just have to change the method SkFlate::HaveFlate to return false in third_party/skia/src/core/SkFlate.cpp.

Comment 20 by Deleted ...@, Dec 26 2011

I'd suggest using the vendor drivers:

Had the same problem using the Foomatic drivers, but when I switched to the vendor drivers printing was much faster and reliable.

Labels: Action-FeedbackNeeded
scm, any further info?
I'd like to add to this issue. XUbuntu Precise 12.04, using Google Chrome 18.0.1025.142 stable; also have tried "beta" builds of version 18. On Brother 4040 and 5370 printers: the former spits out a PCL error; the latter says something about a "missing command".

* Windows, version 18: works
* Xubuntu 11.04, CUPS 1.4.x: works
* Xubuntu 11.04, CUPS 1.5.0: works
* Xubuntu 12.04, CUPS 1.5.2: errors

Funny enough, if I save the PDF, Adobe Reader can read it, but it complains about a missing "Arial, Bold" font. I'm going to see if the vendor can check their software, else maybe some font conversion is going awry?
unquietwiki: sounds like a bug in cups or xubuntu
unquietwiki: you also need to be more specific about what drivers you are using. Have you tried the vendor drivers?
Have tried vendor-based drivers: not much luck. Apparently there was a known issue circulating around the time of my feedback, concerning Brother printers and CUPS 1.5.2: the Debian+Ubuntu folks have tried to fix that, but the latest filter package (dated yesterday) still gives some PDF issues on Chrome printing. Tested this against a 4040 printer using drivers for the 4040 pxlcolor + 52xx BRScript + 53xx BRScript + generic PS + generic PCL: I got some bold headers from my vendor program to print out using PCL; Ubuntu test pages didn't even work for the BRScript drivers.

Think I found the issue with PDFs. "Poppler" binaries in the latest Ubuntu tree (12.04) seem to be causing the issues with PDFs and whatnot. I'm verifying the proper workaround now, but if you install 11.10 poppler binaries (; and replace the appropriate binaries in /usr/lib/cups/filters with the ones from the old version (those get installed to /usr/bin): PDF printing appears to work again.

Bug I found that involves poppler issues: they appear to be putting out a fix; will have to see if it corrects the Chromium bug or not.

One other outlier to consider: Ghostscript 9.05 has some changes involving font substitution. Replacing that with 9.04 got rid of the "PCL XL error" I was getting on my Brother printers, but output was still only 2 page elements: that's why I kept digging until I found the poppler stuff.
Okay, I have a documented workaround for the printing issues involving 12.04 Ubuntu. Basically, you wash the PDF output through pdftocairo, and that should catch bad PDF/layout issues.
Status: WontFix
unquietwiki: sounds like your issue only occurs when you try to print a PDF, not when you try to print a webpage?  In the future, please file a new bug when yours is not reproduced by the original poster's instructions.

unquietwiki's issues seem to be in system software and resolved whereas the original poster hasn't replied since January so I'm going to close this as Wont Fix.  Comment and reopen if this is still a problem.
Project Member

Comment 29 by, Oct 13 2012

Labels: Restrict-AddIssueComment-Commit
This issue has been closed for some time. No one will pay attention to new comments.
If you are seeing this bug or have new data, please click New Issue to start a new bug.
Project Member

Comment 30 by, Mar 9 2013

Labels: -Action-FeedbackNeeded Needs-Feedback
Project Member

Comment 31 by, Mar 10 2013

Labels: -Area-Internals -Feature-Printing Cr-Internals Cr-Internals-Printing

Sign in to add a comment