Re: [cups] Guidance on troubleshooting printing to USB-connected brother laser printer

Banibrata Dutta <[email protected]>
Newsgroups gmane.comp.printing.cups.general
Message-ID <CALODqpo1oWjU396U9HPd3i5M9YM93Xkg5_2nHqfJNvDj7Uw72w@mail.gmail.com>
On Tue, Sep 29, 2020 at 11:49 AM Johannes Meixner <[email protected]> wrote:

>
> Hello,
>
> On 2020-09-28 17:35, Banibrata Dutta wrote:
> > On Mon, Sep 28, 2020 at 6:49 PM Brian Potkin wrote:
> >
> >>
> >> Both Firefox and Evince convert this 4-page PDF into another PDF
> >> before
> >> sending to the printing system. You can choose to troubleshoot using
> >> this PDF (it will be one of the d* files) or the original 4-page PDF
> >> or
> >> both.
> >>
> >> You will have a PPD for the printer in /etc/cups/ppd.
> >
> > Is there a way to know the right PPD file definitely ?
>
> The PPD that you currently use for your printer in the /etc/cups/ppd
> directory is named as your print queue for your printer is named.
> This is the PPD that needs to be tested via cupsfilter how the
> generic filtering (except the printer specific filtering) works.
>
> >> Execute
> >>
> >>  sudo cupsfilter -p PPD_in_/etc/cups/ppd -m
> >> application/vnd.cups-postscript your4-pagePDF > out.ps 2>log
> >>
> >> This tests the non-vendor part of the filtering system. View out.ps.
> >
> > View out.ps to check everything is visually in order ?
>

Done. The PPD is called  /etc/cups/ppd/Brother-HL-L2320D-series.ppd.
The out.ps looks fine. Also it confirms what I was hoping to be true, i.e.
the out.ps all pages are same size, some of the odd-sized (squarish) pages
have been trimmed down widthwise to fit into the A4 sized frame, but
barring that, it looks like something close to the PDF.

Cf. the section
> "Test if what the application had submitted to CUPS seems to be correct"
> in
> https://en.opensuse.org/SDB:How_to_Report_a_Printing_Issue
> how to use Ghostscript to view a PostScript or PDF file
> plus getting Ghostscript (error) messages in case of issues.
>

From the above link my first observation is that CUPS doesn't seem to be
removing the c* and d* files from print spool dir. For example here is what
I see:
root@shivalik:/var/spool/cups# ls -l
total 2604
-rw------- 1 root lp    1126 Sep 29 18:57 c00024
-rw------- 1 root lp    1126 Sep 29 21:40 c00025
-rw-r----- 1 root lp 1326607 Sep 29 18:57 d00024-001
-rw-r----- 1 root lp 1326607 Sep 29 21:39 d00025-001
even though the CUPS web-management dashboard (localhost:631) job status
for the printer shows both jobs as "completed". I don't seem to even need
to CUPS disable !

Having copied one of the d* files to tmp, I see this:
root@shivalik:/var/spool/cups# file /tmp/print-job-data.save
/tmp/print-job-data.save: PostScript document text conforming DSC level
3.0, Level 2

Launching Ghostscript, the Windows with 1 page shows up properly, and I see
this in terminal:
root@shivalik:/var/spool/cups# gs -r50 -sPAPERSIZE=a4 -dFIXEDMEDIA
/tmp/print-job-data.save
GPL Ghostscript 9.50 (2019-10-15)
Copyright (C) 2019 Artifex Software, Inc.  All rights reserved.
This software is supplied under the GNU AGPLv3 and comes with NO WARRANTY:
see the file COPYING for details.
Loading NimbusRoman-Regular font from
/usr/share/ghostscript/9.50/Resource/Font/NimbusRoman-Regular... 4379960
2871268 6472768 5156952 1 done.
>>showpage, press <return> to continue<<

and also,

root@shivalik:/var/spool/cups# gs -r50 -dNOPAUSE -dBATCH -sDEVICE=nullpage
/tmp/print-job-data.save
GPL Ghostscript 9.50 (2019-10-15)
Copyright (C) 2019 Artifex Software, Inc.  All rights reserved.
This software is supplied under the GNU AGPLv3 and comes with NO WARRANTY:
see the file COPYING for details.
Loading NimbusRoman-Regular font from
/usr/share/ghostscript/9.50/Resource/Font/NimbusRoman-Regular... 4397968
2884912 3358176 2038398 1 done.

From the above, doesn't look like (to my eyes) that there is any issue with
the generated .ps file. What should be my next steps ?

When the print is fired, I see visual activity in the printer i.e. the
'Ready LED' which was glowing steady bit dimly-lit until now, becoming
bright and start flashing.
As per printer manufacturer (or perhaps another post I read), this is
indication of exchange of data/control with host computer. However, the
drum & rollers don't whirr up (as they do in the case that printer seems to
accept a print job and print something).

> However, I do have one more basic question. If every page of the PDF
> > are of
> > different size (perhaps even non-standard page sizes), is CUPS filter
> > able
> > to convert them all into desired page-size (such as - say A4 or Letter)
> > ?
>
> You will see that by viewing out.ps what the outcome is
> in your particular case.
>
> Additionally you may have a look at the section
> "It always helps to simulate printout on a virtual generic PostScript
> printer"
> in
> https://en.opensuse.org/SDB:How_to_Report_a_Printing_Issue
_______________________________________________
cups mailing list
[email protected]
https://lists.cups.org/mailman/listinfo/cups
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.