[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]

Commands Reference, Volume 3


lsvirprt Command

Purpose

Displays the attribute values of a virtual printer.

Syntax

lsvirprt [ -q QueueName -d DeviceName { [ -f Format ] [ -n ] [ -a AttributeName | -s SectionName ] ... | -i | -D } ]

Description

The lsvirprt command displays the attribute values for the virtual printer assigned to the PrintQueueName and QueueDeviceName variables.

The lsvirprt command becomes interactive if no flags are specified with the command. A list of print queue names is displayed, and a prompt appears requesting that the desired print queue name be selected. After a valid print queue name is selected, a prompt appears requesting that attribute names be entered. If an attribute name of * (asterisk) is entered, a list of all attributes is displayed.

Note: Attribute names for default values of the qprt command line flags can be specified by entering the flag letters. For example, to view the default value for the -w flag (page width), enter the w attribute name. All other attribute names must be 2 characters long.

You can use the Printer Queues application in Web-based System Manager (wsm) to change printer characteristics. You could also use the System Management Interface Tool (SMIT) smit lsvirprt fast path to run this command.

Flags


-a AttributeName Specifies the name of an attribute for which information is to be displayed. The flag cannot be used with the -s flag. The -a flag can be specified many times to list multiple attributes. The AttributeName value can be a single-character name (for example, j), a simple two-character name (for example, ci), or a regular expression that specifies multiple attributes (for example, ^i.*.)
-d QueueDeviceName Specifies the name of the queue device to which the virtual printer is assigned. This flag is optional, but can be specified only if the -q flag is specified.
-D Displays data streams supported by a given queue and queue device name variable values. The -D flag displays the default data stream first and all other supported data streams in alphabetical order.
-f Format Specifies the display format for attribute information. Attribute information includes the attribute value, limits field, and attribute description. The Format value is specified in printf format. The -f Format option also supports the following predefined set of position arguments:

%1$[*.*]s
Message catalog name

%2$[*.*]d
Message number

%3$[*.*]s
Attribute name

%4$[*.*]s
Limits field

%5$[*.*]s
Attribute value

%6$[*.*]s
Attribute description

%7$c
Second character of attribute name.
-i Sets the command to interactive mode. The -q and -d flags must be specified with the -i flag. If values have been assigned to the QueueName and DeviceName variables, the command does not prompt for the queue and device names and accepts attribute names interactively.
-n Displays only the specified attributes that have nonnull values.
-s SectionName Specifies a section name in the virtual printer attribute database of the specified queue and queue device. The SectionName values begin with two underscores and contain three characters that identify a section. For example, the name of a section that contains all the flag attributes is __FLG. The -s flag can not be used with the -a flag. This option can be repeated to list multiple attributes. The SectionName variable value can be a regular expression.
-q PrintQueueName Specifies the name of the print queue to which the virtual printer is assigned. This flag is optional, but can be specified only if the -d flag is specified.

Examples

  1. To show the attribute values for the w (default page width) and si (user to receive the "Intervention Required" messages) attributes for the virtual printer assigned to the mypro queue device on the proq print queue, enter:

    lsvirprt -dmypro -qproq -a w -a si
    

    The output from this command is:

    Name            Description                      Value
    _w              COLUMNS per page                 136
    si              USERS to get intervention messages
    
  2. To show the same attributes in Example 1, but the be prompted for the flag values, enter:

    lsvirpt
    

    The output from this command is:

    1       e4039c          @piobe            ibm4039 (PCL Emulation)
    2       e4039s          @piobe            ibm4039 (PostScript)
    3       fjzhp4s         jzfile            hplj-4 (PostScript)
    4       hpc14           hp@pc15           hplj-4 (PCL)
    ...
    
  3. To list attributes in a section for header and trailer pipelines for the que queue and the dev device, enter:

    lsvirpt -qque -ddev -s__HTP
    

    The output from this command is:

    Name    Description                      Value
    sh      Pipeline for Header Page         %Ide/pioburst %F[H]
                                             %Idb/H.ascii | 
                                             %Ide/pioformat  
                                             -@%Idd/%Imm 
                                             -!%Idf/piof5202 -L! -J! 
                                             %IsH
    st      Pipeline for Trailer Page        %Ide/pioburst %F[H]
                                             %Idb/T.ascii | 
                                             %Ide/pioformat 
                                             -@%Idd/%Imm 
                                             -!%Idf/piof5202-L!
                                             -t%o%G_1%r%{14}%-%d 
                                             %IsT
    
  4. To list all the data streams supported for the que queue and the dev device, enter:

    lsvirpt -qque -ddev -D
    

    The output from this command is:

    a ASCII
    p pass-through
    s PostScript
    
  5. To list names and descriptions of all attributes in a printer attribute database for the que queue and the dev device in a specific format, enter:

    lsvirpt -qque -ddev -a'.*' -f' %3$5.5s: %6$s\\n'
    

    The output from this command is:

    __FLG:  Values That May Be Overridden With Flags
    _A:     stderr returned?
    _E:     Double spacing flag
    _F:     (not used) Font file name
    _H:     Name to Replace Host Name of Burst Page
    ...
    
  6. To list all the sections in a printer attribute data base for the que queue and the dev device in a specific format, enter:

    lsvirpt -qque -ddev -a'__.*' -f'%3$s: %6$s\\n'
    

    The output from this command is:

    __FLG:  Values That May Be Overridden With Flags On the Command
            Line
    __SYS:  Other Values Of Interest To the Streams Administrator
    __IDS:  Pipelines For Input Data Streams (2 char,1st="i",2nd=data
            stream name)
    __PFL:  Flags Prohibited For Input Data Streams (2 char,1st="I", 
            2nd=data stream name)
    __FIL:  Command Strings For Filter Flags (2 char, 1st="f",
            2nd=flag)
    __DIR:  Directories
    ...
    

Files


/etc/qconfig Contains the configuration file.
/usr/sbin/lsvirprt Contains the lsvirprt command.
/var/spool/lpd/pio/@local/custom/* Contains virtual printer attribute files.
/var/spool/lpd/pio/@local/ddi/* Contains the digested virtual printer attribute files.

Related Information

The chvirprt command, mkvirprt command, rmvirprt command.

The qconfig file.

For information on installing the Web-based System Manager, see Chapter 2: Installation and System Requirements in AIX 5L Version 5.1 Web-based System Manager Administration Guide.

Configuring a Printer without Adding a Queue in AIX 5L Version 5.1 Guide to Printers and Printing.

Printer Overview for System Management in AIX 5L Version 5.1 Guide to Printers and Printing.

Queuing System Overview for System Management in AIX 5L Version 5.1 Guide to Printers and Printing.

Virtual Printer Definitions and Attribute Values in AIX 5L Version 5.1 Guide to Printers and Printing.

Adding a Printer Using the Printer Colon File in AIX 5L Version 5.1 Guide to Printers and Printing.


[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]