Solstice AdminSuite Print Administration Guide

Printer Configuration Resources

This section describes the resources that the SunSoft print client commands use to locate printer names and printer configuration information.

The SunSoft print client commands can use a name service, which is a network (shared) resource for storing printer configuration information for all printers on the network. The name service (NIS or NIS+) simplifies printer configuration maintenance: When you add a printer in the name service, all SunSoft print clients on the network can access it.

Figure 1-3 highlights the part of the print process in which the SunSoft print client commands check a hierarchy of printer configuration resources to determine where to send the print request.

Figure 1-3 The SunSoft Print Client Commands Check Resources to Locate Printers

Graphic

The Advantages of SunSoft Print Client Commands in Locating Printers

The print configuration resources are a key component of the SunSoft Print Client software: They increase printing efficiency because of the method they use to locate printer information. To illustrate the advantages, the next sections compare the Solaris 2.x and SunSoft methods to locate printers.

How the Solaris 2.x Print Software Locates Printers

As shown in Figure 1-4, the print command in the Solaris 2.x (SunOS 5.x) operating environment uses only local resources to locate printers and printer configuration information.

Figure 1-4 How the Solaris 2.x Print Software Locates Printers

Graphic

  1. A user submits a print request from an SVR4 print client by using the lp or lpr command. The user can specify a destination printer name or printer class with either the lp -d or lpr -P command and option, as shown in these examples:


    % lp -d neptune
    

    % lpr -P pluto
    
  2. The print command locates a printer and printer configuration information.

    • It checks to see if the user specified a destination printer name or printer class when submitting the print request.

    • If the user didn't specify a printer name or class, the software checks the SVR4 print client's /etc/lp/default file for a default printer name.

    • When the print client software finds the printer name or class, or has located a default printer, it checks the SVR4 print client's /etc/lp/printers directory for configuration information on the printer or printer class.

There are two main disadvantages in the Solaris 2.x method to locate printers:

How the SunSoft Print Client Software Locates Printers

As shown in Figure 1-5, the SunSoft print client commands use more options to locate printers and printer configuration information.

Figure 1-5 How the SunSoft Print Client Software Locates Printers

Graphic

  1. A user submits a print request from a SunSoft print client by using the lp or lpr command. The user can specify a destination printer name or class in any of three styles:

    • Atomic style, which is the print command and option followed by the printer name or class, as shown in the next example.


      % lp -d neptune
      
    • POSIX style, which is the print command and option followed by server:printer, as shown in the following example.


      % lpr -P galaxy:neptune
      
    • Context-based style, as defined in the Federated Naming Service Programming Guide in the Solaris 2.5 Software Developer AnswerBook, shown in the next example.


      % lp -d thisorgunit/service/printer/printer-name
      
  2. The print command locates a printer and printer configuration information as follows:

    • It checks to see if the user specified a destination printer name or printer class in one of the three valid styles.

    • If the user didn't specify a printer name or class in a valid style, the command checks the user's PRINTER or LPDEST environment variable for a default printer name.

    • If neither environment variable for the default printer is defined, the command checks the .printers file in the user's home directory for the _default printer alias.

    • If the command does not find a _default printer alias in the .printers file, it then checks the SunSoft print client's /etc/printers.conf file for configuration information.

    • If the printer is not found in the /etc/printers.conf file, the command checks the name service (NIS or NIS+), if any.

These are the advantages of the SunSoft method to locate printers:

When to Use a Name Service

The comparison of the Solaris and SunSoft print configuration resources in "Printer Configuration Resources" points out the advantages you can gain by using NIS or NIS+ with the SunSoft Print Client software. A name service provides the most efficient way to add, modify, and delete printer configuration information for a network.

Almost every site can benefit significantly from using a name service. One exception might be a very small network with only a few printers and print clients.