A network printer is a hardware device that is directly connected to the network. This means the printer can be accessed from a print server without actually connecting it to the print server with a cable. The network printer has its own system name and IP address. Even though a network printer is not connected to a print server, it is necessary to set up a print server for the printer. The print server provides queuing capabilities, filtering, and printing administration for the network printer.
You can add a network printer by using the LP print service commands or by using Solaris Print Manager. For information about new printing features that are new or changed in this release, see What's New in Printing?.
Network printers might use one or more special protocols that require a vendor-supplied printing program. The procedures to set up the vendor-supplied printing program can vary. If the printer does not come with vendor-supplied support, the Solaris network printer support can be used with most devices. Use the print vendor-supplied software when possible.
The vendor might supply an SVR4 printer interface script to replace the standard printer interface script. If so, their SVR4 interface script calls the vendor-supplied printing program to send the job to the printer. If not, you need to modify the standard interface script to call the vendor-supplied printing program. You can do this by editing the per-printer copy of the standard interface script to call the vendor-supplied printing program.
The following terms are used in network printer configuration:
Print server – The machine that spools and schedules the jobs for a printer. The print server is the machine on which the printer is configured.
Printer-host device – The printer-host device is the software and hardware supplied by a vendor that provides network printer support for a non-network capable printer. The combination of the printer-host device with one or more printers attached to the device creates a network printer.
Printer node – The printer node is either the physical printer or the printer-host device. It is the physical printer when the network support resides in the physical printer. It is the printer-host device when an external box is used to provide the network interface. The printer node name is the machine name given with the IP address. This name is selected by the system administrator and has no default or vendor requirement. The printer node name, as with all nodes, must be unique.
Printer name – The name entered on the command line when using any of the printer commands. The printer name is selected by the system administrator at the time of printer configuration. Any one physical printer can have several printer or queue names; each provides access to the printer.
Destination or network printer access name – The internal name of the printer node port that is used by the printer subsystem to access the printer. The access name is the name of the printer node, or the name of the printer node with a printer vendor port designation. Any printer vendor port designation is explicitly defined in the printer vendor documentation. The designation is printer specific. If the printer is a printer-host device and a printer, the port designation is documented in the printer-host device documentation. The format is:
printer-node-name
or
printer-node-name:port-designation
Protocol – The over-the-wire protocol used to communicate with the printer. The documentation from the printer vendor supplies the information regarding the protocol to select. The network printer support supplies both BSD Printer Protocol and raw TCP. Due to implementation variations, you might want to try both.
Timeout, or retry interval Timeout – Is a seed number representing the number of seconds to wait between attempting connections to the printer. This seed number is the smallest amount of time to wait between attempted connections, and increases with an increase in failed connections. After repeated failures to connect to the printer, a message is returned to the user requesting possible human intervention. Attempts to reconnect continue until successful or the job is cancelled by the job owner.
Network printers often have software support provided by the printer vendor. If your printer has printer vendor-supplied software, use the printer vendor software when possible. The software is designed to support the attributes of the printer and can take full advantage of the printer capabilities. Read the printer vendor documentation to install and configure the printer under an LP print system.
If the network printer vendor does not provide software support, the Sun supplied software is available. The software provides generic support for network printers and is not capable of providing full access to all possible printer attributes.
A general discussion of how to add a network printer is provided in Chapter 4, Setting Up Printers (Tasks). The following is a discussion of printer management using the Sun supplied software.
The software support for network printers is called through one of the following interface scripts:
With PPD files — netstandard_foomatic
Without PPD files — netstandard
The configuring of a network printer with the network interface script causes the network printer support module to be called.
The command to configure the printer for network support with PPD files is as follows:
# lpadmin -p printer-name -m netstandard_foomatic |
The command to configure the printer for network support without PPD files is as follows:
# lpadmin -p printer-name -m netstandard |
The print subsystem uses BSD print protocol and raw TCP to communicate with the printer. The printer vendor documentation provides the information about which protocol to use. In general, the TCP protocol is more generic across printers.
Type one of the following commands to select the protocol:
# lpadmin -p printer-name -o protocol=bsd |
# lpadmin -p printer-name -o protocol=tcp |
If the protocol that is selected is the BSD print protocol, you can further select the order of sending the control file to the printer. Some printers expect the control file, then the data file. Others expect the reverse. For this information, see the printer vendor documentation. The default is to send the control file first.
Type either one of the following commands to select the order:
# lpadmin -p printer-name -o bsdctrl=first |
# lpadmin -p printer-name -o bsdctrl=last |
The system administrator selects the printer node name. This name must be unique, as with any node on the network. The printer node name is associated with the IP address of the printer.
The print subsystem requires access information for the printer. The subsystem uses the destination name when making the network connection to the printer. This name is supplied by the system administrator to the print subsystem by using the lpadmin command. It becomes part of the printer configuration database. The printer access name is the name of the printer node, sometimes qualified by a port name. Port designation varies across printer vendors. You will find information about port designation in the documentation that is provided with the printer by the printer vendor. The format of printer access name is:
printer_node-name[:port-designation]
A common port designation with TCP is 9100. If the printer node name is pn1, and the printer vendor defines the port as 9100, then the printer access name is: pn1:9100. To configure a printer in this case use:
# lpadmin -p printer_name -o dest=pn1:9100 |
When using the BSD protocol, the port designation might not be a number, but some name defined by the printer vendor, for example: xxx_parallel_1. If the printer node name is cardboard, then the printer access name is: cardboard:xxx_parallel_1. To configure a printer in this case use:
# lpadmin -p printer-name -o dest=cardboard:xxx_parallel_1 |
If there is no port designation, and the printer node name is newspaper, the printer access name is the printer node name: newspaper. To configure a printer in this case use:
# lpadmin -p printer_name -o dest=newspaper |
The timeout option allows the user to select the amount of time (in seconds) to wait between successive attempts to connect to the printer. Some printers have a long warm up time and a longer timeout value is advised. The default is 10 seconds.
The timeout value does not impact the success or failure of the print process. The value is a seed value which the software uses as the initial timeout count. On repeated failures, this count is increased. A message is sent to the spooler when repeated attempts to connect to the printer fail. This alerts the user that intervention might be required. The failure could be anything from the printer being turned off to the printer being out of paper. Should these messages be produced too often, for example when the printer is warming up, increasing the timeout value will eliminate spurious messages.
The system administrator can experiment to find the optimal timeout value. Type the following command to set the timeout value:
# lpadmin -p printer-name -o timeout=n |
Each network printer should have only one server that provides access to the printer. This restriction enables the server to manage the access to the printer and keep jobs coherent.
The default device for the network printer is /dev/null. This device is sufficient when there is only one queue for the printer. Should more queues be required, set the device to a file. This setting enables the print system to restrict access to the printer across queues. The following commands create a device file and configure it as the network printer device.
# touch /path/filename # chmod 600 /path/filename # lpadmin -p printer-name -v /path/filename |
The following is an example of how to create a device file called devtreedown.
# touch /var/tmp/devtreedown # chmod 600 /var/tmp/devtreedown # lpadmin -p treedown -v /var/tmp/devtreedown |
Connect the printer to the network and turn on the power to the printer.
Consult the printer vendor's installation documentation for information about the hardware switches and cabling requirements. Get an IP address and select a name for the printer node. This is equivalent to adding any node to the network.
Follow the printer vendor instructions to add the network printer.
Use the printer vendor instructions to configure the network printer. These instructions are specific to the vendor and printer.
Add client access to the new printer.
Now that the printer has been added, create access to the printer for the clients. For more information, see How to Add Printer Access by Using Solaris Print Manager.
Optional tasks to complete.
There are several optional tasks that you might want to complete when setting up a network printer. For pointers to the remaining tasks, see Setting Up Printing (Task Map).
In this release, the printer defintions that you can assign with Solaris Print Manager have been modified. For overview information about new or modified Solaris Print Manager features, see What's New in Printing?.
Select the system to be the print server.
Connect the printer to the network. Turn on the power to the printer.
Consult the printer vendor's installation documentation for information about the hardware switches and cabling requirements.
Start Solaris Print Manager on the print server.
For instructions, see How to Start Solaris Print Manager.
Select New Network Printer from the Printer menu.
The New Network Printer window is displayed.
Fill in the required fields with the appropriate information.
If you need information to complete a field, click the Help button.
For example, to add a new network printer with PPD files, complete the following fields:
Printer Name: Description: Printer Port: Printer Make: Printer Model: Printer Driver: Fault Notification: Destination: Protocol: Options: Default Printer Always Use Banner User Access List: |
The Printer Server field is filled in by Solaris Print Manager.
To add a new network printer without PPD files, complete the following fields:
Printer Name: Description: Printer Port: Printer Type: File Contents: Fault Notification: destination: Protocol: Options: Default Printer Always Use Banner User Access List: |
The Printer Server field is filled in by Solaris Print Manager.
To use Solaris Print Manager to add a new network printer without PPD files see Reverting to Previous Solaris Print Manager Printer Definition Screens.
Click OK.
Verify that the printer has been installed. Check for the new printer entry in the Solaris Print Manager main window.
Verify that the printer can print requests.
$ lp -d printer-name filename |
Exit Solaris Print Manager.
Choose Exit from the Print Manager Menu.
This procedure describes how to add a new network printer with the expanded printer support that is available in this release. There are two examples that follow this procedure. The first example shows you how to add a new network printer with PPD files by using lp commands. The second example shows you how to add a new network printer without PPD files by using lp commands.
The following steps are necessary to set up a network printer by using the network printer support software. The use of this software is intended for printers that do not come with vendor-supplied software.
For overview information about adding a new network printer or modifying an existing network printer with PPD files, see What's New in Printing?.
Connect the printer to the network, and turn on the power to the printer.
Consult the printer vendor's installation documentation for information about the hardware switches and cabling requirements. Get an IP address and select a name for the printer node. This step is equivalent to adding any node to the network.
Collect the information that is required to configure a new network printer with PPD files.
Printer name and port device
Network printer access name
Protocol
Timeout
File content type
PPD file
To determine the PPD file, first define the printer make, model, and driver that the printer will use.
For more information, see the terms that are described inAdding a Network Printer.
Define the printer name, port device, file content type, and PPD file that the printer will use. When using PPD files, the file content type is usually PostScript.
Specify the printer name and the port device that the printer will use.
# lpadmin -p printer-name -v /dev/null |
The device to use is /dev/null.
Specify the interface script that the printer will use.
# lpadmin -p printer-name -m netstandard_foomatic |
The interface script that is supplied with the support software for network printer is /usr/lib/lp/model/netstandard_foomatic.
Specify the file content type and PPD file that the printer will use.
# lpadmin -p printer-name -I content-type -n /usr/lib/lp/model/ppd/manufacturer/ppdfile |
The PPD file that you specify is located in the /usr/lib/lp/model/ppd/manufacturer/ directory
For more information, see lpadmin(1M).
Specify the printer description.
# lpadmin -p printer-name -D "printer-description" |
Set the printer destination, protocol, and timeout values.
# lpadmin -p printer-name -o dest=access-name:port -o protocol=protocol -o timeout=value |
-p printer-name |
Specifies the network printer name. |
-o dest=access-name:port |
Sets the printer destination to the network printer access name and a designated printer vendor port, if the port is defined in the printer vendor documentation. |
-o protocol=protocol |
Sets the over-the-wire protocol used to communicate with the printer. Both BSD and raw TCP are supported. |
-o timeout=value |
Sets a retry timeout value that represents a number of seconds to wait between attempting connections to the printer. |
(Optional) Add filters to the print server.
# cd /etc/lp/fd # for filter in *.fd;do > name=`basename $filter .fd` > lpfilter -f $name -F $filter > done |
Enable the printer to accept print requests and to print those requests.
# accept printer-name # enable printer-name |
Verify that the printer is correctly configured.
# lpstat -p printer-name |
Add client access to the new printer.
Now that the printer has been added, create access to the printer for the clients. For more information, see Setting Up a Print Client. For information about how to define a print client by using a name service, see
Complete any optional tasks.
There are several optional tasks that you might want to complete when setting up a printer. For pointers to the remaining tasks, see Setting Up Printing (Task Map). For information abot how to define print clients by using the name service, see Printing Support in the Name Service Switch.
This example shows how to add a new network printer with PPD files. The -n option to the lpadmin command enables you to add a new print queue by specifying PPD files. The commands used in this example must be executed on the print server. The following information is used as an example only. The information that you provide will vary.
Printer name : luna1
Device: /dev/null
Interface: /usr/lib/lp/model/netstandard_foomatic
Network printer access name: nimquat:9100
Protocol: tcp
Timeout: 5
File content type: postscript
PPD file: /usr/lib/lp/model/ppd/manufacturer/ppdfile
# lpadmin -p luna1 -v /dev/null 1 # lpadmin -p luna1 -m netstandard_foomatic 2 # lpadmin -p luna1 -o dest=nimquat:9100 -o protocol=tcp -o timeout=5 3 # lpadmin -p luna1 -I postscript 4 # lpadmin -p luna1 -n /usr/lib/lp/model/ppd/manufacturer/ppdfile 5 # lpadmin -p luna1 -D "Second floor color printer"6 # cd /etc/lp/fd # for filter in *.fd;do > name=`basename $filter .fd` > lpfilter -f $name -F $filter > done 7 # accept luna1 destination "luna1" now accepting requests # enable luna1 8 printer "luna1" now enabled # lpstat -p luna1 9 printer luna1 is idle. enabled since Mon Apr 19 15:31:15 2004. available. |
Defines printer name and sets the device to /dev/null
Defines the interface script for network printers
Sets the destination, protocol, and timeout
Specifies the file content types to which the printer can print to directly
Specifies the PPD file to use
Adds a description for the printer
Adds print filters to the print server
Accepts print requests for the printer and enables the printer
Verifies that the printer is ready to print
This example shows how to add a new network printer without PPD files. The commands must be executed on the print server. The following information is used as an example. The information that you provide will vary.
Printer name: luna1
Device: /dev/null
Interface: /usr/lib/lp/model/netstandard
Network printer access name: nimquat:9100
Protocol: tcp
Timeout: 5
File content type: postscript
Printer type: PS
# lpadmin -p luna1 -v /dev/null 1 # lpadmin -p luna1 -m netstandard 2 # lpadmin -p luna1 -o dest=nimquat:9100 -o protocol=tcp -o timeout=5 3 # lpadmin -p luna1 -I postscript -T PS 4# lpadmin -p luna1 -D "Room 1954 ps" 5 # cd /etc/lp/fd # for filter in *.fd;do > name=`basename $filter .fd` > lpfilter -f $name -F $filter > done 6 # accept luna1 destination "luna1" now accepting requests # enable luna1 7 printer "luna1" now enabled # lpstat -p luna1 8 printer luna1 is idle. enabled since Feb 28 11:21 2003. available. |
Defines printer name and sets the device to /dev/null
Defines the interface script for network printers
Sets the destination, protocol, and timeout
Specifies the file content type to which the printer can print directly, and the printer type
Adds a description for the printer
Adds print filters to the print server
Accepts print requests for the printer and enables the printer
Verifies that the printer is ready for printing