Evince and Firefox fails to print but OpenOffice prints normaly in Jaunty

Bug #369503 reported by Bugsy
4
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cups (Ubuntu)
Triaged
Undecided
Unassigned

Bug Description

Binary package hint: cups

I have Canon LBP5000 printer and I have installed the drivers with this guide https://help.ubuntu.com/community/HardwareSupportComponentsPrinters/CanonPrinters/Canon_LBP_2900

Everything used to work with previous releases but now with Jaunty only OpenOffice and Gedit seem to print normally. For example with Firefox and Evince the system says printing task is done but my printer does nothing.

Now after using this command "cupsctl LogLevel=debug" the printing failed also according to system. It also says printer message "pstocapt2 write error,32"

I'm using little bit older canon driver (1.3) because newer drivers (1.6 and 1.8) seem to have dependability issues.

I have also attached cups error log.

ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Lpstat:
 laite kohteelle LBP5000: ccp:/var/ccpd/fifo0
 laite kohteelle LBP50002: hal:///org/freedesktop/Hal/devices/usb_device_4a9_2679_00000362CB87_if0_printer_noserial
MachineType: Gigabyte Technology Co., Ltd. EP35-DS3
NonfreeKernelModules: nvidia
Package: cups 1.3.9-17ubuntu1
Papersize: a4
PpdFiles:
 LBP50002: Canon LBP5000 CAPT ver.1.3
 LBP5000: Canon LBP5000 CAPT ver.1.3
ProcCmdLine: root=/dev/md0 ro quiet splash
ProcEnviron:
 LANG=fi_FI.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.28-11.42-generic
SourcePackage: cups

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :
Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

For your notice I'm using the lbp5000 printer not the lbp50002. Ubuntu want's to find lbp50002 printer by itself but it does not print at all.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

What is your standard paper size? A4 or Letter? Please edit /etc/papersize if it contains the wrong paper size name. Send the test print job with the correct paper size setting. Note that Firefox and Evince to not remember the paper size setting. You also have to select "Page Setup ..." in the file menu to get access to the paper size.

Do a full system update to capture the newest bug fixes, especially a paper size issue with the CUPS filters.

After that please try again. If the problem persists, please attach the error_log again (proceed as described in the error_log section of https://wiki.ubuntu.com/DebuggingPrintingProblems).

Changed in cups (Ubuntu):
status: New → Incomplete
Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Ok I installed newest updates. I did not check the paper size in the /etc/papersize before updates but at least now it's correct (a4).

Also I disabled the "detect paper size" and the printer started to work properly. Afterwards I enabled it again and the printer still works so the issue seems to be solved.

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

But there is another problem in Evince. If I try to print multiple pages the printing fails and the printig problem solver says "pstocapt2 write error,32." This was not a problem in previous releases.

I have also included troubleshoot.txt from the problem solver.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

This means every program except Evince prints correctly for you now?

Can you attach an error_log of a job printed out of Evince? Please proceed as described on https://wiki.ubuntu.com/DebuggingPrintingProblems, section "CUPS error_log". Thanks.

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Actually after the Evince failed to print other programs failed to print also. But after system restart and changing "detect paper size" to false all programs printed including Evince. Evince still has an issue with one pdf file which doesn't print at all. It's really puzzling because every other pdf file prints normally now.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Where is the "detect paper size" option in your system?

Can you attach the PDF file which still does not print out of Evince for you?

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

The Detect paper size is in the Printing -> General Settings where for example Page size, Color Mode, etc. can be adjusted. Also I'm talking about system wide settings, not just settings found from Evince.

I would like to attach the pdf but it's a pdf book and the licence doesn't allow it.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

What do you mean with "Printing -> General Settings"? In which menu/program is this? Where did you do the system-wide settings? Where do you have "detect paper size" there?

Perhaps the book does not have permission to be printed (by its license), then PDF viewers do not print it as such PDFs are appropriately marked. See File -> Properties in Evince.

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

From gnome toolbar I select System -> Administration -> Printing -> Printer configuration. After that I select the correct printer (lbp5000) and click on Properties. In there is a Printer Options tab where I did found the Detect Paper Size option.

Also I 'm not sure if it is a printing rights issue because the book printed normally with the previous release of Ubuntu (8.10). Did the troubleshoot.txt which I attached 6 messages ago contain anything interesting? It was the same pdf-book I was trying to print (TIVI-PROJEKTIEN JOHTAMINEN - Projektimallit ja l\xc3\xa4pivienti) then.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Can you attach your PPD file (/etc/cups/ppd/LBP5000.ppd)?

Can you attach an error_log of printing your PDF book out of Evince? Please proceed as described on https://wiki.ubuntu.com/DebuggingPrintingProblems, section "CUPS error_log". Thanks.

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Here is the error log. If I try to print multiple pages the system says printing failed but if I try to print only one page the system thinks the printing task is done. Either way no actual pages are printed.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Can you attach your PPD file (/etc/cups/ppd/LBP5000.ppd)?

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Here it is.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Can you execute the following command line in a terminal window:

cupsfilter -m application/vnd.cups-postscript -p /etc/cups/ppd/<printer>.ppd <file>.pdf > test.ps

Replace <file>.pdf by the name of the PDF file which does not print for you. Post the screen output of the command. Display test.ps on the screen (with evince or gv). Does the file display correctly?

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Ok I did "sudo /etc/cups/ppd/LBP5000.ppd /home/carlo/Tivi.pdf > test.ps" It did not allow me to execute the command without sudo. Then commandline reads "sudo: /etc/cups/ppd/LBP5000.ppd: command not found" and the test.ps was empty.

After this I added r+w and execute right to LBP5000.ppd and tried the same command without sudo. Test.ps is still empty but now the commandline reads:

/etc/cups/ppd/LBP5000.ppd: line 1: *PPD-Adobe:: command not found
/etc/cups/ppd/LBP5000.ppd: line 2: *%: command not found
/etc/cups/ppd/LBP5000.ppd: line 3: syntax error near unexpected token `('
/etc/cups/ppd/LBP5000.ppd: line 3: `*% Copyright (C) 2004-2005 CANON INC.'

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

You probably did not replace all placeholders. Please execute

cupsfilter -m application/vnd.cups-postscript -p /etc/cups/ppd/LBP5000.ppd file.pdf > test.ps

with file.pdf beinmg the file name of your e-book which does not print on your printer.

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Ok, the test.ps seems ok and prints correctly. Also the command printted this in command shell
...
DEBUG: Copying page 108...
DEBUG: pagew = 566.2, pagel = 813.2
DEBUG: bboxx = 0, bboxy = 0, bboxw = 595, bboxl = 842
DEBUG: PageLeft = 14.4, PageRight = 580.6
DEBUG: PageTop = 827.6, PageBottom = 14.4
DEBUG: PageWidth = 595.0, PageLength = 842.0
DEBUG: Copying page 109...
DEBUG: pagew = 566.2, pagel = 813.2
DEBUG: bboxx = 0, bboxy = 0, bboxw = 595, bboxl = 842
DEBUG: PageLeft = 14.4, PageRight = 580.6
DEBUG: PageTop = 827.6, PageBottom = 14.4
DEBUG: PageWidth = 595.0, PageLength = 842.0
DEBUG: Wrote 109 pages...
INFO: cpdftocps (PID 8572) exited with no errors.

After that I managed to print one page from the orginal pdf but when I tried to print multiple pages the pdf-printing failed. Now I can't print any pages from the orginal pdf.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Can you replace your /usr/lib/cups/filter/pdftops file by the attached one (do not forget to make the new file executable with "chmod 755 /usr/lib/cups/filter/pdftops") and print your book again? Does it work now?

Revision history for this message
Bugsy (carlo-suomi24-deactivatedaccount) wrote :

Wow, now it prints correctly. Thanks.

I also tried to check the differences between your pdftops and the orginal file but I could not open the orginal file with gedit. Is it correct behaviour?

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

My alternative pdftops filter is a shell script which does principally the same as the original pdftops filter which is a compiled C program. It calls Ghostscript to convert PDF to PostScript. I have written the shell script for quick testing. One can edit it quickly and attach it to bug reports to test the changes. The original filter uses the Ghostscript "pswrite" output device and the alternative filter uses the "ps2write" output device. The PostScript output is different: The former delivers DSC-conforminmg PostScript but converts all text characters into bitmaps, the latter conserves text as text and conserves the fonts, but its PostScript output is not DSC conforming.

The "pswrite" output device has several compatibility problems which got discovered recently: This bug, bug 362186, bug 44989, and bug 361772. The "ps2write" output device solves these problems but its PostScript is not DSC-conforming, so it cannot be used in the PostScript printing workflow of CUPS used by most distributions (PDF input --pdftops--> Non-DSC-PS --pstops--> ...) as the pstops filter which does the page management (N-up, selected pages, reverse order, ...) is fed with non-DSC-conforming PostScript and PostScript must be DSC-conforming to reliably tell pages apart. In the PDF-centric printing workflow in Ubuntu (PDF input --pdftopdf--> page-managed PDF --pdftops--> ...) This is no problem.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Easiest fix would be to patch the CUPS pdftops filter to let Ghostscript use "ps2write".

Changed in cups (Ubuntu):
status: Incomplete → Triaged
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

The use of the "ps2write" output device of Ghostscript in the pdftops filter is not yet possible in CUPS, due to http://bugs.ghostscript.com/show_bug.cgi?id=690475

For the time being use the attached pdftops filter.

Revision history for this message
kurt carter (kurt-tripzsystems) wrote :

Try installing okular. It seems to work where Evince doesn't.

Cheers,

Kurt

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.