ISCSI target driver iSCSI-SCST

ISCSI-SCST is a forked (with all respects) version of IET with updates to work over SCST as well as with many improvements and bugfixes. The reason of fork is that the necessary changes are intrusive and with the current IET merge policy, where only simple bugfix-like patches, which doesn't touch the core code, could be merged, it is very unlikely that they will be merged in the main IET trunk.

ISCSI-SCST has the following major advantages over the mainline IET:

  • It uses full power of SCST core without loosing any existing IET feature (except, maybe, illegal from SCSI specifications point of view MPIO). Namely, you can additionally use with it:
    • Pass-through mode with one to many relationship, i.e. when multiple initiators can connect to the exported pass-through devices. For instance, you can safely export your parallel SCSI tape or tape library on your iSCSI net and multiple initiators can share it without risk of data loss because of the shared usage. Existing "rawio" patch for IET supports only non-enforced 1:1 relationship, so it is unsafe to use it in multiple initiators environments.
    • More advances devices visibility management, when different initiators can see different set of devices with different access permissions from the same target.
    • O_DIRECT, i.e. "BLOCKIO on files", mode, which has all advantages of BLOCKIO, but also supports files on file systems. Sometimes, in the appropriate cases, this mode can make performance difference in 100% or even more.
    • With 4KB blocks you can forget about abysmal write performance caused by misaligned partitions. All modern OS'es, including Windows starting from, at least, Windows 2000, work perfectly with 4KB block devices without any additional storage or handling overhead.
    • Virtual CD/DVD-ROMs without necessity for manual patching.
    • Ability to create target devices emulators in the user space.
    • Ability to create multi-transport SCSI targets, which can export (possibly, the same) devices over multiple transports.
  • It has many code improvements and cleanups, including stability and iSCSI RFC violations fixes. Many IET users use it for ages without problems, so they consider it free from any real problem. But, in fact, unfortunately, it isn't so. IET works well only on "fast" paths and regularly used code branches. In many other less used cases IET has various problems, from simply ignoring error processing, as it is with memory allocations, and crashing itself with BUG() macro, as it is for malformed packets from initiators, to possible data corruption. See, for instance, this thread on a VMware forum about in which Russian roulette IET users play using it with VMware. ChangeLog file lists most noticeable fixes, but there were a lot of many other smaller ones.
  • Due to reworked I/O architecture and SCST backend iSCSI-SCST has better performance in many cases. In future with upcoming improvements in SCST core, like zero-copy with Linux cache FILEIO, the performance difference is going to be even bigger. Currently in tests from a single initiator over a single connection on 1GbE hardware over FILEIO vdisk iSCSI-SCST with default settings usually outperforms tuned for best performance IET a on on up to 100%. The difference is especially noticeably with real storage, not NULLIO or RAM disks. On 10GbE hardware the performance difference is often as high as 100-200% or even more. With higher number of initiators the difference will be even bigger. This is because iSCSI-SCST has less commands processing overhead per command, hence has smaller processing latency and puts less load on CPU.

Also, in contrast to IET, iSCSI-SCST is open for any new development, modifications and improvements, so people who want to fix or implement something new will not have to keep and maintain separate patches as it is currently necessary with IET. ISCSI-SCST is actively developed and going to gain in the future new features like support for multiple connections per session, error recovery levels >0, etc., which eventually make it really "Enterprise".

If you are an IET user before installation carefully read README files of both iSCSI-SCST and the SCST core. Especially pay attention that now the LUN information for iSCSI-SCST is configured not using iscsi-scstd.conf file in /etc, but using corresponding SCST facilities. This is because now the responsibilities are divided (as it should be) between the target driver (iSCSI-SCST) and the SCST core: target driver is responsible for handling targets and their parameters, SCST core is responsible for handling backstorage.

The latest stable version is 1.0.0. Requires Linux kernel version 2.6.16.x or higher and SCST version 1.0.0 or higher. Tested mostly on i386 and x86_64, but should work on any other supported by Linux platform.

You can find the latest development version of this driver in the SCST SVN. See the download page how to setup access to it.