apple / cups

Apple CUPS Sources
https://www.cups.org
Apache License 2.0
1.94k stars 464 forks source link

efficient parallel printing of the same document to N identical printers #6220

Open milahu opened 3 months ago

milahu commented 3 months ago

cups is slowing down my printing process

when i send the same document to 10 identical printers then cups runs the same filter pipeline 10 times

expected

cups should run the filter pipeline once and send 10 copies of the result to my 10 identical printers

example

82 A4 pages 20 pages per minute duplex (Brother HL-L5100DN) each printer takes 250 seconds

1 printer high cpu load for 30 seconds

  0 send job: lp input.pdf -d my_printer
 28 printer starting
276 printer done

6 printers high cpu load for 180 seconds

  0 send 6 jobs: lp input.pdf -d my_printer
 68 first printer starting
112 last printer starting
318 first printer done
362 last printer done

362 versus 276 seconds = 30% slower

considering the network traffic (100 Mbit/s) sending the same document to 6 identical printers should have an overhead between 1% and 5%

workaround

for now, i would be happy with a workaround where i run the filter pipeline manually and call lp final.xyz -d my_printer_$x

how would that work?

keywords

related

dkosovic commented 2 months ago

The Brother HL-L5100DN supports the following according to the link you posted:

It also supports AirPrint according to the following page:

As it supports AirPrint, it also effectively supports IPP Everywhere.

Add the printers as IPP Everywhere print queues, assuming you are using their Ethernet ports and they have IP addresses, e.g.: sudo lpadmin -p queue1 -v ipp://xxx.xx.xxx.xx/ipp/print -m everywhere

As the printer has native PDF support, it'll be PDF in and PDF out for CUPS with close to zero CPU overhead for the QPDF based pdftopdf filter that comes with cups-filters.

You've posted this issue to Apple CUPS, but appear to be using OpenPrinting CUPS which has its own issues page: