System Administration Guide: Advanced Administration

How to Set Up an Alias for a Selectable Character Set

You do not need to perform this procedure if the terminfo names for the selectable character sets are adequate. For more information on using the terminfo database, see Adding a terminfo Entry for an Unsupported Printer.

  1. Log in as superuser, lp, or assume an equivalent role on the print server.

  2. Display the names of the selectable character sets for the specified printer type.


    # tput -T printer-type csn
    

    -T printer-type

    Printer type found in the terminfo database. For information on entries in the terminfo database, see Printer Type.

    n

    Number (0, 1, 2, 3, 4, 5, and so on) that represents a selectable character set for the specified printer type. The system displays the selectable character set name followed by the prompt symbol. For example, cs1 could cause the system to display english#.

    For more information, see tput(1).

  3. Set up an alias for a selectable character set.


    # lpadmin -p printer-name -S select-charset1=alias1[,select-charset2=alias2...]
    

    -p printer-name

    Printer on which you are setting up aliases for selectable character sets. 

    -S select-charset

    Selectable character set name for which to set an alias. The name can be found in Step 2.

    alias

    Alias for the specified selectable character set. This alias can be used in addition to the selectable character set name. 

    You can set up more than one alias with this command. Use commas or spaces to separate the aliases. If you use spaces, enclose the list of aliases in quotes. 

    The alias is added in the print server's /etc/lp/printers/printer-name/configuration file.

  4. Log in as superuser, lp, or assume an equivalent role on a system that is a print client of the print server.

  5. Set up an alias for the selectable character set.


    # lpadmin -p printer-name -S select-charset1=alias1[,select-charset2=alias2...]
    

    In this command, the variables are the same as those in Step 3.

    The alias is added in the print client's /etc/lp/printers/printer-name/configuration file.

  6. Repeat Step 4 and Step 5 for each print client that might need to use the alias.

  7. Verify that the selectable character set alias is listed in the output of the following command on the print server and print clients.


    $ lpstat -p printer-name -l
    

    Otherwise, submit a print request that uses the alias for the selectable character set and check for output.

Example—Setting Up an Alias for a Selectable Character Set

The following example shows how to display the names of selectable character sets and specify text as an alias for the usascii selectable character set on the printer luna, which is an ln03 printer type.


# tput -T ln03 cs0
usascii# tput -T ln03 cs1
english# tput -T ln03 csn2
finnish# tput -T ln03 csn3
japanese# tput -T ln03 cs4
norwegian#
# lpadmin -p luna -S usascii=text