Printer classes

Michael Sweet mike at easysw.com
Wed Mar 8 06:26:42 PST 2006


Michael De Vlaminck wrote:
> Hello,
> 
> When using printer classes, a job sent to a class is sent to the
> first available printer in that class. But how does cups decide what
> printer is the first available? For example when you have a printer A
> with 4 jobs on queue and another printer B with only 2 job on queue.
> The first available printer can be B because it has only 2 jobs. But
> those 2 jobs can be very large so that printer A (with 4 small jobs)
> will be the first available. How exactly is it decided which is the
> first availble printer?

The job is queued on the class.  It doesn't get assigned to a
printer until a printer becomes available, and then CUPS keeps
track of the "next" printer to use in the class.

Um, let's say you have called MyClass with two printers, MyPrinter1
and MyPrinter2.  A user sends 3 jobs to MyClass, which normally will
print on MyPrinter1, then MyPrinter2, and finally MyPrinter1.  When
the next job comes in for MyClass, it will print on MyPrinter2 if
MyPrinter2 is not busy.

If MyPrinter1 or MyPrinter2 is busy when they are the next printer
to use, then CUPS moves on until it finds an available printer.  If
no printers are available when it checks, it will retry when one of
the printers becomes available.

-- 
______________________________________________________________________
Michael Sweet, Easy Software Products           mike at easysw dot com
Internet Printing and Document Software          http://www.easysw.com




More information about the cups mailing list