AB 130/1 INFORMATION RELEASE 4c

edplogo.gif (5330 bytes)

GUIDE TO SETTING UP A TCP NETWORK PRINTER

This Admin Bulletin AB130/1 is a complete reissue of AB130.

Remove and destroy existing AB130 and replace with this AB130/1

NOTE: Throughout this FECO a SPACE in a string is shown by a Ñ .

              All other spaces are purely cosmetic

For the general purposes of this and subsequent actions, both a network printer itself and the various network printer adapter products shall be referred to at various times as "the printer" and "the network printer".

1      DEFINE THE NETWORK CHARACTERISTICS OF THE PRINTER/PRINT ADAPTER

            The "IP Address", the "Gateway Address", and the "Sub-Net Mask" for the printer are all-important,
            and can be obtained by contacting the LAN administrators of the network to which the printer will be
            attached. The LAN administrator will ensure that the printer’s IP address is unique. In addition, the
            LAN administrator will assign a "network nodename" to the IP address.

2      SETTING UP THE PRINTER OR THE PRINT ADAPTER:

            You must read the network printer’s documentation quite carefully; imbedded in the text somewhere
            is a vital piece of information which is critical to the success of the following steps. That piece is the
            4-digit "port number" on which the network printer’s CPU programming depends for incoming print
             jobs (or messages) to be routed. Several popular examples are already available.

            2000 is the port number for a Milan_Print_Server,
            2501 is the port number for a Ricoh_Print_Server,

            2766 is the port number for a QMS_Printer,
            4010 is the port number for a Netgear_Print_Server, Port 1,
            4020 is the port number for a Netgear_Print_Server, Port2, and

            9100 is the port number for a HP_LaserJet_4_si_MX.

            In addition to the port number, one must also become familiar with the directions for setting up the
            "IP Address", the "Gateway Address", the "Sub-Net Mask", and the "network nodename". Each
            of these TCP/IP parameters is critical to the ability of the printer to properly receive and print incoming
             jobs. The values for these parameters are assigned by the LAN administrator. If you do not already
            have this information, please stop at this point, contact you network administrator, and get this data.

            Once you have these 5 pieces of information, you may setup the printer’s internal network parameters.
            Refer to the User’s or Administrator’s Guides that were shipped with the product for further
            configuration information. Make certain that recommended steps are not skipped, nor are
            recommended tests overlooked. Paying close attention to detail at this time will prevent a LAN
            disaster from happening later.

            When you are sure that the printer is configured, you may test it by performing a telnet to the port on
            the printer. For a Milan print adapter with an IP address of 153.78.113.168, the operation would be:

$ telnet Ñ 153.78.113.168 2000 <CR>

            One should expect the HP LaserJet 4 to be accessible in the same manner, and it is:

$ telnet Ñ 153.78.113.112 9100 <CR>

            Data typed in at this time will be sent to the printer’s CPU. If the printer happens to be ASCII
            (not Postscript), the data will print as soon as a Control – L (^ L) is typed. If you are not able to
            contact the printer, or if nothing happens when the telnet is tried, or if nothing prints, re-verify that
            the printer is properly configured, and that it is indeed unique on the network.

3        SETTING UP THE UNIX SYSTEM’S NETWORK DATA

            For the following sections, all work must be performed by the root-level (privileged) user. There are
            many changes to make, and the un-privileged user cannot modify the configuration files in the three
            critical UNIX Subsystems (LAN, UUCP, LP).

            One must verify that the UNIX system’s LAN subsystem knows about both the IP address and the
            network nodename for the printer. Two methods are available to verify this data; the name server
            lookup (nslookup) utility, as well as grep’ing the / etc / hosts file.

            A good first attempt is to run the Domain Name Server (DNS) " nslookup" utility with the printer’s
            nodename as the first argument. For this situation, you may assume a printer network nodename of
            "hplj4" has been assigned to network address 153.78.113.112; if the user types "# nslookup Ñ
             hplj4 <CR>
", the system should respond with something like;

                                        Server: server.ColumbiaSC.NCR.COM

                                        Address: 153.78.113.200

                                        Name: hplj4.ColumbiaSC.NCR.COM

                                        Address 153.78.113.112

            This output indicates that the LAN configuration already includes the printer’s IP address and
            network nodename. Any other resulting message means that the LAN administrator must verify the
            LAN configuration, or that the entry must be added to the /etc/hosts file (if not found there already).
            The printer’s IP address and network nodename must be in at least one of the DNS databases or the
             /etc/hosts file prior to further activity.

            As in the "Printer Configuration" section just above, you must be able to telnet (or at least to "ping) to
            the printer’s port from the UNIX system. If you cannot, the problem must be corrected prior to any
            further activity.

4      SETTING UP THE UNIX SYSTEM’S UUCP SUBSYSTEM

           Once the LAN is setup and functional, the UNIX system’s UUCP subsystem must be configured.
           This is necessary because the LP subsystem’s network-contact daemon "LpNet" is written to use the
            "dialling" techniques first coded in the UUCP subsystem. Thus, the UUCP configuration file "
             /etc/uucp/Systems" will be the file to contain the dialing information on the LAN to the networked
            printer Since dialing information is also influenced by the contents of the /etc/uucp/Devices and
             /etc/uucp/Dialers files, they will need to be modified, too. In all, these three files form the core for the
             UUCP subsytem’s hooks in "LpNet".

             An entry will be needed in the /etc/uucp/Dialers file:

prt Ñ " " Ñ " " (Note that this is doubled double quotes!)

             Likewise, an entry will be needed in the /etc/uucp/Devices file:

                                               PRT, eg Ñ tcp Ñ - Ñ - Ñ TLI Ñ \D Ñ prt

             These two entries must match each other: the "prt" in the Devices file entry is a label which must be
             found in the Dialers file. If you have questions about the meaning of these lines or a specific field in
             them, you can read the Devices (4) and Dialers (4) man pages.

             The /etc/uucp/Systems file will need to contain an entry which specifies the dialing information for
             the printer’s network nodename. Again, using the previous example of "hplj4", here’s the relevant line
             from the Systems file, plus and explanation of the major fields:

                                                hplj4 Ñ Any Ñ PRT Ñ - Ñ \x0002238c994e7170

            In this line, the "PRT" label exactly matches the one found in the Device file. The hexadecimal string
            "\x0002238c994e7170" may be initially confusing, but is much simpler than it looks; it is the output of
            the rfsaddr (1M) utility. This utility converts a port and IP address to a hex value. Refer to the
            rfsaddr(1M) man page for further information. For this example, the command used was:

                                                # / usr / bin / rfsaddr Ñ –h Ñ hplj4 Ñ –p Ñ 9100 <CR>

            Of course, if the printer listened on a different port number (for example, if it had been a Milan Printer
            Adapter rather than the HP Laserjet 4), the other port number would be specified in the command line
            as illustrated above.

            Once this information is safely written to these three files, you may move your concentration from the
            UUCP to the LP subsystem.

5      SETTING UP THE UNIX SYSTEM’S LP SUBSYSTEM

           Once you have reached this point, the hard part is perhaps over. The next step is to determine the
           name (or names…) with which the printer will be identified. This concept may be somewhat confusing,
           so an explanation follows.

            The simple fact is that the printer’s network nodename does not have to be the same name the printer
            is called by the LP subsystem. In other words, the LP printer name can be some useful and meaningful
            name, rather than just a plain network node name. For example, the network node name of "hplj4" is
            somewhat descriptive (Hewlett-Packard LaserJet 4), but names like "hp4post" and "hp4laser" might
            have more intuitive meaning: postscripts and plain text capabilities are implied. In other words, the LP
            subsystem allows the LP administrator to "substitute" the network node name with more meaningful
            names.

            Once the names have been decided, a check must be made to ensure that the intended LP printer
            names have not already been used:

                                                # lpstat Ñ –v Ñ 2>&1 Ñ | Ñ egrep Ñ "hp4post Ñ I Ñ hp4laser" <CR>

            If there are no matches, all is well. If there are some matches, you may remove the previous LP printers
            (lpadmin –x, not really recommended), or you may simply choose new names. (Make up some new
            names. It’s a lot easier than trying to reconstruct some lost printer characteristics! : - ) )

            A final note: names are most useful and intuitive when they reflect the usage of the printer: "hp4post"
            implies a Hewlett-Packard LaserJet 4 Postscipt printer, and "hp4laser" implies a Hewlett-Packard
            LaserJet 4 ASCII /plaintext printer
. Thus, the names reflect the type of jobs the printer will accept.

            Since the decisions regarding the printer names and the types of jobs the printer will accept have been
            made, the next step is to add the printers to the LP subsystem using the lpadmin (1M) utility. You may
            find it beneficial to print out a reference copy of the lpadmin(1M) man page, in order to more easily
            understand the following information.

            If you are adding plain ASCII printer, you will most likely use the command line:

            # lpadmin Ñ –p Ñ hp4text Ñ –U Ñ hplj4 Ñ –T Ñ dumb –I simple Ñ -D Ñ \
                                                                                            "ASC
II/plain Ñ text" <CR>

            If you are adding a postscript printer, you will most likely use:

            # lpadmin Ñ –p Ñ hp4post Ñ –U Ñ hplj4 Ñ –T Ñ PS ÑI Ñ simple Ñ –D Ñ \
                                                                                                                            "postscript"

            Since and ASCII-to-PostScript translator is included in the LP package, it would be useful to also setup
            and ASCII-capable printer definition:

            # lpadmin Ñ –p Ñ hp4laser Ñ –U Ñ hplj4 Ñ –T Ñ PS ÑI Ñ postscript Ñ \
                                                                                    – D Ñ "ASCII/plain Ñ text" <CR>

            Consideration must be made for saving trees. The banner page is an annoying default feature of the
            LP subsystem. You may wish to edit the interface files (/etc/lp/interfaces/hp4* for this example) to
            change the line:

                                                    nobanner = "no"

            Change this line to "yes", and the banner page will be history, i.e.

                                                    nobanner = "yes"

            Once the printers have been setup to this point, the LP subsystem administrator will have to perform the
             following two commands to complete each printer’s identification to the LP subsystem:

                                                    # accept Ñ hp4post <CR>

                                                    # accept Ñ hp4laser <CR>

            and

                                                    # enable Ñ hp4post<CR>

                                                    # enable Ñ hp4laser<CR>

            In other words, perform the accept (1M) and enable (1M) commands on each printer added to the
            LP subsystem.

            A final step will be to shutdown and restart the LP subsystem:

                                                    # lpshut <CR>

                                                    # / usr / lib / lpsched <CR>

6      TESTING

            Two simple tests are all that is needed to prove the printers are actually printing. First, perform an
            "lpstat –t" command to display that the printers are actually in the LP subsystem:

            # lpstat Ñ –t Ñ I Ñ egrep Ñ "hp4post Ñ I Ñ hp4laser"

            dial token for hp4post: hplj4

            dial token for hp4laser: hplj4

            hp4post accepting requests since Sat Feb 12 14:34:01 EST 1994

            hp4laser accepting requests since Sat Feb 12 14:34:01 EST 1994

            printer hp4post is idle. Enabled since Thu Jun 30 14:14:45 EDT 1994. available.

            Printer hp4laser is idle. Enabled since Thu Jun 30 14:14:45 EDT 1994. available.

            Secondly, print something! Since this example has two printer definitions "pointing" to the same
            physical printer, we’ll send both a postscript and an ASCII/plain text job to the printer. First, the ASCII
            /plain text:

            # lp Ñ –dhp4laser Ñ / etc / group <CR>

            request id is hp4laser-1 (1 file)

            For this example, a copy of the /etc/group file should be printing on the ASCII /plain text printer.
            We can verify:

            # lpstat Ñ –t Ñ I Ñ grep Ñ hp4laser

            dial token for hp4laser: hplj4

            hp4laser accepting requests since Sat Feb 12 14:34:01 EST 1994

            printer hp4laser is idle, enabled since Thu Jun 30 09:36:01 EDT 1994. available.

            Hp4laser-1 your name 789 Jun 30 22:24 on hp4laser

            Time to test printing postscript. Surprise! One also just tested the Postscript printing at the same time!
            The LP subsystem detected that the print device being used was an ASCII /plain text printer, and that
            the output device is a PostScript one. It automatically utilized the ASCII-to-Postscript translator
            (/usr/lib/lp/postscript/postprint) to convert one to the other.

7      TROUBLE SHOOTING

            You may experience the following problems:

7.1     Printer does not appear to be incorporating carriage returns. This may happen if your printer was
            configured as type hplaser. In order to correct the problem, the terminfo for hplaser will have to be
            modified as follows.

            # cd Ñ / usr / share / lib / terminfo / h

            #cp Ñ hplaser Ñ hplaser.old (make a copy of the original)

            # infocmp ÑI Ñ hplaser Ñ > Ñ hplaser.s (create source file)

            #I vi Ñ hplaser.s

            Make the following modifications

            1st line should read:

                            hplaser,             (i.e. remove other hp definitions)

            IS2 line should be changed as follows:

                            0G to 3G

            Save changes & exit vi

            # tic Ñ hplaser.s (compile source file)

            Confirm that type = hplaser in /etc/lp/printers/<printername>/configuration file.

7.2     Printer works in Unix but is not seen by UniVision.

            If the printer is working is Unix but UniVision is unable to add it in using the Maintain Printer Records
            option is UVsetup:-

            This takes into account the output produced by lpstat –p for network printers,

7.3   Printer has been added into Univision but remains DISABLED.

Return to Index