Displaying FCP channel and device information

Red Hat Enterprise Linux 8.6 LPAR mode z/VM guest

For each online FCP device, there is a number of read-only attributes in sysfs that provide information about the corresponding FCP channel and FCP device.

Before you begin

The FCP device must be online for the FCP channel information to be valid.

About this task

The following tables summarize the relevant attributes.

Table 1. Attributes with Fibre Channel adapter hardware information
Attribute Explanation
card_version Version number that identifies a particular hardware feature. Same as model in Table 3.
fc_security IBM® Fibre Channel Endpoint Security capabilities of the FCP channel. See Investigating IBM Fibre Channel Endpoint Security.
hardware_version Number that identifies a hardware version for a particular feature. The initial hardware version of a feature is zero. This version indicator is increased only for hardware modifications of the same feature. Appending hardware_version to card_version results in a hierarchical version indication for a physical adapter.

Same as hardware_version in Table 3.

lic_version Microcode level. Same as firmware_version in Table 3.
peer_wwnn WWNN of peer for a point-to-point connection.
peer_wwpn WWPN of peer for a point-to-point connection.
peer_d_id Destination ID of the peer for a point-to-point connection.
Table 2. Attributes with FCP device information
Attribute Explanation
in_recovery Shows if the FCP device is in recovery (0 or 1).

For the attributes availability, cmb_enable, and cutype, see Device directories. The status attribute is reserved.

Table 3. Relevant transport class attributes, fc_host attributes
Attribute Explanation
fabric_name Name of the attached fabric. The name is a 64-bit hexadecimal value.
For z13® and z14 hardware with FICON® Express16S or FICON Express16S+ features, this attribute contains valid fabric names only if the following minimum firmware level requirements are met.
z13
FICON Express16S: MCL P08424.005, LIC version 0x00000721
z14
FICON Express16S: MCL P42611.008, LIC version 0x10200069
FICON Express16S+: MCL P42625.010, LIC version 0x10300147
firmware_version Microcode level. Same as lic_version in Table 1
hardware_version Number that identifies a hardware version for a particular feature. The initial hardware version of a feature is zero. This version indicator is increased only for hardware modifications of the same feature. Appending hardware_version to card_version results in a hierarchical version indication for a physical adapter.

Same as hardware_version in Table 1

manufacturer Manufacturer of the FCP channel. The value is IBM.
maxframe_size Maximum frame size.
model Version number that identifies a particular hardware feature. Same as card_version in Table 1
permanent_port_name WWPN associated with the physical port of the FCP channel.
port_id A unique ID (N_Port_ID) assigned by the fabric. In an NPIV setup, each virtual port is assigned a different port_id.
port_name WWPN associated with the FCP device. If N_Port ID Virtualization is not available, the WWPN of the physical port (see permanent_port_name).
port_type The port type indicates the topology of the port.
serial_number The 32-byte serial number of the adapter hardware that provides the FCP channel.
speed Speed of FC link.
supported_classes Supported FC service class.
supported_speeds Supported speeds.
symbolic_name The symbolic port name that is registered with the FC name server.
tgid_bind_type Target binding type.
Table 4. Relevant transport class attributes, fc_host statistics
Attribute Explanation
reset_statistics Writeable attribute to reset statistic counters.
seconds_since_last_reset Seconds since last reset of statistic counters.
tx_frames Transmitted FC frames.
tx_words Transmitted FC words.
rx_frames Received FC frames.
rx_words Received FC words.
lip_count Number of LIP sequences.
nos_count Number of NOS sequences.
error_frames Number of frames that are received in error.
dumped_frames Number of frames that are lost because of lack of host resources.
link_failure_count Link failure count.
loss_of_sync_count Loss of synchronization count.
loss_of_signal_count Loss of signal count.
prim_seq_protocol_err_count Primitive sequence protocol error count.
invalid_tx_word_count Invalid transmission word count.
invalid_crc_count Invalid CRC count.
fcp_input_requests Number of FCP operations with data input.
fcp_output_requests Number of FCP operations with data output.
fcp_control_requests Number of FCP operations without data movement.
fcp_input_megabytes Megabytes of FCP data input.
fcp_output_megabytes Megabytes of FCP data output.

Procedure

Use the cat command to read an attribute.
  • Issue a command of this form to read an attribute:
    # cat /sys/bus/ccw/drivers/zfcp/<device_bus_id>/<attribute>
    where:
    <device_bus_id>
    specifies an FCP device that corresponds to the FCP channel.
    <attribute>
    is one of the attributes in Table 1 or Table 2.
  • To read attributes of the associated Fibre Channel host use:
    # cat /sys/class/fc_host/<host_name>/<attribute>
    where:
    <host_name>
    is the ID of the Fibre Channel host.
    <attribute>
    is one of the attributes in Table 3.
  • To read statistics attributes of the FCP channel associated with this Fibre Channel host, use:
    # cat /sys/class/fc_host/<host_name>/statistics/<attribute>
    where:
    <host_name>
    is the ID of the Fibre Channel host.
    <attribute>
    is one of the attributes in Table 4.

Examples

  • In this example, information is displayed about an FCP channel that corresponds to an FCP device with bus ID 0.0.3d0c:
    # cat /sys/bus/ccw/drivers/zfcp/0.0.3d0c/hardware_version
    0x00000000
    # cat /sys/bus/ccw/drivers/zfcp/0.0.3d0c/lic_version
    0x16500124
  • Alternatively you can use lszfcp to display attributes of an FCP channel:
    # lszfcp -b 0.0.3d0c -a
    0.0.3d0c host0
    Bus = "ccw"
        availability        = "good"
        card_version        = "0x0008"
        cmb_enable          = "0"
        cutype              = "1731/03"
        devtype             = "1732/03"
        failed              = "0"
        fc_security         = "Authentication, Encryption"
        hardware_version    = "0x00000000"
        in_recovery         = "0"
        lic_version         = "0x20600116"
        modalias            = "ccw:t1731m03dt1732dm03"
        online              = "1"
        peer_d_id           = "0x000000"
        peer_wwnn           = "0x0000000000000000"
        peer_wwpn           = "0x0000000000000000"
        status              = "0x5400040b"
        uevent              = "DRIVER=zfcp"
    Class = "fc_host"
        active_fc4s         = "0x00 0x00 0x01 0x00 ..."
        dev_loss_tmo        = "60"
        fabric_name         = "0x100000051e4a8f00"
        firmware_version    = "0x20600116"
        hardware_version    = "0x00000000"
        manufacturer        = "IBM"
        maxframe_size       = "2112 bytes"
        model               = "0x0008"
        node_name           = "0x5005076400c7ec87"
        permanent_port_name = "0xc05076ffd6801981"
        port_id             = "0x671a29"
        port_name           = "0xc05076ffd6801e10"
        port_state          = "Online"
        port_type           = "NPIV VPORT"
        serial_number       = "IBM0200000007EC87"
        speed               = "16 Gbit"
        supported_classes   = "Class 2, Class 3"
        supported_fc4s      = "0x00 0x00 0x01 0x00 ..."
        supported_speeds    = "8 Gbit, 16 Gbit"   
        symbolic_name       = "IBM type serial PCHID: 0198 NPIV UlpId: 05600300 DEVNO: 0.0.3d0c NAME: hostname.domain"
        tgtid_bind_type     = "wwpn (World Wide Port Name)"
    Class = "scsi_host"
        active_mode         = "Initiator"
        can_queue           = "4096"
        cmd_per_lun         = "0"
        eh_deadline         = "off"
        host_busy           = "0"
        megabytes           = "15 0"
        proc_name           = "zfcp"
        prot_capabilities   = "0"
        prot_guard_type     = "0"
        queue_full          = "0 2357653"
        requests            = "815 0 66"
        seconds_active      = "11"
        sg_prot_tablesize   = "0"
        sg_tablesize        = "574"
        state               = "running"
        supported_mode      = "Initiator"
        unchecked_isa_dma   = "0"
        unique_id           = "6400"
        use_blk_mq          = "1"
        utilization         = "0 0 0"