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 ] [ -f ]

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,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.
Following are the possible values for the path_status field:
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 nonoptimized 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.
Chg
Indicates 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.
Los
Indicates that the MPIO disk path lost access to data permanently and is no longer usable in the host. The storage target must be evaluated or diagnosed for possible problems.
Sby
Indicates that the MPIO disk path is a standby path. If an MPIO disk path is in the Sby state, the disk path cannot be used for I/O operations. A device-dependent operation on the storage device can change the state of the MPIO disk path to either Opt or Non state and then the MPIO disk path can be used for I/O operations.
NAv
Indicates that the MPIO disk path is not available. If an MPIO disk path is in the NAv state, the disk path cannot be used for I/O operations. A device-dependent operation on the storage device can change the state of the MPIO disk path to either Opt or Non state and then the MPIO disk path can be used for I/O operations.
Trn
Indicates that the MPIO disk path is switching between two valid states. If an MPIO disk path is in the Trn state, the disk path cannot be used for I/O operations. The state of the disk path changes from Trn state to another state automatically. An MPIO disk path cannot be in the Trn state for a long duration. However, the AIX operating system might not detect the change in the path status immediately.
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 experienced an unexpected reservation conflict. This value might indicate a usage or configuration error, with multiple hosts that access 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 did not mark the path as Failed. Sometimes, 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.
EEH
Indicates that the Fibre Channel adapter that is used by the MPIO disk path is experiencing an Enhanced Error Handling (EEH) event. When the Fibre Channel adapter, which is using the MPIO disk path for I/O operations, experiences an EEH error, the EEH event causes the PCM to temporarily avoid the MPIO disk path. MPIO disk paths with a status of EEH are considered as degraded because the I/O operation is blocked on the MPIO disk path during the EEH event. The path-selection algorithms prefer the Deg path status over the EEH path status and prefer EEH path status over an unusable path status, such as RSV. After the Fibre Channel adapter is back online and resumes I/O operations, the path status is changed from EEH to Deg, and the I/O operations resume on the MPIO disk path.
Clo
Indicates that the MPIO disk path is closed. A device is considered as closed if all MPIO disk paths that are connected to the device are 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 that is 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 that are 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
Indicates 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 reopened.
Additional NVMe extended status
When the status of the MPIO disk path is Failed, the following extended status can be seen as an extra detail as to why the path failed:
Table 1. NVMe extended status
Status Description
Offline Indicates that the disk path is 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 Fibre Channel error conditions. The most likely condition is CassErr that means the Create Association service to the target controller failed. The CassErr condition 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 is selected for an I/O operation, how many errors occurred on the MPIO disk path, and how many times the MPIO disk path 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.

start of change-fend of change start of changeWhen the -f flag is used with the -a flag, the Fabric Performance Impact Notification (fpin) error counts for the local adapter ports are displayed. When the -f flag is used with the -a and -r flags, fpin error counts for both the local adapter ports and remote storage ports are displayed. These fpin error counts indicate that either the local adapter ports or the remote storage ports are congested. For different predefined time ranges that are displayed in the output (for example, last 10 minutes, last 60 minutes, and last 24 hours), the fpin error counts indicate recent errors.end of change
-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 that is 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 and fpin error counts.

Security

Attention RBAC 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

  1. To display the summary information for the hdisk1234 device, enter the following command:
    lsmpio -l hdisk1234

    The system displays an output similar to one of the following outputs:

    • name   path_id status  path_status      parent connection
      ===============================================================================
      hdisk1234  0   Enabled Opt,Rsv          fscsi0 500a098186a7d4ca,0008000000000000
      hdisk1234  1   Enabled Non              fscsi0 500a098196a7d4ca,0008000000000000
      hdisk1234  2   Enabled Opt,Sel,EEH      fscsi1 500a098186a7d4ca,0008000000000000
      hdisk1234  3   Enabled Non              fscsi1 500a098196a7d4ca,0008000000000000

      In this example, path 0 is optimized but is marked as reserved (Rsv) that makes the path unusable. In this case, path 2 is selected for the I/O operations because the EEH state is preferred than the unusable Rsv state. Moreover, the path 0 might never be in the Deg state because it is already being avoided due to the Rsv state. The I/O requests might not be fulfilled because the adapter that is used by path 2 is rebooting because of the EEH error.

    • name   path_id status  path_status     parent connection
      ===============================================================================
      hdisk1234  0   Enabled Opt,Rsv         fscsi0 500a098186a7d4ca,0008000000000000
      hdisk1234  1   Enabled Non             fscsi0 500a098196a7d4ca,0008000000000000
      hdisk1234  2   Enabled Opt,EEH         fscsi1 500a098186a7d4ca,0008000000000000
      hdisk1234  3   Enabled Non             fscsi1 500a098196a7d4ca,0008000000000000
      hdisk1234  4   Enabled Opt,Sel,Deg     fscsi2 500a098186b7d4ca,0008000000000000
      hdisk1234  5   Enabled Non             fscsi2 500a098196b7d4ca,0008000000000000

      In this example, path 4 with the Deg state is preferred over path 2 with the EEH state. If you run iostat -m hdisk1234, the iostat command output shows that all the I/O operations are performed at path 4.

    • name   path_id status  path_status     parent connection
      ===============================================================================
      hdisk1234  0   Enabled Opt,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
      hdisk1234  4   Enabled Opt,Sel         fscsi2 500a098186b7d4ca,0008000000000000
      hdisk1234  5   Enabled Non             fscsi2 500a098196b7d4ca,0008000000000000

      In this example output, none of the paths have Deg or EEH state. In this case, path 2 or path 4 is selected based on shortest queue or round-robin algorithms.

    • name   path_id status  path_status     parent connection
      ===============================================================================
      hdisk1234  0   Enabled Opt,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
      hdisk1234  4   Enabled Opt             fscsi2 500a098186b7d4ca,0008000000000000
      hdisk1234  5   Enabled Non             fscsi2 500a098196b7d4ca,0008000000000000

      In this example, path 2 is selected. The device is using the fail_over algorithm. If path 2 fails, the I/O request fails over to path 4.

  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
                Enhanced Errror Handling (EEH):  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
                Due to PG SN Mismatch:           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 failed. During regular processing, temporary, recoverable errors might be reported frequently. These errors might cause the I/O operation to 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
  6. To display local and remote port fpin error counts, enter the following command:

    lsmpio -arf
    The output might be similar to the following sample:
    # lsmpio -arf
    Adapter Driver: fscsi1 -> AIX PCM
        Adapter WWPN:  100000109b1708ae
        FPIN STATE:    CLEAR
        FPIN Errors
        Last 10 Minutes:                          0
        Last 60 Minutes:                          0
        Last 24 Hours:                            0
        Total Adapter Errs:                       1
    
                                   FPIN Errors
                                Last 10     Last 60     Last 24     Total Peer  FPIN STATE
                                Minutes     Minutes     Hours       Errs
        5005076802164af3          0           0           0           4          CLEAR
        5005076802364af4          0           0           0           0          CLEAR
        5005076802464af4          0           0           0           0          CLEAR
        5005076802264af3          1           1           1           2            PCn
    
    Adapter Driver: fscsi0 -> AIX PCM
        Adapter WWPN:  100000109b1708ad
        FPIN STATE:     LCn,LI
        FPIN Errors
        Last 10 Minutes:                          1
        Last 60 Minutes:                          1
        Last 24 Hours:                            1
        Total Adapter Errs:                       2
    
                                   FPIN Errors
                                Last 10     Last 60     Last 24     Total Peer  FPIN STATE
                                Minutes     Minutes     Hours       Errs
        5005076802164af3          0           0           0           4             LI
        5005076802364af4          0           0           0           0          CLEAR
        5005076802464af4          0           0           0           0          CLEAR
        5005076802264af3          1           1           1           2            PCn