Listing and Setting iSCSI Parameters with ESXCLI

You can list and set iSCSI parameters for software iSCSI and for dependent hardware iSCSI by using ESXCLI.
You can retrieve and set iSCSI parameters by running one of the following commands.
Parameter Type
Command
Adapter-level parameters
esxcli iscsi adapter param set --adapter=<vmhba> --key=<key> --value=<value>
Target-level parameters
esxcli iscsi adapter target portal param set --adapter=<vmhba> --key=<key> --value=<value> --address=<address> --name=<iqn.name>
Discovery-level parameters
esxcli iscsi adapter discovery sendtarget param set --adapter=<vmhba> --key=<key> --value=<value> --address=<address>
The following table lists all settable parameters. These parameters are also described in the IETF rfc 3720. You can run
esxcli iscsi adapter param get
to determine whether a parameter is settable or not.
The parameters in the table apply to software iSCSI and dependent hardware iSCSI.
Settable iSCSI Parameters
Parameter
Description
DataDigestType
Increases data integrity. When data digest is enabled, the system performs a checksum over each PDUs data part and verifies using the CRC32C algorithm.
Systems that use Intel Nehalem processors offload the iSCSI digest calculations for software iSCSI, thus reducing the impact on performance.
Valid values are
digestProhibited
,
digestDiscouraged
,
digestPreferred
, or
digestRequired
.
HeaderDigest
Increases data integrity. When header digest is enabled, the system performs a checksum over the header part of each iSCSI Protocol Data Unit (PDU) and verifies using the CRC32C algorithm.
MaxOutstandingR2T
Max Outstanding R2T defines the Ready to Transfer (R2T) PDUs that can be in transition before an acknowledgement PDU is received.
FirstBurstLength
Maximum amount of unsolicited data an iSCSI initiator can send to the target during the execution of a single SCSI command, in bytes.
MaxBurstLength
Maximum SCSI data payload in a Data-In or a solicited Data-Out iSCSI sequence, in bytes.
MaxRecvDataSegLen
Maximum data segment length, in bytes, that can be received in an iSCSI PDU.
NoopOutInterval
Time interval, in seconds, between NOP-Out requests sent from your iSCSI initiator to an iSCSI target. The NOP-Out requests serve as the ping mechanism to verify that a connection between the iSCSI initiator and the iSCSI target is active.
Supported only at the initiator level.
NoopOutTimeout
Amount of time, in seconds, that can lapse before your host receives a NOP-In message. The message is sent by the iSCSI target in response to the NOP-Out request. When the
NoopTimeout
limit is exceeded, the initiator terminates the current session and starts a new one.
Supported only at the initiator level.
RecoveryTimeout
Amount of time, in seconds, that can lapse while a session recovery is performed. If the timeout exceeds its limit, the iSCSI initiator terminates the session.
DelayedAck
Allows systems to delay acknowledgment of received data packets.
You can use the following ESXCLI commands to list parameter options.
  • Run
    esxcli iscsi adapter param get
    to list parameter options for the iSCSI adapter.
  • Run
    esxcli iscsi adapter discovery sendtarget param get
    or
    esxcli iscsi adapter target portal param set
    to retrieve information about iSCSI parameters and whether they are settable.
  • Run
    esxcli iscsi adapter discovery sendtarget param get
    or
    esxcli iscsi adapter target portal param set
    to set iSCSI parameter options.
If special characters are in the
<name>=<value>
sequence, for example, if you add a space, you must surround the sequence with double quotes (
"<name> = <value>"
).