lsiscsiauth

Use the lsiscsiauth command to list the Challenge Handshake Authentication Protocol (CHAP) secret that is configured for authenticating an entity to the system.

Syntax

 lsiscsiauth    [  -nohdr  ]     [  -delim  delimiter  ] [  -filtervalue  attribute=value  ]   [  -filtervalue?  ]  

Parameters

-nohdr
(Optional) By default, headings are displayed for each column of data in a concise style view, and for each item of data in a detailed style view. The -nohdr parameter suppresses the display of these headings.
Note: If there is no data to be displayed, headings are not displayed.
-delim delimiter
(Optional) By default in a concise view, all columns of data are space-separated. The width of each column is set to the maximum width of each item of data. In a detailed view, each item of data has its own row, and if the headers are displayed, the data is separated from the header by a space. The -delim parameter overrides this behavior. Valid input for the -delim parameter is a 1-byte character. If you enter -delim : on the command line, the colon character (:) separates all items of data in a concise view; for example, the spacing of columns does not occur. In a detailed view, the data is separated from its header by the specified delimiter.
-filtervalueattribute=value
(Optional) Specifies a list of one or more filters. Only objects with a value that matches the filter attribute value are displayed. If a capacity is specified, the units must also be included.
Note: Some filters allow the asterisk character (*) when you enter the command. The following rules apply to the use of wildcard characters with the system CLI:
  • The wildcard character is an asterisk (*).
  • The command can contain a maximum of one wildcard.
  • When you use a wildcard, you must enclose the filter entry within double quotation marks (""), as follows:
    lsiscsiauth -filtervalue  "name=md*"
-filtervalue?
(Optional) displays a list of filters that can be applied against this view. The following filter attributes are valid for the lsiscsiauth command:
  • type
  • id
  • name
  • iscsi_auth_method
  • iscsi_chap_secret
  • cluster_iscsi_auth_method
  • cluster_iscsi_chap_secret
  • iscsiusername

For more information about filtering attributes, see Attributes of the -filtervalue parameters.

Description

This command lists the CHAP secret that is configured for authenticating an entity to the system. The command also displays the configured iSCSI authentication method. The iscsi_auth_method field can have values of none or chap.

When you create an iSCSI host by using the mkhost command with the iscsiname parameter, the host is initially configured with the authentication method as none, and no CHAP secret is set. To set a CHAP secret for authenticating the iSCSI host with the system, use the chhost command with the chapsecret parameter.

This table provides the attribute values that can be displayed as output view data.
Table 1. lsiscsiauth output
Attribute Description
type Indicates the iSCSI system type.
id Indicates the iSCSI system ID.
name Indicates the iSCSI system name.
iscsi_auth_method Indicates the iSCSI authentication method.
iscsi_chap_secret Indicates whether an iSCSI CHAP secret exists.
cluster_iscsi_auth_method Indicates clustered system iSCSI authentication method.
cluster_iscsi_chap_secret Indicates the clustered system iSCSI configured CHAP secret.
iscsiusername Indicates the iSCSI user name.

An invocation example

lsiscsiauth

The following output is displayed:

type   id   name        iscsi_auth_method   iscsi_chap_secret   cluster_iscsi_auth_method   cluster_iscsi_chap_secret
host   0    mchost20    none                                    none
host   1    mchost30    none                                    none
host   2    mchost200   none                                    none
host   3    mchost40    none                                    none
host   4    mchost240   none                                    none
host   5    mchost170   none                                    none
host   6    mchost120   none                                    none
host   7    mchost60    none                                    none
host   8    mchost180   none                                    none
host   9    mchost13    none                                    none
host   10   newhost     none                                    none

An invocation example

lsiscsiauth -iscsiusername

The following output is displayed:

type   id   name        iscsi_auth_method   iscsiusername   iscsi_chap_secret   
host   0    host0       chap                rhel_host1      rhel_secret

An invocation example

iscsiusername

The following output is displayed:

type   id   name        iscsi_auth_method   iscsiusername   iscsi_chap_secret   
host   0    host0       chap                -               rhel_secret