System Administration Guide: Solaris Printing

Chapter 1 Introduction to Printing in the Solaris Operating System

This chapter provides an introduction to printing in the Solaris Operating System ( Solaris OS). Conceptual information about Solaris printing services, tools, and protocols is described. Each of the subsequent chapters in this book describe how to use these tools, protocols, and technologies to administer printing services and printers.

Several terms and concepts that are introduced in this chapter and are used frequently throughout this book. To fully grasp printing concepts, a basic understanding of these concepts and terms is essential. For a complete listing of all the printing concepts and terms, see Glossary.

This is a list of the information in this chapter.

What's New in Printing?

This section describes new and changed printing features in this Solaris release. For a complete listing of new Solaris features and a description of Solaris releases, see Solaris Express Developer Edition What’s New.

Common UNIX Printing System

Solaris Express Community Edition, build 87: The Common UNIX Printing System (CUPS), Version 1.3.6, is now part of the Solaris OS distribution.

The Common UNIX Printing System (CUPS) is a modular printing system that enables a system to function as a print server. A system that is running CUPS is a host that can accept print requests from client systems, process the requests, then send them to the appropriate printer.

To facilitate this support in the Solaris OS, the following interfaces have been introduced:

For more information, see the CUPS documentation page, at The complete set of CUPS documentation is also accessible from a CUPS server on a host that is running CUPS by typing http://localhost:631/help/ in a web browser.

OpenSolaris Print Manager

Solaris Express Community Edition, build 97 and OpenSolaris 2008.11 release: The OpenSolarisTM Print Manager application is a graphical user interface (GUI) that you can use to manage local and remote printer queues, printer groups, and print jobs. Print Manager enables you to perform many aspects of printer administration. You can run the OpenSolaris Print Manager application from the Main Menubar on the GNOME desktop panel. For more information, see Chapter 10, Setting Up and Administering Printers From the Desktop (Tasks).

Automatic Printer Discovery and Configuration in the Desktop Environment

OpenSolaris 2008.05: The Solaris OS has the capability to automatically discover directly attached and network-attached printers. This service is implemented through the Hardware Abstraction Layer (HAL) and has the capability to detect SNMP capable printers on a on network where a Solaris host is attached. This functionality is managed by the Service Management Facility (SMF) and can be enabled by using the svcadm command. Authorizations that are required to use this feature have been added to the Print Management user profile. See Chapter 10, Setting Up and Administering Printers From the Desktop (Tasks) for further details of this feature.

This feature provides the following types of support:

The detection component has the ability to discover USB printers that have been physically connected to or disconnected from a local system. The configuration component enables you to configure certain properties of directly attached USB printers. The notification component lets you know when a printer has been connected or disconnected from the local system.

Automatic printer discovery includes enhanced hardware abstraction layer (HAL) support for recognizing USB printer hotplug events, as well as network attached printers on a Solaris hosted network. HAL USB support was introduced in the Solaris Express Developer Edition 5/07 release. The hardware abstraction layer (HAL) daemon, hald, provides a view of devices that are attached to a local system. This view is updated automatically as a system's hardware configuration changes, by hotplugging or other methods. You can find out more about HAL at

More information can be found at

For step-by-step instructions, see Chapter 10, Setting Up and Administering Printers From the Desktop (Tasks).

More information about other OpenSolaris printing projects can be found at

Privilege Requirements for Using Solaris Print Commands

The design of the Open Standard Print API (PAPI) implementation in the Solaris release makes it no longer necessary for applications, toolkits, and print commands to run with elevated privilege to interact with print services.

As a result, the following print commands are no longer installed SUID root:

Previsously, these commands were installed SUID root because the commands required an elevated privilege for the following purposes:

This functionality is now localized in a small helper application, /usr/lib/print/lpd-port. As a result, any applications that use RFC-1179 PAPI support no longer require elevated privilege. The lpd-port helper application contains minimal support for passing RFC-1179 protocol requests on a reserved port and allocating sequential job-id numbers. Although the helper application is installed SUID root, all elevated privileges are dropped until they are required. When necessary, the privilege is elevated for the required operation and then permanently dropped if the elevated privilege is no longer required. In the Solaris release, this process is accomplished through the use of privileges. On other platforms, the process is accomplished by using the setuid, seteuid, or setreuid functions.

If you have local printers that you do not want to share on the network, you can safely disable the printing network listeners. If you are running the Solaris release, or a CUPS server, the lpstat command provides you with more information about remote print queues and print jobs, as well as their capabilities when using IPP to communicate with those servers.

When IPP is in use, and with the proper authorization, the following operations can be performed on remote print queues and print jobs:

Also, you can now move print requests between queues on a print server and modify print requests remotely when IPP is in use.

For more information, see the privileges(5) man page. For step-by-step procedures, see Administering Printers by Using the Internet Printing Protocol (Task Map).

PPD File Management Utility

Solaris Express Developer Edition 5/07: The PPD File Manager, /usr/sbin/ppdmgr, is a utility for administering PostScriptTM Printer Description (PPD) files that are used with the Solaris print subsystem. When you add a PPD file to the system by using the ppdmgr utility or the lpadmin command with the -n option, a cache of PPD file information is automatically updated. This cache is used by Solaris Print Manager and the printing tools that are available in the GNOME Desktop Environment.

For more information, see Administering PPD Files by Using the PPD File Management Utility (Task Map) and the ppdmgr(1M) man page.

Fundamentals of Printing in the Solaris Operating System

The Solaris printing software provides an environment for setting up and managing print servers and print clients.

The Solaris printing software contains these tools and services:

For more information, see Chapter 5, Administering Printers by Using Solaris Print Manager and LP Print Commands (Tasks).

The Solaris printing software includes these additional interfaces, protocols, and technologies:

Overview of the Solaris Printing Architecture

At the core of the print system is a UNIX System V (R4) based spooler. In addition to the spooler are client applications that are used to make requests of and manage the spooler. filters that perform document translation, back-end processing software that performs final document transformation , and device (printer) communication. To utilize the complete functionality of the print system, all these resources are required.

Printing in the Solaris OS consists of the software to support the following:

The following figure is a high level diagram that represents the Solaris print system components.

Graphic of LP client-server relationship, with applications
that use the print service. The surrounding text provides details.

Recent changes in Solaris printing include the integration of IPP client-side support, implemented through the PAPI. The Berkeley Software Distribution (BSD) and System V (SysV) commands, as well as some applications, are layered on top of the PAPI interface. See Implementation of the Open Standard Print API.

Implementation of the Open Standard Print API

The Solaris implementation of the Open Standard Print API, also referred to as PAPI, makes it possible to layer applications, toolkits and print commands on top of a print service, protocol neutral interface. This implementation can be used with RFC-1179, IPP-based, and LP-based printing services. Printer, server, and job attributes, as well as job submission and queries to a printer, are among the supported PAPI functions. This support enables the print client, be it an application, or the print commands themselves, to query the print system about the characteristics of a printer and to request information.

For more information, see the following references:

PAPI Print Client Commands

Historically, printing commands have been tied to a specific print system because they have been implemented on top of print system specific protocols and interfaces. Examples include the BSD, LPR, SysV LP, LPRng, and CUPS printing protocols. The introduction of the PAPI, makes it possible to layer these print commands on top of a print service, protocol neutral, interface.

The PAPI provides applications a single interface for print service interaction. This means that applications can be written to use this interface and work with a variety of print services without requiring changes to the applications. Applications are no longer tied to a particular print service, such as the LP print service or CUPS. Instead, print services can easily be replaced on a system without impacting the protocol or application layers above. Ultimately, print services can be both developed and selected based on specific needs.

The PAPI interacts with the lpsched command and RFC-1179-based servers. PAPI also enables interaction with CUPS servers by using libcups and native IPP client-side support. The PAPI supports that is available in the Solaris OS includes the modification of several common BSD and SysV printing commands. The new command implementations are layered on the PAPI. Hence, these commands can work with a variety of printing services.

The PAPI implementation in the Solaris OS also includes server-side and client-side support for IPP, which is layered on top of the PAPI. IPP is implemented as a set of protocol-specific libraries and an Apache module. Like the command implementations, the IPP Listening Service can be used with any printing service that supports the PAPI. Server-side support for the RFC-1179 protocol is also available. For more information, see Chapter 3, Setting Up Printing Services (Tasks).

The following is a list of the PAPI supported components:

Using Printing Protocols in the Solaris Release

The overall printing architecture in the Solaris OS uses network printing protocols to communicate with print services in following ways:

The Solaris Express software provides applications, toolkits, printing commands, and an application programming interface that interacts with print services. This API is called the PAPI. The PAPI consists of a front-end API implementation that dynamically loads back-end print service or protocol modules that communicate directly with print services. These print services contain the print job or print queue that is being acted upon. Client-to-server communications include the RFC-1179 and IPP protocols, as well as support for communicating with a local LP print service. For server-to-printer communications, the network printing protocol support enables the print service to transmit print jobs directly to network-attached printers.

Server-to-printer communications include support for the following network protocols:

Selecting the Client-To-Server Network Printing Protocol

Applications, toolkits, and printing commands select the protocol to use for client-to-server communications, based on the value of the printer-uri-supported attribute that is found in the printers.conf database entry for the specified print queue. This value is automatically generated and populated when access to a remote print queue is configured by using the lpadmin command or when an application uses the interface that is being referenced to perform an action or actions.

For example, when printing a document while using Mozilla, the path that is followed to gain access to the printer is:

Mozilla -> lp -> PAPI

For more information, see the printers.conf(4)

The lpadmin command generates printer-uri-supported values using the following format:


To determine which URI to use in the printers.conf database, the lpadmin command probes the remote print service. If the remote print service supports IPP, this protocol is preferred over the BSD protocol. However, you can override automatic protocol selection by specifying the -soption with the lpadmin command, then supplying a different URI. For more information, see the Printer URI Formats.

The print subsystem uses the BSD print protocol, also referred to as the RFC-1179 protocol, and raw Transmission Control Protocol (TCP), the basic communication language or protocol of the Internet, to communicate with the printer. If you are setting up a printer that includes printer vendor documentation, information about which protocol to use is provided. The TCP protocol is the protocol that is most often used for printing on the network.

Printer URI Formats

The following are supported printer URI formats:

Table 1–1 Supported URI Formats for Print Commands



This printer URI scheme can only be used to contact a local LP service to access the print queue that is specified in the URI. 



Use this printer URI scheme to contact local or remote print services to address the specified print queue on the host that is specified in the URI. The optional #extensions can be specified as #solaris to indicate that the server host will process Solaris extensions to the RFC-1179 protocol during print job submission.





Use this printer URI scheme to contact local or remote print services to address a particular print queue on the host that is specified in the URI. The IPP URI scheme is described in the IPP specifications. This printer URI scheme utilizes more of a free form than the LPD printer URI scheme. All of the Solaris and CUPS-based print queues are accessed by using these schemes, or formats. Access to print queues on other IPP-based print servers requires the use of the server supported IPP URI scheme. Typically, the scheme that is used is one those that are listed in this table. 

Selecting the Server-To-Printer Network Printing Protocol

Network-attached printers often support more than one method of communicating with a print service. The most common method of communicating with the print service is through a raw TCP connection to a well-known port on the device. Other methods of communication include the RFC-1179 and IPP network protocols. You can select the server-to-printer communication protocol when adding a new print queue in one of following ways:

When determining which protocol to use for server-to-printer communication, consult the vendor printer documentation for more specific information. Documentation includes information such as TCP port numbers, RFC-1179 printer names, and the IPP printer URIs that are supported by the device. In most instances, a raw TCP socket communication is likely to provide the most reliable results.

Also, note that due to differences between printing services on UNIX and Windows platforms, Windows hosted printers should be configured as network-attached printers and administered as such. These types of printers require the creation of a print queue if you are using them on a Solaris system. These printers might also use the SMB protocol for server-to-printer communication. For more information about the SMB protocol, see Using the SMB Protocol.

For more information about setting up printers and configuring print queues, see Setting Up Printers on a Print Server (Task Map).

What is a Device URI?

A Uniform Resource Identifier (URI) is an addressing technology for identifying resources on the Internet or a private intranet. The terms URI and URL are used synonymously. URIs can be used with application-level protocols, called URI schemes. The Solaris printer software includes support for configuring network-attached printers. When creating print queues for network-attached printers by using LP print commands or by using Solaris Print Manager, you can specify the device as a device-uri.

To specify the device as a device-uri from the command line, use the lpadmin command with the -v and -m options:

# lpadmin -p printer -v device-uri -m uri

Note that the -v option is still a valid option for specifying devices other than those that utilize the device-uri. addressing technology.

For example, to add the printer, Lucille, by using the device-uri, smb://server/queue, and the interface script that is included in the Solaris printer software, type:

# lpadmin -p lucille -v smb://server/print-queue -m uri -n /usr/lib/lp/model/ppd

Note –

You must use the -m option in the command-line syntax to specify an interface script, or the back-end process ignores the print request. The script can be the interface script that is included in the Solaris printing software or another interface script that is device-uri protocol aware.

The following device-uri schemes are supported:

To specify a device that uses a device-uri when using Solaris Print Manager to add a network-attached printer, select the URI option in the Protocol drop-down menu of the New Network Printer window. Type a supported printer URI in the destination field.

Other modifications that support setup of remote print queues by specifying the device as a device-uri include the following:

What Is the Internet Printing Protocol?

IPP is a fairly recent industry standard network printing protocol that is used for client-to-server and server-to-printer communications. This protocol provides a basic model that includes printers and jobs, standard attributes for these printers and jobs, and a set of standard operations that can be performed against these printers and jobs. Because the objects, attributes, and operations are standardized, IPP is a method for communicating between client and server systems. In the Solaris OS, server-side support for this protocol is provided by an IPP listening service. IPP client-side support in the Solaris OS is implemented through the PAPI. IPP printer support is available through the URI interface script.

More information about OpenSolaris printing can be found at

For step-by-step procedures and additional background information in this document, see Setting Up the Internet Printing Protocol and Appendix A, Using the Internet Printing Protocol.

Overview of the RFC-1179 Printing Protocol

The RFC-1179 protocol is an existing over-the-wire protocol that is widely used for communicating between print clients and servers and network-attached printers. The Request for Comments (RFC) 1179 describes the protocol that a line printer daemon client uses to control printing. Developed originally for BSD UNIX, the RFC-1179 printing protocol has long been the cross-platform standard for printing. You can use this protocol to perform basic printing tasks, such as submitting and canceling print jobs, and obtaining print job status. The RFC-1179 protocol is able to communicate with LPD-based print servers and any other print server that accepts the BSD printing protocol. Many network-attached printers offer this protocol as an option for transferring job data.

RFC-1179 Protocol Compared to the Internet Printing Protocol

The RFC-1179 protocol has served for decades as the standard network printing protocol. The protocol was originally designed to perform a very limited set of operations. The RFC-1179 protocol lacks a common representation for status information. In addition, this protocol offers only basic print job options. Conversely, the design of IPP includes features that are lacking in the RFC-1179 and BSD protocols. With IPP, a broad set of operations can be performed. These operations make use of a core set of common attributes by using a common representation and encoding method. Also, IPP enables encryption and authentication to be used between a print client and a print server. Finally, IPP provides a means for extending operations and attributes, while maintaining backward compatibility and interoperability. One of the results of the evolution of the RFC-1179 protocol is that it has several conflicting vendor extensions to overcome, making IPP the preferred choice of printing protocols.

For more information about using IPP to set up and administer printers, see Setting Up the Internet Printing Protocol and Appendix A, Using the Internet Printing Protocol.

Using the SMB Protocol

The SMB protocol is an application-level network protocol that is primarily used for sharing printers, access to files, serial ports, and miscellaneous communications between nodes on the network. Mainly used by Windows systems, SMB is an authenticated inter-process communication mechanism. In the Solaris OS, the SMB protocol is used primarily for sharing printers. All of these processes take place over the network. SMB can run over multiple protocols.

SMB works through a peer-to-peer approach. A client makes a specific requests to a server, and the server responds accordingly. SMB servers make their file systems and other resources available to clients on the network. In the Solaris OS, SMB includes Samba server-side support that is managed by the Service Management Facility (SMF) and Samba smbclient client-side support. To access a Windows hosted printer, setup of a local print queue is required. This requirement is due to differences in UNIX and Windows printing models.

About Samba

Samba is an open-source SMB server freeware application that uses the SMB protocol. Samba provides Windows clients access to UNIX servers and UNIX clients access to Windows servers. The access that is provided is for both files and other services, including printer sharing. Samba's design, as well as constraint, is to operate on top of a variety of existing UNIX systems. Samba runs as a set of daemons and services, without any need for modification of existing kernels. More information about Samba can be found at

Overview of Solaris Print Manager

Solaris Print Manager is a JavaTM technology-based GUI that enables you to manage local and remote printing configuration. This tool can be used in the files, LDAP, NIS, and NIS+ naming service environments.

To use this tool, you must:

Solaris Print Manager centralizes printer information when the information is used in conjunction with a naming service. Using a naming service for storing printer configuration information is the preferred method, because a naming service makes printer information available to all systems on the network. This method provides easier printer administration. Solaris Print Manager recognizes existing printer information on print servers, print clients, and in the naming service databases. No conversion tasks are required to use Solaris Print Manager as long as the print clients are running at least the Solaris 2.6 release.

The Solaris Print Manager package is SUNWppm.

Overview of the LP Print Service

The LP print service is a set of software utilities that enables users to print files while continuing to work. Originally, the print service was called the LP spooler. LP represents line printer, but the meaning now includes many other types of printers, such as laser printers. Spool is an acronym for Simultaneous Peripheral Operations Online.

The LP print service consists of the LP print service software, any print filters you might provide, and the hardware, such as the printer, system, and network connections.

Solaris Express 8/06: Starting with this release, the LP print client commands make use of the PAPI to interact with Solaris LP (lpsched), RFC-1179 (BSD/LPD protocol), and IPP-based servers. IPP support is capable of interacting with CUPS servers by using its native IPP service. With the introduction of this API support, several common BSD and SysV printing commands use the PAPI interface. As a result, the new command implementations work with a number of existing print services. A portion of this development includes server-side support for IPP that is also layered on the API. This support is implemented as a set of protocol-specific libraries and as an Apache module, Versions 1 and 2. Similar to the print command implementation, the IPP listening service can be used with any print service that has PAPI support. The RFC-1179 server-side support is also layered on the PAPI.

For additional information about the LP print service, see LP Print Service.

Functions of the LP Print Service

The LP print service performs the following functions:

Customizing the LP Print Service

Although the LP print service is designed to be flexible enough to handle most printers and printing needs, the LP print service does not handle every possible situation. You might have a print request that is not accommodated by the standard features of the LP print service. Or, you might have a printer that does not quite fit into the way the LP print service handles printers.

You can customize the LP print service in the following ways:

For detailed descriptions and step-by-step instructions on customizing the LP print service, see Chapter 7, Customizing Printing Services and Printers (Tasks).

The Solaris Print Client-Server Process

This section provides an overview of the print client-server process.

Using Print Servers

The print server is a system that has a local printer connected to it and makes the printer available to other systems on the network. The following figure highlights the part of the print process in which the print server sends the print request to the printer.

Figure 1–1 The Print Server Sends a Print Request to the Printer

Illustration of a print server sending a print request
in 5 steps. See the following description of these 5 steps.

  1. The print client submits a print request.

  2. The print request is processed on the print client.

  3. The print request goes to the print server.

  4. The print request goes to the printer.

  5. The print output is produced on the printer.

Using Print Clients

A print client is a system that can send print requests to a print server.

The following figure highlights the part of the print process in which the user submits a print request from a print client.

Figure 1–2 The User Submits a Print Request from a Print Client

Illustration of what happens when a user submits a print
request. See the following section for a description of these 5 steps.

The Print Client Process

The following figure illustrates the path of a print request from the time the user initiates the request until the print request is printed.

Figure 1–3 Overview of the Print Client Process

Illustration of the print client process in 5 steps.
See the following description of these 5 steps.

  1. A user submits a print request from a print client.

  2. The print command checks a hierarchy of print configuration resources to determine where to send the print request.

  3. The print command sends the print request directly to the appropriate print server. A print server can be any server that accepts Berkley Software Distribution (BSD) printing protocol, including System V Release 4 (SVR4), or LP print servers and BSD LPD-based print servers, as well as servers that accept IPP.

  4. The print server sends the print request to the appropriate printer.

  5. The print request is printed.

How Local Printing Works

The print request follows the same path it would if the client and server were separate systems. Requests always flow from client to server following the same path.

The following figure shows what happens when a user submits a request to print a PostScript file on a local printer, which is a printer connected to the user's system. The lpsched daemon on the local system does all processing.

This processing might include the following:

The printer interface program does the following:

Graphic is described in the surrounding text.

How LP Administers Files and Schedules Local Print Requests

The LP print service has a scheduler daemon called lpsched. The scheduler daemon updates the LP system files with information about printer setup and configuration.

The lpsched daemon schedules all local print requests on a print server, as shown in the following figure. Users can issue the requests from an application or from the command line. Also, the scheduler tracks the status of printers and filters on the print server. When a printer finishes a request, the scheduler schedules the next request n the queue on the print server, if a next request exists.

Graphic is described in the surrounding text.

Without rebooting the system, you can stop the scheduler with the svcadm disable application/print/server command. Then, restart the scheduler with the svcadm enable application/print/server command. The scheduler for each system manages requests that are issued to the system by the lp command.

How Remote Printing Works

The following figure shows what happens when a user on a Solaris print client submits a print request to an LPD-based print server. The command opens a connection and handles its own communications with the print server directly.

Illustration of a Solaris print client sending a print
request to an LPD-based print server where it is accepted, spooled, and scheduled
for printing.

The following figure shows an LPD-based print client submitting a print request to a Solaris print server. The lpd daemon handles the local part of the print request and the connection to the print server. On the print server, the inetd process waits for network printing requests and starts a protocol adaptor to service the request. The protocol adaptor communicates with the lpsched daemon, which processes the request on the print server.

Graphic is described in the surrounding text.

The following figure shows what happens when a user on a Solaris print client submits a print request to a Solaris print server. The print command on the print client handles the local part of each print request by communicating directly with the print server.

Graphic is described in the surrounding text.

The inetd process on the print server monitors network printing requests and starts a protocol adaptor to communicate with the lpsched daemon on the print server, which processes the print request.

Where to Find Printing Tasks

Printer Task 

Topics Covered 

For More Information 

Set up and administer printing services. 

Setting up Solaris Print Manager, the LP print service, and the IPP, RFC-1179, and SMB printing protocols. 

Chapter 3, Setting Up Printing Services (Tasks)

Set up printers. 

Setting up a print server, adding directly attached and network-attached printers, and adding a print client. 

Chapter 4, Setting Up Printers (Tasks)


Administering printers, the print scheduler, setting printer definitions, and administering print requests by using the following printing tools, services and protocols:

  • Solaris Print Manager

  • LP print service

  • IPP

  • RFC-1179 protocol

  • SMB protocol (through Samba)

Chapter 5, Administering Printers by Using Solaris Print Manager and LP Print Commands (Tasks)

Chapter 6, Administering Printers That Use Network Printing Protocols (Tasks)

Administer PPD files by using the PPD File Manager (ppdmgr).

Administering PPD Files on a system by using the ppdmgr utility, a tool that automates PPD file administration.

Chapter 9, Administering Printers by Using the PPD File Management Utility (Tasks)

Set up and administer printers from the Desktop. 

Setting up USB directly attached and network-attached printers from the desktop. 

Chapter 10, Setting Up and Administering Printers From the Desktop (Tasks)

Customize printing services and printers. 

Customizing printing services. Administering character sets, print forms, print filters, and print fonts. 

Chapter 7, Customizing Printing Services and Printers (Tasks)