IVM lsrefcode command

Purpose

Lists reference codes for partitions or the managed system. This command is operable only in an Integrated Virtualization Manager environment.

Syntax

To list reference codes for the managed system:

lsrefcode -r sys [ -n Number ] [ --filter "FilterData" ] [ -F "AttributeNames" ] [ --header ] [ -m ManagedSystem ]

To list reference codes for partitions:

lsrefcode -r lpar [ -n Number ] [ --filter "FilterData" ] [ -F "AttributeNames" ] [ --header ] [ -m ManagedSystem ]

Description

The lsrefcode command lists reference codes for partitions or the managed system.

Flags

Flag name Description
-r ResourceType The type of resources to list:
  • -r sys: List reference codes for the managed system.
    • Attributes: refcode_num, time_stamp, refcode, word2, word3, word4, word5, word6, word7, word8, word9, fru_call_out_loc_codes
    • Filters: None
  • -r lpar: List reference codes for partitions.
    • Attributes: lpar_name, lpar_id, time_stamp, refcode, word2, word3, word4, word5, word6, word7, word8, word9, fru_call_out_loc_codes
    • Filters: { lpar_ids | lpar_names}
-n Number The number of reference codes to list. The default is to list one. Reference codes are listed in order, with the most recent reference code first.
-m ManagedSystem The name of the managed system. This attribute is optional because there is only one system to manage. The name might either be the user-defined name for the managed system, or be in the form tttt-mmm*ssssssss, where tttt is the machine type, mmm is the model, and ssssssss is the serial number of the managed system.
--filter FilterData The filters to apply to the resources to be listed. Filters are used to select which resources of the specified resource type are to be listed. If no filters are used, then all of the resources of the specified resource type will be listed. For example, specific partitions can be listed by using a filter to specify the names or IDs of the partitions to list. Otherwise, if no filter is used, then all the partitions in the managed system will be listed.

The filter data consists of filter name/value pairs, which are in comma separated value (CSV) format. The filter data must be enclosed in double quotation marks.

The format of the filter data is as follows:
"filter-name=value,filter-name=value,..."
Certain filters accept a comma separated list of values, as follows:
""filter-name=value,value,...",..."

When a list of values is specified, the filter name/value pair must be enclosed in double quotation marks. Depending on the shell being used, nested double quotation marks might need to be preceded by an escape character, which is usually a '\' character.

Unless otherwise indicated, multiple values can be specified for each filter.

Valid filter names for -r lpar:

lpar_ids
ID of the partition to view
lpar_names
Name of the partitions to view
-F AttributeNames A delimiter separated list of attribute names for the desired attribute values to be displayed for each resource. If no attribute names are specified, then values for all of the attributes for the resource will be displayed.

When this option is specified, only attribute values will be displayed. No attribute names will be displayed. The attribute values displayed will be separated by the delimiter which was specified with this option.

This option is useful when only attribute values are desired to be displayed, or when the values of only selected attributes are desired to be displayed.

Attribute Names:
fru_call_out_loc_codes
Location codes of the field replaceable unit related to the reference code
lpar_id
Unique integer identifier for the partition
lpar_name
Name of the partition
refcode
The ASCII reference code string
refcode_num
The sequence number of the reference code.
time_stamp
The time that the reference code was created in the format: MM/DD/YYYY HH:MM:SS where MM is the two digit month, DD is the two digit day, YYYY is the four digit year, HH is the two digit hour, MM is the two digit minute, and SS is the two digit second.
fru_call_out_loc_codes
The Field Replaceable Unit (FRU) numbers for the FRUs whose absence or failure caused this reference code to be received. This field might be used for other values.
--header Display a header record, which is a delimiter separated list of attribute names for the attribute values that will be displayed. This header record will be the first record displayed. This option is only valid when used with the -F option.

Exit Status

This command has a return code of 0 on success.

Security

This command is accessible by all users.

Examples

  1. To list the current reference code for the managed system, type:
    lsrefcode -r sys
  2. To list the current reference code for all partitions, type:
    lsrefcode -r lpar
  3. To list the last 25 reference codes for partitions p1 and p2, only viewing the lpar_id and refcode attributes, type:
    lsrefcode -r lpar -n 25 --filter \"lpar_names=p1,p2\" -F lpar_id,refcode



Last updated: Wed, November 18, 2020