|Skip Navigation Links|
|Exit Print View|
|Oracle Solaris 11.1 Administration: SAN Configuration and Multipathing Oracle Solaris 11.1 Information Library|
This is a general list of tasks associated with configuring iSCSI initiators. Some of the tasks are optional depending on your network configuration needs. Some of the links below will take you to separate documents that describe network configuration and target configuration.
Review the following terminology before configuring iSCSI targets and initiators.
Review the following iSCSI recommendations before configuring iSCSI devices in your network.
Consider using multipathed device paths for increased availability.
Multiple connections per session (MCS) support allow multiple TCP/IP connections from the initiator to the target for the same iSCSI session.
Deploy iSCSI devices in a fast (gigE or better), dedicated network.
Use jumbo frames, if possible to allow more data to be transferred in each Ethernet transaction to reduce the number of frames.
Use CAT6 rated cables for Gigabit network infrastructures.
Segregate iSCSI storage networks from your local area network traffic
Configure multiple sessions or connections to utilize multiple threads in TCP/IP stack
Consider TCP tuning, such as disabling Nagle algorithm
In addition to physical security, use CHAP authentication, which ensures that each host has its own password.
Consider using iSNS target discovery domains, which enhance security by providing access control to targets that are not enabled with their own access controls, while limiting the logon process of each initiator to a relevant subset of the available targets in the network.
Dynamic device discovery – Two dynamic device discovery methods are available:
SendTargets – If an iSCSI node exposes a large number of targets, such as an iSCSI to Fibre-Channel bridge, you can supply the iSCSI node IP address/port combination and allow the iSCSI initiator to use the SendTargets features to perform the device discovery.
iSNS – The Internet Storage Name Service (iSNS) allows the iSCSI initiator to discover the targets to which it has access using as little configuration information as possible. It also provides state change notification to notify the iSCSI initiator when changes in the operational state of storage nodes occur. To use the iSNS discovery method, you can supply the iSNS server address/port combination and allow the iSCSI initiator to query the iSNS servers that you specified to perform the device discovery. The default port for the iSNS server is 3205. For more information about iSNS, see RFC 4171:
The iSNS discovery service provides an administrative model to discover all targets on a network.
For more information about setting up iSNS support in Oracle Solaris, see Chapter 12, Configuring and Managing the Oracle Solaris Internet Storage Name Service (iSNS), in Oracle Solaris 11.1 Administration: Devices and File Systems.
Static device discovery – If an iSCSI node has few targets or if you want to restrict the targets that the initiator attempts to access, you can statically configure the target-name by using the following static target address naming convention:
You can determine the static target address from the array's management tool.
Note - Do not configure an iSCSI target to be discovered by both static and dynamic device discovery methods. The consequence of using redundant discovery methods might be slow performance when the initiator is communicating with the iSCSI target device.
Part of the initiator configuration process is to identify the iSCSI target discovery method, which presents an initiator with a list of available targets. You can configure iSCSI targets for static, SendTargets, or iSNS dynamic discovery. Dynamic discovery using the SendTargets option is the optimum configuration for an iSCSI initiator that accesses a large number of targets, such over an iSCSI to Fibre Channel bridge. SendTargets dynamic discovery requires the IP address and port combination of the iSCSI target for the iSCSI initiator to perform the target discovery. The most common discovery method is SendTargets.
When configuring the target discovery method, you must provide the following information, depending on which method you choose:
SendTargets – Target IP address
iSNS – iSNS server address
Static – Target IP address and target name
For more information about configuring target discovery methods, see Configuring Dynamic or Static Target Discovery.
initiator# svcadm enable network/iscsi/initiator
target# ipadm show-addr ADDROBJ TYPE STATE ADDR lo0/v4 static ok 127.0.0.1/8 e1000g0/_b dhcp ok 188.8.131.52/24 lo0/v6 static ok ::1/128 e1000g0/_a addrconf ok fe80::123:1234:fe27:360c/10 target# itadm list-target -v TARGET NAME STATE SESSIONS iqn.1986-03.com.sun:02:73d12edc-9bb9-cb44-efc4-c3b36c123456 online 0 alias: - auth: none (defaults) targetchapuser: - targetchapsecret: unset tpg-tags: default
initiator# iscsiadm add static-config iqn.1986-03.com.sun:02:73d12edc-9bb9-cb44-efc4-c3b36c123456, 184.108.40.206
initiator# iscsiadm list static-config Static Configuration Target: iqn.1986-03.com.sun:02:73d12edc-9bb9-cb44-efc4-c3b36c123456, 220.127.116.11:3260
The iSCSI connection is not initiated until the discovery method is enabled. See the next step.
If you have configured a dynamically discovered (SendTargets) target, configure the SendTargets discovery method.
initiator# iscsiadm add discovery-address 18.104.22.168
If you have configured a dynamically discovered (iSNS) target, configure the iSNS discovery method.
initiator# iscsiadm add isns-server 22.214.171.124
If you have configured a dynamically discovered (SendTargets) target, enable the SendTargets discovery method.
initiator# iscsiadm modify discovery --sendtargets enable
If you have configured a dynamically discovered (iSNS) target, enable the iSNS discovery method.
initiator# iscsiadm modify discovery --iSNS enable
If you have configured static targets, enable the static target discovery method.
initiator# iscsiadm modify discovery --static enable
initiator# devfsadm -i iscsi
After the devices have been discovered by the Oracle Solaris iSCSI initiator, the login negotiation occurs automatically. The Oracle Solaris iSCSI driver determines the number of available LUs and creates the device nodes. Then, the iSCSI devices can be treated as any other SCSI device.
You can view the iSCSI disks on the local system by using the format utility.
initiator# format 0. c0t600144F0B5418B0000004DDAC7C10001d0 <SUN-COMSTAR-1.0 cyl 1022 alt 2 hd 128 sec 32> /scsi_vhci/disk@g600144f0b5418b0000004ddac7c10001 1. c8t0d0 <Sun-STK RAID INT-V1.0 cyl 17830 alt 2 hd 255 sec 63> /pci@0,0/pci10de,375@f/pci108e,286@0/disk@0,0 2. c8t1d0 <Sun-STK RAID INT-V1.0-136.61GB> /pci@0,0/pci10de,375@f/pci108e,286@0/disk@1,0 3. c8t2d0 <Sun-STK RAID INT-V1.0-136.61GB> /pci@0,0/pci10de,375@f/pci108e,286@0/disk@2,0 4. c8t3d0 <Sun-STK RAID INT-V1.0 cyl 17830 alt 2 hd 255 sec 63> /pci@0,0/pci10de,375@f/pci108e,286@0/disk@3,0 Specify disk (enter its number): 0 selecting c0t600144F0B5418B0000004DDAC7C10001d0 [disk formatted]
In the above output, disk 0 is an iSCSI LU under MPxIO control. Disks 1-4 are local disks.
initiator# zpool create pool-name c0t600144F0B5418B0000004DDAC7C10001d0 initiator# zfs create pool-name/fs-name
The ZFS file system is automatically mounted when created and is remounted at boot time.
The associated targets are logged out after you perform any of the following actions:
Remove a discovery address
Remove an iSNS server
Remove a static configuration
Disable a discovery method
This optional procedure assumes that you are logged in to the local system where access to an target device has already been configured.
If you need to disable the SendTargets discovery method, use the following command:
initiator# iscsiadm modify discovery --sendtargets disable
If you need to disable the iSNS discovery method, use the following command:
initiator# iscsiadm modify discovery --iSNS disable
initiator# iscsiadm modify discovery --static disable
Remove an iSCSI SendTargets discovery entry.
initiator# iscsiadm remove discovery-address 126.96.36.199:3260
Remove an iSCSI iSNS discovery entry.
# iscsiadm remove isns-server 188.8.131.52:3205
initiator# iscsiadm remove static-config eui.5000ABCD78945E2B,184.108.40.206
Note - If you attempt to disable or remove a discovery entry that has an associated logical unit (LU) in use, the disable or remove operation fails with the following message:
logical unit in use
If this errors occurs, stop all associated I/O on the LU, unmount the file systems. Then, repeat the disable or remove operation.
target# itadm delete-target target-IQN
This command might error if the target is still online or busy:
The target is online or busy. Use the -f (force) option, or 'stmfadm offline-target iqn.1986-03.com.sun:02:99619b8a-a4dc-4cfb-93f0-ee3de1234567' itadm delete-target failed with error 16