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.
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.
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
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!
You can also check ZVOLs from this screen, however, unlike the ZFS Filesystems one, you’ll get the LU GUID
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
Select your desired volume to use in the iSCSI LU and simply hit create!
You can also see all the currently available LUs by clicking in Comstar → Logical Units
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
Here you’ll be able to see currently available Targets and add a new one with the button at the bottom of the list.
When you click “++add target” the following window will show up:
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
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”.
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.
- 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
Create the Host-Group with whatever name you’d like:
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.
Select the Host-Group you want and add the Client Initiator names in the box:
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
Choose a name for your Group and then hit create.
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.
Once you’ve added the Target you should see it in the Target Groups list.
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
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.
After you’ve created the portal group, add the targets you wish to publish on this/these IP Address/es.
Done! You should see your iSCSI Targets in the Portal Group down below.