La commande 'lsmpio' affiche les informations de connexion des disques SAN gérés via MPIO.

 

Cette commande est plus détaillée que la traditionnelle 'lspath', et les informations diffèrent :

# lsmpio 

name path_id status path_status parent connection

hdisk0 0 Enabled Sel fscsi0     50060e80007b9d46,0
hdisk0 1 Enabled fscsi2         50060e80007b9d56,0
hdisk1 0 Enabled Sel fscsi0     50060e80007b9d46,1000000000000
hdisk1 1 Enabled fscsi2         50060e80007b9d56,1000000000000
hdisk2 0 Enabled Clo fscsi0     50060e80007b9d46,2000000000000
hdisk2 1 Enabled Clo fscsi2     50060e80007b9d56,2000000000000

Avec l'option '-a', la commande donne les informations sur les cartes utilisées(hba)

# lsmpio -a

Adapter Driver: fscsi0 -> AIX PCM
Adapter WWPN: 100000900007784a
Link State: Up

Adapter Driver: fscsi2 -> AIX PCM
Adapter WWPN: 10000090000449b0
Link State: Up

lsmpio -q

Device           Vendor Id  Product Id       Size    Volume Name

------------------------------------------------------------------------------

hdisk0           HITACHI    OPEN-V               40G  -

hdisk1           HITACHI    OPEN-V               20G  -

hdisk2           HITACHI    OPEN-V                3G  -

hdisk3           HITACHI    OPEN-V              500G  -

hdisk4           HITACHI    OPEN-V               20G  -

hdisk5           HITACHI    OPEN-V               50G  -

hdisk6           HITACHI    OPEN-V              100G  -

hdisk7           HITACHI    OPEN-V              100G  -

hdisk8           HITACHI    OPEN-V              200G  -

hdisk9           HITACHI    OPEN-V              200G  -

hdisk10          HITACHI    OPEN-V              200G  -

hdisk11          HITACHI    OPEN-V              200G  -

#lsmpio -S

Disk: hdisk0

    Path statistics since Wed Feb 04 12:23:20 CET 2015

    Path 0: (fscsi0:50060e80167b9d46,0)

        Path Selections:                             23158709

        Adapter Errors:                                     0

        Command Timeouts:                                   0

        Reservation Conflicts:                              1

        SCSI Queue Full:                                    0

        SCSI Busy:                                          0

        SCSI ACA Active:                                    0

        SCSI Task Aborted:                                  0

        SCSI Aborted Command:                               0

        SCSI Check Condition:                               5

        Last Error:                                  SCSI Check Condition

        Last Error Time:                             Wed Feb 04 12:23:21 CET 2015

        Path Failure Count:                                 0

        Last Path Failure:                                N/A

        Last Path Failure Time:                           N/A


L'option '-z' permet de remettre à zéro les statistiques.

La documentation officielle est donnée ci-dessous :

lsmpio Command

Purpose

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

Syntax

       lsmpio [ -l device_name ]

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

       lsmpio -z [ -l device_name ]

       lsmpio -q [ -l device_name ]

       lsmpio -a [ -r ]

       lsmpio -h

Description

       The lsmpio command displays information that is related to AIX MPIO storage devices. This command works only for

       devices that are controlled by path-control modules (PCMs) that are enabled for lsmpio support.

       There are four types of information that the lsmpio command displays:

       *    Path operational status

       *    Path statistics

       *    Device inquiry data

       *    Parent adapter information

       The lsmpio command can also be used to reset the path statistics to zero.

       Displaying path operational status

       If the lsmpio command is run without any flags or with the -l flag, it displays the path operational status. This

       output is similar the output displayed by running the lspath command, with an additional Extended Status field:

       lspath -F "path_id status parent connection"

       If the -l flag is not included, the status is shown for all MPIO paths in the system. If the -l flag and device

       name are included, the status is shown only for those paths that are used to attach the specified device.

       The Path Status column shows the same status as the lspath command. The valid values of status are Enabled,

       Disabled, Failed, or Missing.

       The Extended Status field might contain one or more three-letter status abbreviations to provide more detailed

       path status.

       Note: Not all extended status types are applicable to all devices.

       The possible values for the Extended Status field follow:

       Opt

            Indicates that the path is an optimized path. This value indicates a path that attaches to a preferred

            controller in a device that has multiple controllers. The PCM selects one of the preferred paths for I/O

            operations, whenever possible.

       Non

            Indicates that the path is a non-optimized path. On a device with preferred 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.

       Act

            Indicates that the path is an active path on a device that has active and passive controllers. The PCM

            selects active paths for I/O operations on such a device.

       Pas

            Indicates that the 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 path is being selected for I/O operations, for the time when the lsmpio command is to be

            run.

       Rsv

            Indicates that the 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 path experienced a failure. It is possible for a path to have a Path Status value of

            Enabled and still have an Extended Status value of Fai. This scenario indicates that operations sent on this

            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 paths are experiencing errors.

       Deg

            Indicates that the path is in a degraded state. This scenario indicates that the 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 path to fail.

       Clo

            Indicates that the path is closed. If all paths to a device are closed, the device is considered to be

            closed. If only some 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.

       Displaying 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 allows the user to restrict the display to contain statistics for just one MPIO

       storage device. The statistics include how many times the path has been selected for an I/O operation, how many

       errors have occurred on the path, and how many times the path has failed. The detailed statistics information

       breaks down the failure counts, into counts of different types of failures.

       Displaying 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. Becasue each queried

       device is opened and queried by using SCSI commands, this operation might take time to run when there are many

       devices.

       Displaying 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 the details about the

       local adapter identifier, such as the worldwide name for Fibre Channel adapters and the current state of the

       link, if available. The -r flag adds information about the remote ports, which are accessed by the adapter.

       Resetting statistics

       The -z flag causes the lsmpio command to reset all statistics to zero. By default, the statistics for all devices

       are reset. The -l flag can be used to reset the statistics for only a single device.

Flags

       Item

            Description

       -a

            Lists parent Fibre channel adapter information.

       -d

            Displays detailed statistics. This flag is only valid with the -S flag.

       -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.

       -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

            the remote ports that are accessed by an adapter. The information returned might depend on the 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.

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 AIX Version 7.1 Security. For a list of privileges and the authorizations 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 that I/O operations have

            failed. It is normal during regular processing for temporary, recoverable errors to be reported, and for the

            I/O operation to be attempted again.

       3    To display MPIO adapter information with 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 a 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 information that is displayed comes from the standard inquiry data and the device identification

            VPD data. If the device represents a PPRC pair (the san_rep_device attribute has a value of yes), the

            display includes the volume serial number for each LUN in the pair, as well as the vendor-specific ID that

            is shared by the two LUNS of the pair, as shown here:

            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

icon phone
Téléphone/Whatsapp : +33 (0)6 83 84 85 74
icon phone