Features comparison between Linux SCSI targets
As on April 2009
| SCST | STGT | IET | LIO v3.0 | ||
|---|---|---|---|---|---|
| General | |||||
| Upstream kernel | - | Kernel part | - | - | |
| Generic Target Engine | + | + | iSCSI only | Under development | |
| Architecture | Kernel only | User space only 1 | - | Kernel only | |
| Stability | + | + 3 | + | Heavy development | |
| Performance 4 | ***** 5 | *** | **** | **** 6 | |
| Zero-Copy | **** | *** 7 | **** | **** | |
| Support for transports without expecting transfer values (parallel SCSI, SAS) | + | - | - | - | |
| Interface with user space | ProcFS | Custom | - | ConfigFS/IOCTL/ProcFS | |
| Major features | |||||
| Target drivers in kernel space | + | + | - | Under development | |
| Target drivers in user space | + | + | - | - | |
| Backstorage handlers in kernel space | + | - | - | + | |
| Backstorage handlers in user space | + | + | - | - | |
| Local access to emulated backstorage devices 8 | + | - | - | - | |
| Advanced devices access control 9 | + | - | - | - | |
| Support for Asynchronous Event Notifications (AEN) | + | - | - | - | |
| Notification for devices added/removed or resized through AENs or Unit Attentions | + | - | - | - | |
| Bidirectional Commands | + 10 | + | - | - | |
| Extended CDB (size >16 bytes) | + 10 | + | - | - | |
| Descriptor sense support | + | + | - | - | RESERVE/RELEASE (Windows 2003 clustering) | + | + | + | + | Safe RESERVE/RELEASE implementation according to SCSI requirements 11 | Safe | Safe | Not safe | Not safe | Safe implementation of Task Management commands 12 | Safe | Not safe | Not safe | Not safe |
| Persistent Reservations (Windows 2008 clustering) | - | - | - | Under development | |
| ALUA | - | - | - | Under development | |
| Failover Clustering | + | ? | + | + | |
| SCSI MIBs | - | - | - | - 13 | |
| Cluster Storage Integration | - | - | - | VHACS | |
| Supported SCSI transports | |||||
| iSCSI | + | + | + | + | |
| Fibre Channel | + | - | - | - | |
| SRP | + | - | - | - | |
| iSER | - | + | - | - | |
| Parallel (Wide) SCSI | + | - | - | - | |
| SAS | Under development | - | - | - | |
| FCoE | Under development | Under development | - | - | |
| IBM pSeries Virtual SCSI | - | + | - | - | |
| Supported backstorage | |||||
| Kernel side FILEIO | + | - | + | + | |
| Kernel side BLOCKIO | + | - | + | + | |
| User space side FILEIO | + | + | - | - | |
| SCSI pass-through | + | - | - | Single initiator only, not enforced 14 | |
| 4k sectors support in pass-through mode | + | - | - | ? | |
| 4k, 2k, 1k and 512 byte sectors emulation in modes, other than pass-through | + | - | - | + | |
| Virtual CD devices emulation from ISO files | + | + | - | - | |
| Possibility to write to emulated from ISO files CD devices | - | + | - | - | |
| Emulation of virtual tape and media changer devices | - | Experimental | - | - | |
| iSCSI Target | |||||
| Architecture | Split 2 | User space only | Split 2 | Kernel only | |
| Interface with user space | IOCTL/ProcFS/ Netlink | - | IOCTL/ProcFS/ Netlink | ConfigFS/IOCTL/ProcFS | |
| Multiple connections per session (MS/C) | - | - | - | + | |
| Max ErrorRecoveryLevel | 0 | 0 | 0 | 2 | |
| Bidirectional Commands | + 10 | + | - | - | |
| Extended CDB (size >16 bytes) | + 10 | + | - | - | |
| Support for Asynchronous Event Notifications (AEN) | + | - | - | - | Safe implementation of connections and sessions reinstatement 15 | Safe | Not safe | Not safe | Not safe |
| iSCSI MIBs | - | - | - | - 13 | |
REMARKS:
1. STGT has SCSI target engine and memory management in user space with small hooks in the kernel to interact with in-kernel target drivers. As a direct consequence, fully user space STGT target (e.g. iSCSI) can run without any kernel modules needed.
2. All iSCSI management implemented in user space and actual data transfers in kernel space without user space involved.
3. ISER target driver has long known (since Feb 2008) data corruption problem, which localization hasn't been determined yet and might be in the STGT core. See http://lists.berlios.de/pipermail/stgt-devel/2008-February/001367.html and http://lists.wpkg.org/pipermail/stgt/2009-February/002630.html
4. The result "in average" is listed. One target can be better somewhere, another one somewhere else. Although manual tuning of target and system parameters tends the restore the difference listed in the comparison. You can find example measurements here, here and here.
5. All SCST and its drivers' kernel patches supposed to be applied and SCST with the drivers built in the release or performance build. Without the kernel patches SCST performance will be at "****+" level, except for the case, when user space backstorage handler used with iSCSI-SCST iSCSI target driver, where performance will be at "***+" level.
6. There is no performance data for LIO, which allow to make a direct comparison of it with other targets. The conclusion was made by source code study only. LIO should have performance on the IET level or less, because of more processing overhead. It might be much less for small block sizes.
7. Some zero-copy functionality isn't available from user space, sometimes fundamentally. For instance, zero-copy FILEIO with page cache or zero-copy send to a socket. Also STGT can't use splice() for in-kernel target drivers, because it has memory management in user space. To use splice() with socket-based user space target drivers STGT would need a deep redesign of internal interactions between target drivers, core and backend handlers.
8. "Local access to emulated backstorage devices" means that you can access emulated by a SCSI target devices locally on the target host. For instance, you can mount your ISO image from emulated by the target CDROM device on the locally target host.
9. "Advanced devices access control" means that different initiators can see different sets of devices from the same target. This feature is essential for hardware targets, which don't have ability to create virtual targets.
10. Not well tested, because at the moment there is no backend using this functionality.
11. SCSI requires that if an initiator clears reservation held by another initiator, the reservation holder must be notified about the reservation clearance. Otherwise, several initiators can at the same time change supposed to be protected by the reservation data, which can corrupt them. This is what was called "Russian roulette with your data" by someone working for VMware on the VMware community forum.
12. After a task management command completed and before the corresponding response was sent to the initiator, who sent that task management command, all the affected SCSI commands must get into a state, where they can't affect following after the tasks management response commands from this initiator. This is the safe implementation. The unsafe implementation only marks all the affected SCSI commands as aborted and then immediately send task management response to the initiator. This implementation only guarantees that the initiator will never receive responses from those commands, but it doesn't guarantee that none of those commands will get executed by backstorage *AFTER* any SCSI command, which initiator will send after it received the task management response thinking that all the aborted commands actually fully aborted. This could lead to a data corruption.
13. The IETF SCSI-MIB (RFC 4455) is not supported by LIO, only proprietary MIBs SBE-SCSI-MIB, SBE-ISCSI-MIB and SBE-IPS-AUTH-MIB are supported.
14. LIO doesn't emulate all the necessary SCSI host functionality to allow to share a SCSI device in pass-through mode to several initiators. It can only pass SCSI commands from initiator to the SCSI device. This is safe only if there is only one initiator. This limitation isn't enforced anyhow by LIO. You can find more technical information about that in http://www.mail-archive.com/linux-scsi@vger.kernel.org/msg06911.html
15. Connections and sessions reinstatement is, basically, a kind of Task Management command, because it implies commands aborting. For instance, open-iscsi uses it as a less intrusive substistute for target reset in eh_target_reset_handler() callback. So, similarly to (7) above, a safe implementation must not accept SCSI commands from new connection/session until all the SCSI commands in being reinstated connection/session get into a state, where they can't affect the new commands.
P.S. You can find a brief background history of this comparison page here.