Knowledge Base

How to use the iSCSI Target service on Synology NAS

Overview

iSCSI is a protocol to facilitate SCSI-based storage commands to be sent over ubiquitous network structures, such as a LAN or VPN. Using the iSCSI Target service provides an illusion that a hard drive is locally attached to a computer, and will be managed by a local computer's operating system. In reality, the newly added disk is a virtual drive which exists on the Synology NAS. Because the hard drive is virtual, there is no need to add additional hardware to the computer, as the virtual drive is administered through a common network infrastructure.

This article will guide the administrator through the basics of creating an iSCSI LUN on Synology NAS, which can be used with an iSCSI Target for virtual storage.

Contents

  1. How to create an iSCSI Target on Synology NAS
  2. iSCSI LUN advanced options
  3. iSCSI Target advanced options

1. How to create an iSCSI Target on Synology NAS

  1. Log into DSM as admin.
  2. Go to Storage Manager > iSCSI LUN, and click Create.
  3. Select a LUN type:
    • File-Level iSCSI allows the creation of Targets on existing storage volumes, so that storage may be shared between the two storage systems. This tutorial will cover how to create File-Level iSCSI.
    • Block-Level iSCSI offers faster performance, but requires the usage of an entire storage volume. Using this wizard will involve additional steps to create the Target compared to file-based iSCSI, and will be similar to creating a RAID volume on Synology NAS.
  4. Note: For more information about File/Block-Level iSCSI, please refer to here.
  5. Specify the following information for the iSCSI LUN:
    • Name: Enter a name for the iSCSI LUN.
    • Tips: If you are using one LUN with one Target, please consider using the following format structure to name the iSCSI LUN.
      Format Structure: iqn.yyyy-mm.domain:device.ID
      Example: iqn.2010-10.Synology-iSCSI:VirtualDisk.01
    • Location: For Synology NAS that has more than one volumes, specify where the Target will reside.
    • Thin Provisioning: Available for file-based iSCSI LUNs. This option will allow the storage capacity of the iSCSI Target to be dynamic and allocated on-demand.
    • Important: Please make sure that the space of the iSCSI Target does not exceed the physical space of your Synology NAS. Data loss or communication errors with the iSCSI Target may occur if you did not follow the proper storage management. The administrator of Synology NAS is responsible for managing the data storage capacities of the Synology NAS.
    • Advanced LUN features: Available on ext4 file system. This setting can only be enabled during initial iSCSI LUN creation and cannot be changed afterwards.
    • Advanced LUN allocation unit size: Set the allocation unit size to optimize certain features for application server, such as Microsoft Exchange or SQL Server, or virtualization servers and storage acceleration technologies, such as Microsoft Windows ODX or VMware VAAI.
    • Capacity: Enter the capacity of the iSCSI Target in Gigabytes.
    • iSCSI Target mapping: Please select Create a new iSCSI Target.
    • Click Next to continue.
  6. Specify the following information for the iSCSI Target:
    • Name: Enter a name for the iSCSI Target.
    • Tips: If you are using one LUN with one Target, please consider using the following format structure to name the iSCSI Target.
      Format Structure: iqn.yyyy-mm.domain:device.ID
      Example: iqn.2010-10.Synology-iSCSI:VirtualDisk.01
    • IQN: Enter the IQN name for the iSCSI Target.
    • Note: The name can have up to 128 characters, including letters, numbers, colons, dashes, and periods.
      Format Structure: iqn.yyyy-mm.domain:device.ID
      Example: iqn.2010-10.Synology-iSCSI:VirtualDisk.01
    • Enable CHAP: CHAP will require iSCSI Initiators to be authenticated before using the iSCSI Target; Mutual CHAP will require both initiators and Targets to authenticate each other before facilitating communications. Enter a username (up to 12 characters, including letters or numbers) for the authentication as well as a password (12 to 16 characters, including letters or numbers). For more information about CHAP, please refer to here.
    • Click Next to continue.
  7. Confirm and click Apply to save the settings.
  8. You will see the new iSCSI LUN with a new iSCSI Target in the list.

Return to top

2. iSCSI LUN advanced options

In this section, we will cover the advanced options of a file-based iSCSI LUN.

Note: Please make sure that an iSCSI LUN has been created and has been mapped to an iSCSI Target before proceeding with the iSCSI LUN advanced options.
  1. Go to Storage Manager > iSCSI LUN, select an iSCSI LUN and click Edit > Properties.
  2. Modify any information if necessary.
  3. Note: For Block-based iSCSI LUNs, the capacity of the LUN can be adjusted by selecting the LUN and clicking on the Manage button > Volume Expansion.
  4. Under the Mapping tab, you can associate the LUN to many different Targets. Please note that this is an option for experienced administrators for specialized virtual storage environments.

Return to top

3. iSCSI Target advanced options

In this section, we will cover the advanced options of the iSCSI Target. Please make sure that you have created an iSCSI Target with a mapped LUN before proceeding with the advanced options of an iSCSI Target.

  1. Go to Storage Manager > iSCSI Target. Select an iSCSI Target and click Edit.
  2. Under the General tab, modify the name, IQN, and CHAP options if necessary.
  3. Under the Advanced tab, modify the following options if necessary:
    • CRC Checksum: Enable these options to have the iSCSI Initiator and Target to conduct CRC bit checking. This is typically reserved for those environments that need this level of error resiliency.
    • Allow multiple sessions from one or more iSCSI Initiators:
      • For iSCSI MPIO or MC/S, allow multiple sessions or Initiators to communicate with the same Target.
      • For multiple iSCSI Initiators, using this function requires a cluster-aware file system, such as VMware Virtual Machine File System, or Oracle Clustering File System. Failure to use a cluster-aware file system will result in data lost or corruption. For further information about using Synology NAS within clustering environments, please refer to here.
    • Maximum receive/send segment bytes: Adjusting the sending or receiving segment frame can yield differences in iSCSI performance. It is recommended to be used by experienced administrators only.
  4. Under the Mapping tab, you can associate the Target to many different LUNs. Please note that this is an option for experienced administrators for specialized virtual storage environments.
  5. Under the Masking tab, the Target can be made accessible or be denied by different iSCSI Initiators, based on the IQN of the iSCSI Initiator.

Return to top

Is this information useful for you? Yes No

Need technical support? Submit Support Form