8.4.4. Setting up iSCSI Services

This section contains a comprehensive step-by-step on how to create and setup iSCSI services on Napp-IT.

Tip

Keep in mind that if you complete this guide and its steps properly and the Targets still do not show up in an Initiator, it might be Napp-IT locking you out of the feature until you have a VALID LICENSE KEY.

Summary

If you’re looking to quickly create a service without going over the step-by-step in too much detail:

  • Create a ZPOOL (If you wish to use Volume-based LUNs)

  • Enable the Comstar, iSCSI services

  • Create a ZVOL in the ZPOOL from Comstar itself

  • Create a Volume-Based LUN on that Dataset

  • Create a Target

  • Create a Target-Group that includes your desired Target(s)

  • Create a View that includes that Target Group

Setting up iSCSI Volumes

The first thing you’ll need to do is setup the volumes you’ll use for the Logical Unit Numbers, or LUNs. To do this go to Comstar → Zvols → Create Volumes

../../../../_images/comstar-1-zvols.png

Here you’ll want to create a Volume/Dataset inside your desired ZPOOL for iSCSI usage. Just choose whatever size your heart desires (and the disks can muster) and hit create!

../../../../_images/iscsizvols1.png

You can also check ZVOLs from this screen, however, unlike the ZFS Filesystems one, you’ll get the LU GUID

../../../../_images/iscsizvols2.png

Setting up LUNs

Once you’ve created the volumes (You can also create File based LUNs or RAW LUNs) you can head to Comstar → Logical Units → Create Volume LU

../../../../_images/comstar-2-luns.png

Select your desired volume to use in the iSCSI LU and simply hit create!

../../../../_images/iscsiluns2.png

You can also see all the currently available LUs by clicking in Comstar → Logical Units

../../../../_images/iscsiluns1.png

Now let’s keep moving forward and create an iSCSI Target.

Setting up the iSCSI Target(s)

To create an iSCSI Target go to the section Comstar → Targets

../../../../_images/comstar-3-targets.png

Here you’ll be able to see currently available Targets and add a new one with the button at the bottom of the list.

../../../../_images/iscsitarget1.png

When you click “++add target” the following window will show up:

../../../../_images/iscsitarget2.png

You can leave the randomly generated iqn name or create one yourself.

Setting up Views

Once you’ve created the Target you must add the Logical Unit to a Host-Group and Target-Group.
  • To create a Host-Group read this first - Setting up Host Groups

    Note

    A host-group allows you to filter so that specific hosts can access the target/target-group.

  • To create a Target-Group read this first - Setting up Target Groups

Go to Comstar → Views and hit “add view”.

../../../../_images/comstar-4-views.png

Here you should be able to add your desired LUN to all host-groups and target-groups or a specific one if you so desire.

../../../../_images/iscsiview1.png
Once you’ve added the LU GUID to the View (which is associated to Target and Host Groups) you can move on to the next step:

Setting up Host Groups

To create a host-group (clients) go to Comstar → Host-Groups → create host-group

../../../../_images/comstar-5-hg.png

Create the Host-Group with whatever name you’d like:

../../../../_images/iscsihg-create.png

Once you’ve created the group go ahead and add members to it, you’ll need to know what Initiator Name is being used in each client, so you’ll have to check those.

../../../../_images/iscsihg-add.png ../../../../_images/iscsihg1.png

Select the Host-Group you want and add the Client Initiator names in the box:

../../../../_images/iscsihg2.png

After you hit Submit you should see your Initiator(s) added down below in the Host-Group.

Setting up Target Groups

To create a Target-Group you need to follow very similar steps to the ones for creating a Host-Group.

Go to Comstar → Target-Groups → create Target-group

../../../../_images/comstar-6-tg.png

Choose a name for your Group and then hit create.

../../../../_images/iscsitg-create.png

Then add members to it by going to the add target section.

Write (or copy) the target you wish to add and select to which group.

../../../../_images/iscsitg-add.png

Once you’ve added the Target you should see it in the Target Groups list.

../../../../_images/iscsitg1.png

Setting up Target Portal Groups

Finally, create a Target Portal Group. This allows you to associate specific Network Interfaces or Addresses to a Target Group

Go to Comstar → Target Portal Groups → create portal-group

../../../../_images/comstar-7-tpg.png

Here you can choose which IP Addresses to use. If you’re using a High-Available application such as RSF-1, use the Virtual IP(s) you’ve setup for the ZPOOL you wish to share through this portal group.

Create the portal group.

../../../../_images/iscsipg2.png

After you’ve created the portal group, add the targets you wish to publish on this/these IP Address/es.

../../../../_images/iscsipg4.png

Done! You should see your iSCSI Targets in the Portal Group down below.

../../../../_images/iscsipg1.png