Skip to content

Add optional iSCSI target/export support for Mayastor volumes #2021

Description

@Masorubka1

Is your feature request related to a problem? Please describe

Mayastor appears to be focused primarily on NVMe-oF-style volume access. This is a strong fit for modern Kubernetes storage, but it makes interoperability testing harder for clients, tools, and environments that still depend on iSCSI.

iSCSI support would help users who need compatibility with existing initiators, legacy systems, hypervisors, lab environments, or storage tooling where NVMe-oF is not available or not yet integrated.

Describe the solution you'd like

Add an optional iSCSI export mode for Mayastor volumes.

At minimum, it would be useful to support:

  • exposing a Mayastor volume as an iSCSI target
  • stable target IQN generation or configurable IQNs
  • mapping one Mayastor volume as one LUN
  • basic discovery through SendTargets
  • standard SCSI read/write commands over iSCSI
  • optional CHAP authentication
  • Kubernetes/CRD-level configuration for enabling iSCSI export per volume

This would not need to replace the existing NVMe-oF path. It could be an optional compatibility/export layer for users who explicitly need iSCSI.

Describe alternatives you've considered

The current workaround is to place another Linux iSCSI target implementation in front of a block device, for example LIO/targetcli or tgt. This works for simple testing, but it adds another moving part and does not test Mayastor-native export behavior directly.

Keeping NVMe-oF as the only supported access protocol is also possible, but it does not help environments or tools that require iSCSI compatibility.

Additional context

My use case is interoperability testing for an open-source pure-Rust iSCSI initiator/client library:

https://github.com/Masorubka1/iscsi-client-rs

The library already implements login negotiation, CHAP authentication, PDU parsing/framing, SCSI READ/WRITE, READ CAPACITY, R2T/Data-Out flow, NOP, logout, sense parsing, and integration tests against Linux tgt/LIO-style targets.

A limited initial implementation would already be useful, for example:

  • single-session support
  • ERL0 only
  • no advanced multipath support initially
  • optional basic CHAP
  • one exported LUN per Mayastor volume

If Mayastor had optional iSCSI export support, I would be interested in testing compatibility against it and reporting issues from the initiator/client side.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions