How to Configure iSCSI Target Ports

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.

  1. Log in to the target device and search for iSCSI services that are active.
    svcs -a | grep -i iscsi
    
  2. 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.

  1. Enable the iscsit service.
    # svcadm enable -r svc:/network/iscsi/target:default
    
  2. Verify that the service is enabled.
    # svcs -a | grep iscsi
    
    online  14:21:25 svc:/network/iscsi/target:default
    
  3. Create an iSCSI target port.
    # itadm create-target
    
    Target: iqn.1986-03.com.sun:02:97c1caa8-5732-ec53-b7a2-a722a946fead
    successfully created
    
  4. 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
    
Where to Go Next

Labels

task task Delete
smallsiteadmin smallsiteadmin Delete
configuring configuring Delete
storage storage Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. 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.

    1. 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.

      1. 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:

        • SUNWiscsitu
        • SUNWiscsitr
        • SUNWiscsidmu
        • SUNWiscsidmr
        • SUNWstmf
        • SUNWstmfu

        The iSCSItr package contains the iSCSIt driver.

        1. 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?

Sign up or Log in to add a comment or watch this page.


The individuals who post here are part of the extended Sun Microsystems community and they might not be employed or in any way formally affiliated with Sun Microsystems. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Sun nor any other party necessarily agrees with them.

Copyright 1994-2009 Sun Microsystems, Inc.
Powered by Atlassian Confluence
Sun Guidelines on Public Discourse Privacy Policy Terms of Use Trademarks Site Map Employment Investor Relations Contact