System Administration Guide: Advanced Administration

How to Troubleshoot Incorrect Output

  1. Log in as superuser or lp.

  2. Make sure that the printer type is correct.

    An incorrect printer type might cause incorrect output. For example, if you specify printer type PS and the pages print in reverse order, try printer type PSR. (These type names must be in uppercase.) Also, an incorrect printer type might cause missing text, illegible text, or text with the wrong font. To determine the printer type, examine the entries in the terminfo database. For information on the structure of the terminfo database, see Printer Type.

    1. On the print server, display the printer's characteristics.


      $ lpstat -p luna -l
      printer luna is idle. enabled since Thu Jul 12 15:02:32 ...
              Form mounted: 
              Content types: postscript
              Printer types: PS
              Description:
              Connection: direct
              Interface: /usr/lib/lp/model/standard
              After fault: continue
              Users allowed:
                      (all)
              Forms allowed:
                      (none)
              Banner not required
              Character sets:
      
              Default pitch:
              Default page size: 80 wide 66 long
              Default port settings:  
      $
    2. Consult the printer manufacturer's documentation to determine the printer model.

    3. If the printer type is not correct, change it with Solaris Print Manager's Modify Printer Properties window, or use the following lpadmin command.


      # lpstat -p printer-name -T printer-type
      

      On the print client, the printer type should be unknown. On the print server, the printer type must match a terminfo entry that is defined to support the model of printer you have. If there is no terminfo entry for the type of printer you have, see How to Add a terminfo Entry for an Unsupported Printer.

  3. If the banner page prints, but there is no output for the body of the document, check the file content types.

    File content types specified for a printer indicate the types of files the printer can print directly without filtering. An incorrect file content type causes filtering to be bypassed when it might be needed.

    1. Note the information on file content type that was supplied in the previous step by the lpstat command.

      On the print client, the file content type should be any, unless you have good reason to specify one or more explicit content types. If a content is specified on the client, filtering is done on the print client, rather than the print server. In addition, content types on the client must match the content types specified on the print server, which in turn must reflect the capabilities of the printer.

    2. Consult your printer manufacturer's documentation to determine which types of files the printer can print directly.

      The names you use to refer to these types of files do not have to match the names used by the manufacturer. However, the names you use must agree with the names used by the filters known to the LP print service.

    3. If the file content type is not correct, change it with Solaris Print Manager's Modify Printer Properties window, or the following lpadmin command.


      # lpadmin -p printer-name -I file-content-type(s)
      

      Run this command on either the print client, or print server, or both, as needed. Try -I any on the print client, and -I "" on the print server. The latter specifies a null file content type list, which means an attempt should be made to filter all files, because the printer can directly print only files that exactly match its printer type.

      This combination is a good first choice when files are not printing. If it works, you might want to try specifying explicit content types on the print server to reduce unnecessary filtering. For a local PostScript printer, you should use postscript, or postscript,simple, if the printer supports these types. Be aware that PS and PSR are not file content types; they are printer types.

      If you omit -I, the file content list defaults to simple. If you use the -I option and want to specify file content types in addition to simple, simple must be included in the list.

      When specifying multiple file content types, separate the names with commas. Or you can separate names with spaces and enclose the list in quotation marks. If you specify any as the file content type, no filtering will be done and only file types that can be printed directly by the printer should be sent to it.

  4. Check that the print request does not bypass filtering needed to download fonts.

    If a user submits a print request to a PostScript printer with the lp -T PS command, no filtering is done. Try submitting the request with the lp -T postscript command to force filtering, which might result in the downloading of non-resident fonts needed by the document.

  5. Make sure that the stty settings for the printer port are correct.

    1. Read the printer documentation to determine the correct stty settings for the printer port.


      Note –

      If a printer is connected to a parallel or USB port, the baud setting is irrelevant.


    2. Examine the current settings by using the stty command.


      # stty -a < /dev/term/a
      speed 9600 baud;
      rows = 0; columns = 0; ypixels = 0; xpixels = 0;
      eucw 1:0:0:0, scrw 1:0:0:0
      intr = ^c; quit = ^|; erase = ^?; kill = ^u;
      eof = ^d; eol = <undef>; eol2 = <undef>; swtch = <undef>;
      start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
      rprnt = ^r; flush = ^o; werase = ^w; lnext = ^v;
      parenb -parodd cs7 -cstopb -hupcl cread -clocal -loblk -parext
      -ignbrk brkint -ignpar -parmrk -inpck istrip -inlcr -igncr icrnl -iuclc
      ixon -ixany -ixoff imaxbel
      isig icanon -xcase echo echoe echok -echonl -noflsh
      -tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
      opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel tab3
      #

      This command shows the current stty settings for the printer port.

      The following table shows the default stty options used by the LP print service's standard printer interface program.

      Table 31–2 Default stty Settings Used by the Standard Interface Program

      Option 

      Meaning 

      -9600

      Set baud rate to 9600 

      -cs8

      Set 8-bit bytes 

      -cstopb

      Send one stop bit per byte 

      -parity

      Do not generate parity 

      -ixon

      Enable XON/XOFF (also known as START/STOP or DC1/DC3) 

      -opost

      Do “output post-processing” using all the settings that follow in this table 

      -olcuc

      Do not map lowercase to uppercase 

      -onlcr

      Change line feed to carriage return/line feed 

      -ocrnl

      Do not change carriage returns into line feeds 

      -onocr

      Output carriage returns even at column 0 

      -n10

      No delay after line feeds 

      -cr0

      No delay after carriage returns 

      -tab0

      No delay after tabs 

      -bs0

      No delay after backspaces 

      -vt0

      No delay after vertical tabs 

      -ff0

      No delay after form feeds 

    3. Change the stty settings.


      # lpadmin -p printer-name -o "stty= options" 
      

      Use the following table to choose stty options to correct various problems affecting print output.

      Table 31–3 stty Options to Correct Print Output Problems

      stty Values

      Result 

      Possible Problem From Incorrect Setting 

      110, 300, 600, 1200, 1800, 2400, 4800, 9600, 19200, 38400

      Sets baud rate to the specified value (enter only one baud rate) 

      Random characters and special characters might be printed and spacing might be inconsistent 

      oddp

      evenp

      -parity

      Sets odd parity 

      Sets even parity 

      Sets no parity 

      Missing or incorrect characters appear randomly 

      -tabs

      Sets no tabs 

      Text is jammed against right margin 

      tabs

      Sets tabs every eight spaces 

      Text has no left margin, is run together, or is jammed together 

      -onlcr

      Sets no carriage return at the beginning of line(s) 

      Incorrect double spacing 

      onlcr

      Sets carriage return at beginning of line(s) 

      The print zigzags down the page 

      You can change more than one option setting by enclosing the list of options in single quotation marks and separating each option with spaces. For example, suppose the printer requires you to enable odd parity and set a 7-bit character size. You would type a command similar to that shown in the following example:


      # lpadmin -p neptune -o "stty='parenb parodd cs7'"
      

      The stty option parenb enables parity checking/generation, parodd sets odd parity generation, and cs7 sets the character size to 7 bits.

  6. Verify that the document prints correctly.


    # lp -d printer-name filename