lsmpio Command

Purpose

Displays information about the MultiPath I/O (MPIO) storage devices.

Syntax

lsmpio [ -l device_name ] [ -o ]

lsmpio -S [ -l device_name ] [ -d ]

lsmpio -z [ -l device_name ]

lsmpio -q [ -l device_name ]

lsmpio -a [ -r ] [ -e ] [ -z ]

lsmpio -h

Description

The lsmpio command displays information about AIX® MPIO storage devices. This command can be used only for AIX MPIO storage devices that are controlled by path-control modules (PCMs) that are enabled for the lsmpio command support. Some AIX® MPIO storage devices do not support the lsmpio command queries. However, all AIX MPIO storage devices support Path operational status queries.

Path operational status

You can run the lsmpio command without any flags or with the -l flag to display the path operational status.
# lsmpio
name   path_id status  path_status     parent connection
===============================================================================
hdisk1234  0   Enabled Opt,Sel,Deg,Rsv fscsi0 500a098186a7d4ca,0008000000000000
hdisk1234  1   Enabled Non             fscsi0 500a098196a7d4ca,0008000000000000
hdisk1234  2   Enabled Opt,Sel         fscsi1 500a098186a7d4ca,0008000000000000
hdisk1234  3   Enabled Non             fscsi1 500a098196a7d4ca,0008000000000000
The output is similar to the output that is displayed by running the lspath command as shown in the following command:
lspath -F "path_id status parent connection"
The valid values of the status column are Enabled, Disabled, Failed, or Missing. The extended path_status field might contain one or more three-letter status abbreviations to provide more detailed path status.
Note: Not all extended path_status fields are applicable to all MPIO storage devices. Some path_status values appear only if the storage area network (SAN) fabric supports notification about SAN congestion.
The possible values for the path_status field follow:
Opt
Indicates that the MPIO disk path is an optimized path. This value indicates an MPIO disk path that attaches to a preferred controller in a device that has multiple controllers. The PCM selects one of the preferred MPIO disk paths for I/O operations, whenever possible.
Non
Indicates that the MPIO disk path is a non-optimized path. On a device with preferred MPIO disk paths, this path is not considered as preferred path. The PCM avoids the selection of this path for I/O operations, unless all preferred paths fail.
start of changeChgend of change
start of changeIndicates that the access characteristics of the MPIO disk are changing on the storage target. This state is temporary until the path transitions to a new state.end of change
start of changeLosend of change
start of changeIndicates that the MPIO disk path has lost access to data permanently and is no longer usable in the host. The storage target should be evaluated or diagnosed for possible problems.end of change
Act
Indicates that the MPIO disk path is an active path on a device that has active and passive controllers. The PCM selects active MPIO disk paths for I/O operations on such a device.
Pas
Indicates that the MPIO disk path is a passive path on a device that has active and passive controllers. The PCM avoids the selection of passive paths.
Sel
Indicates that the MPIO disk path is being selected for I/O operations, for the time when the lsmpio command is to be run.
Rsv
Indicates that the MPIO disk path has experienced an unexpected reservation conflict. This value might indicate a usage or configuration error, with multiple hosts accessing the same disk.
Fai
Indicates that the MPIO disk path experienced a failure. It is possible for a path to have a path status value of Enabled and still have an extended path status value of Fai. This scenario indicates that operations that are sent on this MPIO disk path are failing, but AIX MPIO has not marked the path as Failed. In some cases, AIX MPIO leaves one path to the device in Enabled state, even when all MPIO disk paths are experiencing errors.
Deg
Indicates that the MPIO disk path is in a degraded state. This scenario indicates that the MPIO disk path was being used for I/O operations. Those operations experienced errors, thus causing the PCM to temporarily avoid the use of the path. Any additional errors might cause the MPIO disk path to fail.
Clo
Indicates that the MPIO disk path is closed. If all MPIO disk paths to a device are closed, the device is considered to be closed. If only some MPIO disk paths are closed, then those paths might have experienced errors during the last time the device was opened. The AIX MPIO periodically attempts to recover closed paths until the device path is open.
PFa
Indicates that the remote port failed. When the PCM receives an event that indicates that the remote port used by the MPIO disk path is no longer part of the SAN fabric, the PCM marks the path as a failed path. The PCM clears the PFa state when the remote port rejoins the SAN fabric.
PCn
Indicates that the SAN fabric reported network traffic congestion to the remote port that is used by the MPIO disk path. The PCM does not use this MPIO disk path if other MPIO disk paths without the network traffic congestion are available for the MPIO device. The PCM automatically clears the PCn state if the SAN fabric does not report any recent network traffic congestion events.
PDg
Indicates a degraded remote port. The degraded port might experience many errors even though the MPIO disk path to the remote port remains active. Such degraded port cannot process data. The PCM avoids such disk path. To clear the degraded status of the port, you must first disable the degraded port on the switch that the port belongs to and then enable that port. If the PDg state occurs repeatedly on a path, investigate the ports and fibers used by the path to identify any issues with the SAN hardware.
LCn
Indicates that the link that is associated with the AIX adapter is congested because large amount of data is being sent to or from the AIX adapter. The PCM avoids such MPIO disk paths if other MPIO disk paths without the link congestion are available. The PCM automatically clears the LCn state if the SAN fabric does not report any recent link congestion events.
Deferred
start of changeIndicates a newly added path to a currently open disk. The MPIO disk path cannot be opened and used immediately because of internal restrictions. However, the disk path can be opened and used when the disk is re-opened next time.end of change
CtlrRstErr
Indicates that the nonvolatile memory express (NVMe) controller in the target that is associated with the MPIO disk path might not be reset. A reset is required before enabling the controller.
CtlrRdyErr
Indicates that the NVMe controller in the target that is associated with the MPIO disk path could not be enabled (to make it ready). The controller must become ready for the path to work.
HostDDErr
Indicates that the NVMe host driver in AIX detected a software error or ran out of system resources.
Offline
Indicates that the NVMe controller has been set to offline manually preventing it from being used for disk I/O operations.
AdminCmdErr
Indicates that an NVMe Admin command, such as Identify, has failed. Certain NVMe Admin commands are issued during MPIO disk path initialization. If the command fails, the MPIO disk path is marked as failed.
FabCmdErr
Indicates that an NVMe Fabrics command, such as Set Property, has failed. Certain NVMe Fabrics commands are issued during MPIO disk path initialization. If the command fails, the MPIO disk path is marked as failed.
ConnectErr
Indicates that the Connect command has failed. The Connect command is a Fabrics command that is used to form an association between the host and an NVMe controller in the target device. A successful connection is one of the first steps that are required to establish a working MPIO disk path.
AuthErr
Indicates that the target device requires the host to be authenticated but authentication failed.
HbaErr
Indicates that a Host Bus Adapter containing a locally attached NVMe drive has failed or the PCIe slot it resides in has failed. This can happen when the NVMe drive causes repeated errors in accessing system memory.
CrqErr
Indicates that the Create I/O Queue command has failed. This NVMe command is used to create queues in a locally attached NVMe drive. The MPIO disk path is unusable if I/O queues are not associated with it.
LinkDwnErr
Indicates that the Fiber Channel Link on the host port is currently down.
FCloginErr
Indicates that the Fiber Channel (FC) Login (PLOGI, FLOGI or PRLI) has failed.
CassErr
Indicates that the Create Association service has failed. The Create Association service is an NVMe over FC Link Service to establish a transport level association between the host and an NVMe controller. This association is required before the path to an FC attached NVMe storage subsystem can be established.
CiocErr
Indicates that the Create I/O Connection service has failed. The Create I/O Connection service is an NVMe over FC Link Service to establish a transport level I/O connection between the host and a NVMe controller. This connection is required before the path to an FC attached NVMe storage subsystem can be established.
FCDDErr
Indicates that the Fiber Channel driver in AIX has encountered a software error or ran out of system resources.
EndpntMiss
Indicates that one or more ports of the NVMe storage subsystem is missing on the FC fabric. The physical connectivity of the storage subsystem might have been impaired.

start of changeAdditional NVMe extended statusend of change

When the status of the MPIO disk path is Failed, the following extended status can be seen as an additional detail as to why the path has failed:
Table 1. NVMe extended status
Status Description
Offline Indicates that the disk path has been manually set to offline. You must not manually set the path to offline unless advised by technical support.
FCloginErr, LinkDwnErr, CassErr, CiocErr, EndpntMiss Indicates various NVMe over Fiber Channel error conditions. The most likely condition is CassErr that means the Create Association service to the target controller has failed. This normally means the host (NQN) is not properly mapped to the target device.
CtlrRstErr, CtlrRdyErr, AdminCmdErr, ConnectErr, AuthErr, FabCmdErr, HbaErr, CrqErr Indicates various NVMe error conditions that are useful to technical support personnel.
FCDDErr, HostDDErr Indicates driver errors such as exceeding internal resource limits.

Path statistics

The -S flag, along with the optional -d flag, causes the lsmpio command to display normal or detailed path statistics. The optional -l flag restricts the display to contain statistics for just one MPIO storage device. The statistics include how many times the MPIO disk path has been selected for an I/O operation, how many errors have occurred on the MPIO disk path, and how many times the MPIO disk path has failed. The detailed statistics information breaks down the failure counts, into counts of different types of failures.

Device inquiry data

The -q flag of the lsmpio command causes the AIX MPIO to query the device, by using Small Computer System Interface (SCSI) commands to retrieve and display information about the attached device. Because each queried device is opened and queried by using SCSI commands, this operation might take time to run for many devices.

Parent adapter information

The -a flag, along with the optional -r flag, causes the lsmpio command to display information about the Fibre Channel adapters that are used by the AIX MPIO storage devices. The information includes details about the local adapter identifier, such as the worldwide name of Fibre Channel adapters and the current state of the MPIO disk path, if available. The -r flag adds information about remote ports, which are accessed by the Fibre Channel adapter.

You can use the -z flag to reset all statistics to zero.

Flags

Item Description
-a Lists parent Fibre channel adapter information.
-d Displays detailed statistics. This flag is only valid with the -S flag.
-e When this flag is used with the -a flag, error counts for the local adapter ports are displayed. When this flag is used with the -a and -r flags, error counts for local adapter ports and remote ports are displayed.

These error counts indicate an issue with the physical connectivity between the local adapter and the remote storage port. The error counts indicate recent errors for different time ranges.

-h Displays command usage information.
-l disk_name Specifies a device. If this flag is included, the command operates on a single device. If this flag is omitted, the command operates on all AIX MPIO devices. This flag can be used by itself for the summary path status, or with the -q, -S, or -z flags.
-o Indicates that the AIX disk driver attempts to access all multipath I/O (MPIO) that are associated with the specified MPIO disks. The attempt includes accessing the MPIO paths that were marked as failed when the MPIO disk was last closed. This flag provides an up-to-date status about the MPIO path.
Attention: If you attempt to access failed MPIO disk paths, the response time for the lsmpio command can be slower. The response time can be delayed by a few seconds or several minutes depending on several factors such as the number of MPIO disks that are impacted and the scope of the lsmpio command.
-q Queries the device information. This command uses standard SCSI commands to query the device for information. The precise information returned varies, depending on the device type.
-r Displays the remote port information. This flag is used along with the -a flag to display information about remote ports that are accessed by an adapter. The information that is returned might depend on the network protocol that is used by the adapter.
-S Displays statistics for one or all devices. This flag displays basic counters for path use and path errors. If the -d flag is used along with this flag, it displays more detailed statistics.
-z Resets all statistics. If this flag is used, it causes the PCM to reset all statistical counters back to zero.
Note: You can use the -z flag with the -a flag to reset the adapter error counts.

Security

Attention RBAC users and Trusted AIX users: This command can perform privileged operations. Only privileged users can run privileged operations. For more information about authorizations and privileges, see Privileged Command Database in Security. For a list of privileges and the authorizations that are associated with this command, see the lssecattr command or the getcmdattr subcommand.

Examples

Examples of displaying MPIO information:

  1. To display the summary information for the hdisk1234 device, enter the following command:
    lsmpio -l hdisk1234
    The system displays an output similar to the following output:
    name   path_id status  path_status     parent connection
    ===============================================================================
    hdisk1234  0   Enabled Opt,Sel,Deg,Rsv fscsi0 500a098186a7d4ca,0008000000000000
    hdisk1234  1   Enabled Non             fscsi0 500a098196a7d4ca,0008000000000000
    hdisk1234  2   Enabled Opt,Sel         fscsi1 500a098186a7d4ca,0008000000000000
    hdisk1234  3   Enabled Non             fscsi1 500a098196a7d4ca,0008000000000000
  2. To display detailed device statistics for the hdisk10 device, enter the following command:
    lsmpio -Sdl hdisk10
    The system displays an output similar to the following output:
    Disk: hdisk10
        Path statistics since Tue May 21 17:38:43 CDT 2013
        Path 0: (fscsi0:500a098186a7d4ca,8000000000000)
            Path Selections:                                    0
            Adapter Errors:                                     0
                Software:                        0
                Hardware:                        0
                Transport Dead:                  0
                Transport Busy:                  0
                Transport Fault:                 0
                No Device Response:              0
                Target Port ID Changed:          0
            Command Timeouts:                                   0
            Reservation Conflicts:                              0
            SCSI Queue Full:                                    0
            SCSI Busy:                                          0
            SCSI ACA Active:                                    0
            SCSI Task Aborted:                                  0
            SCSI Aborted Command:                               0
            SCSI Check Condition:                               0
                Medium Error:                    0
                Hardware Error:                  0
                Not Ready:                       0
                Other:                           0
            Last Error:                                       N/A
            Last Error Time:                                  N/A
            Path Failure Count:                                 0
                Due to Adapter Error:            0
                Due to I/O Error:                0
                Due to Health Check:             0
                Due to SCSI Sense:               0
                Due to Qualifier Bit:            0
                Due to Opening Error:            0
            Last Path Failure:                                N/A
            Last Path Failure Time:                           N/A
    Note: If some SCSI error counts are reported, it does not indicate a problem or indicate that I/O operations have failed. During regular processing, temporary, recoverable errors might be reported frequently, and therefore, the I/O operation might be attempted again.
  3. To display MPIO adapter information with the remote port information, enter the following command:
    lsmpio -ar
    The system displays an output similar to the following output:
    Adapter Driver: fscsi0 - AIX PCM
        Adapter WWPN:  10000000c94c7bd6
        Link State:    Up
                              Paths      Paths      Paths      Paths
        Remote Ports        Enabled   Disabled     Failed    Missing         ID
        500a098186a7d4ca         31          0          0          0    0x20a00
        500a098196a7d4ca         31          0          0          0    0x20b00
        500507630a18016b         19          0          0          0    0x31200
        500507630a18416b         19          0          0          0    0x31300
        500507630a18816b         19          0          0          0    0x31400
        500507630a18c16b         19          0          0          0    0x31500
    
    Adapter Driver: fscsi1 - AIX PCM
        Adapter WWPN:  10000000c94c7bd7
        Link State:    Up
                              Paths      Paths      Paths      Paths
        Remote Ports        Enabled   Disabled     Failed    Missing         ID
        500a098186a7d4ca         31          0          0          0    0x20a00
        500a098196a7d4ca         31          0          0          0    0x20b00
        500507630a18016b         19          0          0          0    0x31200
        500507630a18416b         19          0          0          0    0x31300
        500507630a18816b         19          0          0          0    0x31400
        500507630a18c16b         19          0          0          0    0x31500
        5001738000330150          1          0          0          0    0x10100
        5001738000330162          1          0          0          0    0x10200
  4. To query an MPIO storage device and display information about it, enter the following command:
    lsmpio -ql hdisk48
    The system displays an output similar to the following output:
    Device:  hdisk48
              Vendor Id:  IBM
             Product Id:  2107900
               Revision:  .160
               Capacity:  10G
          Volume Serial:  600507630AFFC16B0000000000001505  (Page 83 NAA)
    Note: The output that is displayed is derived from the standard inquiry data and the device identification vital product data (VPD). If the device represents a Peer-to-Peer Remote Copy (PPRC) pair (the san_rep_device attribute has a value of yes), the display includes the volume serial number for each logical unit number (LUN) in the PPRC pair and the vendor-specific ID that is shared by the two LUNs of the PPRC pair, as shown in the following output:
    Device:  hdisk33
              Vendor Id:  IBM
             Product Id:  2107900
               Revision:  .160
               Capacity:  10G
          Volume Serial:  600507630AFFC16B0000000000000113  (Page 83 NAA)
          Volume Serial:  600507630AFFC16B000000000000031F  (Page 83 NAA)
          Vendor LUN Id:  3735544C37373130313133005022AD6A  
  5. To display local and remote port error counts, enter the following command:
    lsmpio -are
    The output might be similar to the following sample:
    
    Adapter Driver: fscsi3 -> AIX PCM
        Adapter WWPN:  21000024ff6aee7d
        Link State:    Up
        Connectivity Errors:
            Last 10 Minutes:      74
            Last 60 Minutes:     222
            Last 24 Hours:     12345
    
                                    Connectivity Errors
                                 Last 10   Last 60   Last 24
        Remote Ports             Minutes   Minutes   Hours
        5001738000330171             0         0         0
        5001738000330173             0         0         0
        500a098286a7d4ca             2         9        45
        500a098196a7d4ca            72       213     12300