subscribe iconSubscribe to this information
POWER7 information

lsmap command

Purpose

Displays the mapping between physical, logical, and virtual devices.

Syntax

lsmap {-vadapter ServerVirtualAdapter | -plc PhysicalLocationCode | -all } [ -type BackingDeviceType | -net | -npiv] [-field FieldName ... ] [-fmt Delimiter ]

lsmap -ams { -vtd PagingDevice | -all } [ -type BackingDeviceType ] [ -field FieldName ... ] [ -fmt Delimiter ]

lsmap -clustername ClusterName {-all | -hostname HostName} [-field FieldName... ] [ -fmt Delimiter ]

lsmap -suspend {-vadapter ServerVirtualAdapter | -all } [ -type BackingDeviceType ] [-field FieldName ... ] [-fmt Delimiter ]

lsmap -clustername ClusterName {-all | -hostname HostName}

Description

The lsmap command displays the mapping between the virtual host adapters and the physical devices they are backed to. Given an adapter name (ServerVirtualAdapter) or physical location code (PhysicalLocationCode) of a server virtual adapter, the device name of each connected virtual target device (child devices), its logical unit number, backing device(s), and the backing devices physical location code is displayed. If the -net flag is specified the supplied device must be a virtual server Ethernet adapter.

The -fmt flag separates the output by a user-specified delimiter/character (delimiter). The delimiter can be any non-white space character. This format is provided to facilitate scripting. When a field has no value, it is reported as a "space/blank". For example, if vhost0 has a vtopt0 entry, with no backing device, and you type the command lsmap -vadapter vhost0 -fmt : -field VTD backing status, the system displays the following output vtopt0: :Available.

The -type flag limits the types of backing devices displayed to the user-specified list, BackingDeviceType. With the exception of the net type, any combination of device types may be specified. The net type cannot be combined with any other type.

The -npiv flag displays the server binding information between the virtual fibre channel and the physical fibre channel adapter. It is also used to display client adapter attributes that are sent to the server adapter.

The -suspend flag displays the storage that is used by a suspended client. The rmdev command can be used to remove suspended adapters. For more information, see the Examples section of the rmdev command topic.

Flags

Flag name Description
-all Specifies that the mapping information must be displayed for all the virtual SCSI devices. If the -all flag is used with the -net flag, virtual Ethernet adapters are displayed. If the flag is used with the -npiv flag, virtual fibre channel adapters are displayed. If the flag is used with the -suspend flag, suspended virtual small computer system interface (VSCSI) adapters are displayed.
-ams Displays paging space device information used in active memory sharing.
-clustername Specifies the cluster name.
-field FieldName Specifies the list of fields to display.
Note: The order that you specify the attributes is not guaranteed to be the same order as they are returned. The attributes of the virtual host adapter (vhostX) are always listed before the attributes of the virtual target device (VTD). You can specify the order of the attributes within the virtual host adapter and the order of the attributes within the virtual target device. But, you cannot intermix the attributes of the virtual host adapter and the attributes of the virtual target device.
For virtual SCSI (default), the following fields are supported:
svsa
Server virtual adapter name.
physloc
The physical location code of the server's virtual adapter.
mirrored
The backing device is part of a Peer-to-Peer Remote Copy (PPRC) pair.
clientid
Client partition ID.
vtd
Virtual target device.
lun
Logical unit number.
backing
Backing device.
bdphysloc
The physical location code of the backing device.
status
Virtual target device status.
For shared Ethernet adapter (-net flag), the following fields are supported:
svea
Virtual Ethernet adapter name.
physloc
The physical location code of the server virtual adapter.
sea
Shared Ethernet adapter.
backing
Backing device.
bdphysloc
The physical location code of the backing device.
status
Shared Ethernet adapter status.
 

For NPIV (-npiv flag), the following fields are supported:

name
Virtual fibre channel adapter name.
physloc
The physical location code of the server virtual fibre channel adapter.
clntid
Client logical partition ID.
clntname
Client logical partition name.
clntos
The operating system on the client logical partition.
status
Virtual fibre channel adapter status.
fc
Physical fibre channel adapter name.
fcphysloc
The physical location of the fibre channel adapter.
ports
Physical fibre channel port number.
flags
Virtual fibre channel adapter flags.
vfcclient
Client virtual fibre channel adapter name.
vfcclientdrc
Client virtual fibre channel adapter used for Dynamic Reconfiguration Connection (DRC).
  
For active memory sharing (-ams flag), the following fields are supported:
paging
Paging virtual target device.
streamid
Stream ID.
clientid
Client logical partition ID.
status
Paging virtual target device status.
redundancy
Redundancy usage for the paging VIOS logical partitions.
backing
Backing device.
poolid
Memory pool ID.
vasi
Virtual Asynchronous Services Interface (VASI) device name.
pager
Pager device name.
vbsd
Virtual Block Storage Device (VBSD) name.
For suspended adapter (-suspend flag), the following fields are supported:
svsa
Suspended virtual adapter.
state
Suspended virtual adapter state.
clientname
Client name.
streamid
Stream ID.
clientid
Client partition ID.
vtd
Virtual target device.
status
Virtual target device status.
lun
Logical unit number.
backing
Backing device.
bdphysloc
The physical location code of the backing device.
mirrored
The backing device is part of a peer-to-peer remote copy (PPRC) pair.
For cluster (-clustername flag), the following fields are supported:
Physloc
The physical location code of the server virtual adapter.
ClientID
Client partition ID.
VTD
Client partition ID.
LUN
Logical unit number.
Backing
Backing device.
-fmt delimiter Specifies a delimiter character to separate output fields.
-hostname Specifies the host name or IP address of the VIOS partition.
-net Specifies the supplied device is a server virtual Ethernet adapter or if used with the -all flag all virtual Ethernet adapters and backing devices are displayed.
-npiv Displays NPIV binding information.
-plc PhysicalLocatoinCode Specifies the device physical location code of a server virtual adapter. This flag cannot be used with the -vadapter flag.
-suspend Displays suspended virtual adapters.
-type Specifies the type of devices to display. The following fields are supported:
disk
List physical backing devices.
lv
List logical volume backing devices.
optical
List optical backing devices.
tape
List tape backed devices.
file
List file backed devices.
file_disk
List file backed disk devices.
file_opt
List file backed optical devices.
cl_disk
List clustered backing devices.
net
List network devices. (This option cannot be used in combination with disk, lv, or optical)
usb_disk
Lists USB disks

-vadapter VirtualServerAdapter

Specifies the device name of a server virtual adapter. This flag cannot be used with the -plc flag.

-vtd PagingDevice

Specifies the active memory sharing (AMS) paging device to be displayed.

Output Field Definitions

Field Description
SVSA Server Virtual SCSI Adaper
Physloc Physical Location Code
VTD Virtual Target Device
LUN Logical Unit Number
SVEA Server Virtual Ethernet Adapter
SEA Shared Ethernet Adapter

Exit Status

Return code Description
12 No SEAs associated with device
15 Specified device is not a server virtual SCSI adapter
16 Specified device is not a server virtual Ethernet adapter
17 Specified device in not in the AVAILABLE state
63 Specified device is not a virtual fibre channel adapter on a server logical partition.

Examples

  1. To list all virtual target devices and backing devices mapped to the server virtual SCSI adapter vhost2, type the following command:
    lsmap -vadapter vhost2 

    The system displays the following message:

     SVSA                 Physloc				Client Partition ID
    -------------        --------------------------------- -----------------------------
    vhost2       	      U9111.520.10004BA-V1-C2           0x00000004
    
    VTD                   vtscsi0
    Status                Available
    LUN                   0x8100000000000000
    Backing device        vtd0-1
    Physloc
    
    VTD                   vtscsi1
    LUN                   0x8200000000000000
    Backing device        vtd0-2
    Physloc
    
    VTD                   vtscsi2
    Status                Available
    LUN                   0x8300000000000000
    Backing device        hdisk2
    Physloc               U787A.001.0397658-P1-T16-L5-L0
    Mirrored              false
  2. To list the shared Ethernet adapter and backing device mapped to the virtual server Ethernet adapter ent4, type the following command:
    lsmap -vadapter ent4 -net

    The system displays the following message:

    SVEA   		           Physloc
    ------		           ---------------------
    ent4   		           P2-I1/E1
    
    SEA                  ent5
    Backing device       ent1
    Status               Available
    Physloc              P2-I4/E1
  3. To list the shared Ethernet adapter and backing device mapped to the virtual server Ethernet adapter ent3 in script format separated by a : (colon), type the following command:
    lsmap -vadapter ent3 -net -fmt ":"

    The system displays the following message:

    ent3:U8204.E8A.06A85B2-V13-C11-T1:ent10:ent1:Available:U7311.D20.06168AC-P1-C06-T1
  4. To list all virtual target devices and backing devices, where the backing devices are of type disk or lv, type the following command:
    lsmap -all -type disk lv

    The system displays the following message:

     SVSA                Physloc                           Client Partition ID
    -------------        --------------------------------- -----------------------------
    vhost0               U9117.570.10D1B0E-V4-C3           0x00000000
    
    VTD                   vtscsi0
    Status                Available
    LUN                   0x8100000000000000
    Backing device        hdisk0
    Physloc               U7879.001.DQD0KN7-P1-T12-L3-L0
    
    VTD                   vtscsi2
    Status                Available
    LUN                   0x8200000000000000
    Backing device        lv04
    Physloc                
    
     SVSA                Physloc                           Client Partition ID
    -------------        --------------------------------- -----------------------------
    vhost1               U9117.570.10D1B0E-V4-C4           0x00000000
    
    VTD                   vtscsi1
    Status                Available
    LUN                   0x8100000000000000
    Backing device        lv03
    Physloc 
  5. To list NPIV mapping information, type the following command:
    lsmap -all -npiv

    The system displays the following message:

    Name           Physloc                   ClntID ClntName  ClntOS
    ======       ======================      ===== ========== =====
    vfchost0       U8203.E4A.HV40026-V1-C12    1    HV-40026    AIX
    
    Status:NOT_LOGGED_IN
    FC name:fcs0                             FC loc code:U789C.001.0607088-P1-C5-T1
    Ports logged in:3
    Flags:1 <not_mapped, not_connected>
    VFC client name:                VFC client DRC:
  6. To list shared storage pool mappings along with other storage mappings for a particular virtual SCSI adapter, type the following command:
    lsmap -vadapter vhost0
    The system displays the following output:
     SVSA                 Physloc                          Client Partition ID
    -------------        --------------------------------- -----------------------------
    vhost0       	      U8233.E8B.HV32001-V2-C2            0x00000000
    VTD                   vtscsi0	 
    Status                Available	 
    LUN                   0x8100000000000000	 
    Backing device        testLU1.b1277fffdd5f38acb365413b55e51638	 
    Physloc	 	 
    Mirrored              N/A	 
    
    VTD                   vtscsi1	 
    Status                Available	 
    LUN                   0x8200000000000000	 
    Backing device        testLU2.8f5a2c27dce01bf443383a01c7f723d0	 
    Physloc	 	 
    Mirrored              N/A	 
    
    VTD                   vtscsi2	 
    Status                Available	 
    LUN                   0x8300000000000000	 
    Backing device        testLU3.2cc8eadef6df0db3da76e21c79c7377f	 
    Physloc	 	 
    Mirrored              N/A	
    
    VTD                   vtscsi3
    Status                Available
    LUN                   0x8400000000000000
    Backing device        hdisk3
    Physloc               U787A.001.0397658-P1-T16-L5-L0
    Mirrored              false
    
    VTD                   vtscsi4
    Status                Available
    LUN                   0x8500000000000000
    Backing device        data_lv
    Physloc               
    Mirrored              N/A
  7. To list all shared storage pool mappings, type the following command.
    lsmap -all -clustername newcluster
    The system displays the following output:
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U8233.E8B.HV32001-V2-C2                                             0x00000000
    VTD                  vtscsi0
    LUN                  0x8100000000000000
    Backing device       testLU1.b1277fffdd5f38acb365413b55e51638
    
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U8233.E8B.HV32001-V2-C2                                             0x00000000
    VTD                  vtscsi1
    LUN                  0x8200000000000000
    Backing device       testLU2.8f5a2c27dce01bf443383a01c7f723d0
    
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U8233.E8B.HV32001-V2-C2                                             0x00000000
    VTD                  vtscsi2
    LUN                  0x8300000000000000
    Backing device       testLU3.2cc8eadef6df0db3da76e21c79c7377f
    
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U9179.MHB.10A9DAP-V4-C111                                           0x00000000
    VTD                  vtscsi0
    LUN                  0x8100000000000000
    Backing device       testLU4.ad089db46c2dc3769e71bf7875607c6f
    
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U9179.MHB.10A9DAP-V1-C31                                            0x00000015
    VTD                  vtscsi0
    LUN                  0x8200000000000000
    Backing device       testLU5.34cd008de649b8fde83bb16d395d48c9
    
    Physloc                                                       Client Partition ID
    -----------------------------------------------------------------   -------------------------
    U9179.MHB.10A9DAP-V3-C111                                           0x00000065
    VTD                  vtscsi0
    LUN                  0x8200000000000000
    Backing device       testLU6.ad089db46c2dc3769e71bf7875607c6f
  8. To list all suspended adapters, type the following command:
    lsmap -all -suspend 
    The system displays the following output:
    SVSA       State       Client Name             Stream ID              Client Partition ID
    -------------------------------------------------------------------------------------------
    susadpt0      suspended	   17*9117-MMB*10002EP     0xf70e4facfc46e9a0     0x00000017  
    
    VTD                  vtscsi0
    Status               Defined
    LUN                  0xx8100000000000000
    Backing device       hdisk5
    Physloc              U789D.001.DQDWAXR-P1-C4-T1-W205600A0B86E4A5A-L5000000000000
    Mirrored             false
    
    VTD                  vtscsi1
    Status               Defined
    LUN                  0x8200000000000000
    Backing device       hdisk6
    Physloc              U789D.001.DQDWAXR-P1-C4-T1-W205600A0B86E4A5A-L6000000000000
    Mirrored             false                                                                  


Send feedback Rate this page

Last updated: Wed, June 03, 2015