How to Configure iSCSI Target Ports
The COMSTAR iSCSI port provider implements the iSCSI transport known as iscsit. The iscsit transport runs as a service (svc:/network/iscsi/target). You must enable iscsit for it to be recognized by STMF.
The OpenSolaris software (SXCE Build 103) contains another iSCSI target implementation known as the iSCSI target daemon that is controlled by the SMF service (svc:/system/iscsitgt:default). The iSCSI target daemon is used by iSCSI targets that run on Solaris 10, Nevada, Solaris Express Community Edition, and other OpenSolaris distributions. The iSCSI transport (iscsit) and the iSCSI target daemon (iscsitgtd) are not compatible with one another.
The following packages are required and you should install them before you configure the iSCSI target.
- SUNWiscsitu
- SUNWiscsitr
- SUNWiscsidmu
- SUNWiscsidmr
- SUNWstmf
- SUNWstmfu
| Important Note Due to the incompatibility between iscsit and iscsitgtd, you must decide which iSCSI target service to implement. Only one of these services can be active at a time. The other service must be disabled. |
iSCSI Targets
The itadm command manages iSCSI targets within the SCSI Target Mode Framework (STMF). This method allows iSCSI initiators to access STMF logical units using the iSCSI protocol. STMF treats iSCSI targets as local ports. You can then map logical units to iSCSI targets using the stmfadm command.
An iSCSI target is an access point to STMF logical units, and has no backing store associated with it directly. You can use one iSCSI target to access all STMF logical units. However, you might want to create targets for specific configurations, such as a target portal group that restricts traffic to specific network interface cards (NICs).
iSER Targets and Initiators
The iSCSI Extensions for RDMA (iSER) protocol accelerates the iSCSI protocol by mapping data transfers to remote direct memory access (RDMA) operations. As a result, an iSER initiator can read and write data from an iSER target at high data rates, with relatively low CPU utilization compared to iSCSI using TCP/IP. An InfiniBand Host Channel Adapter (HCA) is required to use iSER. For hosts with an InfiniBand-switched fabric communications link, you must configure IPoIB for the HCAs on both initiators and targets so they can communicate using IP. If an initiator can establish an InfiniBand reliable connected (RC) connection with the target, the initiator will automatically select iSER transport. The iSER protocol is not currently available on Ethernet networks.
How to Verify and Disable Active iSCSI Target Services
Use this procedure to determine whether an iSCSI service is running on your system. If iscsitgtd is running, disable it before continuing with configuring an iSCSI port for use with COMSTAR.
- Log in to the target device and search for iSCSI services that are active.
svcs -a | grep -i iscsi
- If iscsitgt is active, disable it.
# svcs iscsitgt STATE TIME FMRI online 14:20:11 svc:/system/iscsitgt:default svcadm disable iscsitgt
How to Configure an iSCSI Target Port
This procedure configures an iSCSI target port through which an iSCSI initiator will be able to access a SCSI logical unit.
- Enable the iscsit service.
# svcadm enable -r svc:/network/iscsi/target:default
- Verify that the service is enabled.
# svcs -a | grep iscsi
online 14:21:25 svc:/network/iscsi/target:default
- Create an iSCSI target port.
# itadm create-target
Target: iqn.1986-03.com.sun:02:97c1caa8-5732-ec53-b7a2-a722a946fead successfully created
- Verify that the target exists and make a note of the target name.
# itadm list-target
TARGET NAME STATE SESSIONS iqn.1986-03.com.sun:02:97c1caa8-5732-ec53-b7a2-a722a946fead online 0


Comments (4)
Jun 18
anythingyouwantdisplayed says:
in new version of opensolaris you have to install this http://pkg.opensolaris.or...in new version of opensolaris you have to install this http://pkg.opensolaris.org/release/en/search.shtml?token=itadm package before you can use this guide.
Jun 23
alan.mcclellan says:
Ah, so you need to install SUNWiscsit (Sun iSCSI COMSTAR Port Provider) before y...Ah, so you need to install SUNWiscsit (Sun iSCSI COMSTAR Port Provider) before you can configure an iSCSI target port. Doesn't look like that package is part of basic OpenSolaris installation.
Jun 29
DenaSteward says:
The following packages are required before you install SXCE Build 112: SUNWis...The following packages are required before you install SXCE Build 112:
The iSCSItr package contains the iSCSIt driver.
Jun 23
alan.mcclellan says:
So, which packages are required in addition to a generic OpenSolaris 2009.06 ins...So, which packages are required in addition to a generic OpenSolaris 2009.06 installation? Same set?