Skip to content

iscsi-scstd: Add login suspension via SIGUSR1/SIGUSR2#354

Open
bmeagherix wants to merge 1 commit intoSCST-project:masterfrom
bmeagherix:iscsi_svc_unavailable
Open

iscsi-scstd: Add login suspension via SIGUSR1/SIGUSR2#354
bmeagherix wants to merge 1 commit intoSCST-project:masterfrom
bmeagherix:iscsi_svc_unavailable

Conversation

@bmeagherix
Copy link
Contributor

During daemon startup or configuration reload, targets may be partially configured - present in the daemon but without their ACL entries yet written. Initiators that attempt to connect in this window receive ISCSI_STATUS_TGT_NOT_FOUND (class 0x02, Initiator Error), which most initiators treat as a permanent failure and do not retry.

This patch adds a logins_suspended flag that an external process can set and clear by sending SIGUSR1 and SIGUSR2 respectively. While logins are suspended, any login attempt - normal or discovery - is rejected early with ISCSI_STATUS_SVC_UNAVAILABLE (class 0x03, Target Error), which the RFC defines as transient and initiators are expected to retry.

The intended usage is to send SIGUSR1 before beginning a susceptible configuration apply and SIGUSR2 once it is complete, ensuring initiators that arrive during the window will reconnect successfully rather than giving up.

SIGUSR1 and SIGUSR2 were previously unhandled by iscsi-scstd.

(No behavior change unless SIGUSR1 is sent).

SIGUSR1/SIGUSR2 set/clear logins_suspended. While set, any login
attempt is rejected with a retriable Target Error instead of the
permanent Initiator Error (TGT_NOT_FOUND) that causes initiators
to give up.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant