Configuring and Managing Static and Auto iSCSI device on AIX or VIOS

Configuring and Managing Static iSCSI device on AIX or VIOS

iSCSI is a TCP Protocol that stands for internet Small Computer Systems Interface. It enables the communication between the AIX / VIOS initiator to storage target (SAN). Process of configuring the AIX / VIOS iSCSI device involves connecting the Network Adapter to the Storage and allocating the disks from SAN to AIX / VIOS Initiators.

 



There are two categories of iSCSI devices stored in ODM first static - requires iSCSI target information such as target name, IP address and port number to get disks discovered. Second - automatically disks gets discovered but requires authentication. In the below steps we will be explaining how to configure and manage the static group of iSCSI device at the end will check out auto group of iSCSI device configuration.

Step 1: Querying the existing iSCSI device.

# lsdev | grep iscsi
iscsi0     Available             iSCSI Protocol Device
 
# lsattr -El iscsi0 | grep initiator_name
initiator_name     iqn.name.domain.qualified.fully.hostid.1234567
 
iqn.name.domain.qualified.fully.hostid.1234567 is the the initiator name of the above VIOS / AIX LPAR.

Step 2: Configure the Network Adapter with the same VLAN ID that Storage address is present.

# lsdev | grep entX
# ifconfig -a

Where entX is the adapter that is connected to SAN Storage

Step 3: Change the iSCSI Discovery Policy and iSCSI Network Error Recovery Policy to odm and fast_fail

# chdev  -l 'iscsi0' -a initiator_name=iqn.name.domain.qualified.fully.hostid.1234567 -a disc_policy='odm' -a isw_err_recov='fast_fail'

Step 4: Map the iSCSI device to Storage SAN IP Address

# mkiscsi -g static  -l 'iscsi0' -t 'iqn.storage.node' -i '9.x.x.x' -n '3260'

Where -l iscsi0 is the adapter name, -t iqn.storage.node is the storage target name, -i is ip address of target storage (SAN) and -n 3260 is iSCSI TCPIP Port number

Step 5: Refresh the iSCSI device and list disks

# cfgmgr -vl iscsi0 
# lsmpio
# lsiscsi
 
cfgmgr config manager command refreshes the device connected from storage via network to iscsi0 device. lsmpio command list multi path i/o will list out the disk name, path id, status of disk enabled or disabled, path status, parent device name and connection name (iSCSI target name and SAN IP address ). Similar to lsmpio, lsiscsi will also list the device name, SAN IP address, iSCSI port and iSCSI target name.

Optional Step: Creating another new iSCSI device and Copying the existing settings from old iSCSI device

# mkdev -c driver -s node -t iscsi -d
iscsi1 Defined
#
# cpiscsi -l iscsi1 -s iscsi0
#
 
If required we can created another iscsi device named iscsi1 on the AIX / VIOS partition and start getting the disk assigned to AIX / VIOS initiator. Once new device iscsi1 is created and copied the settings we should follow same steps from step4 and step5 the disks will be listed when lsmpio executed.
 

Auto Group of iSCSI device

# mkiscsi -g auto -l 'iscsi0' -t 'iqn.storage.node' -u username -p password
 
Configuring  iscsi device is the mkiscsi command change we need to use -g group as auto with -u username and -p password details. This command will auto configure devices.
 

Post a Comment

0 Comments