Printer Classes

A class of printers may be defined in the LP spool system. A printer class is a named collection of local printers of similar type. For example, if a host has two printers connected, a LaserJet Plus and a LaserJet III, then class •laserjet" could be created with both printers as members of the class. If a print request names a class, rather than a specific printer, as the desired destination then the request is printed on the first available member of the class. Thus, specifying destination •laserjet" in a request on our example host prints the request on either the LaserJet Plus or the LaserJet III, depending on which printer first becomes available. A printer may be a member of only one class. Neither remote printers nor network peripherals may be made members of a class.

Classes are created and deleted using the lpadmin program. Many programs in the LP spool system accept parameters called a destination. A destination may be either the name of a printer or the name of a class.

Destination Availability

Each destination, either a class or printer, on a host may be set to either accept or reject new requests. At the time a new destination is added to the system, it is initially set to reject submissions. If an attempt is made to enter a request locally via the LP program or from a remote host, the new request is rejected. When the system administrator verifies that the system is ready for requests to be entered for the destination, the destination may be set to accept submissions using the accept program. The destination may later be set to reject new submissions using the reject program. This might be done when a printer must be taken out of service for an extended period of time, for example.

Each printer in the system, local or remote, is either enabled or disabled at any time. The spooler will not send requests to a printer that is disabled. New requests may be entered for a disabled printer, but the requests are not sent to the printer while it is disabled. Requests entered for a class of which the printer is a member are printed on another, enabled member. At the time a new printer is added to the system, it is initially disabled. When the system administrator verifies that the printer is ready to print requests, it may be enabled using the enable program. The printer may later be disabled using the disable program. This might be done when a printer must be taken out of service for a short time, such as to load new paper.

Thus, for a request to be sent to a printer there are two conditions that must be met: either the printer or a class of which it is a member must accept new submissions, and the printer must be enabled.

24 LP Spool System