ISCSICTL(8)
β¨ ISCSICTL(8) β¨
okay bestie so this is the iscsictl manual page β a System Manager's Manual situation, iSCSI initiator edition π
buckle up, it's actually not that deep and also extremely deep at the same time.
π NAME π
iscsictl β the iSCSI initiator management utility. that's it, that's the vibe.
πΈ SYNOPSIS πΈ
iscsictl -A -p portal -t target [-u user -s secret] [-w timeout] [-r]
[-e on|off]
iscsictl -A -d discovery-host [-u user -s secret] [-r] [-e on|off]
iscsictl -A -a [-c path]
iscsictl -A -n nickname [-c path]
iscsictl -M -i session-id [-p portal] [-t target] [-u user] [-s secret]
[-e on|off]
iscsictl -M -i session-id [-n nickname [-c path]]
iscsictl -R [-p portal] [-t target]
iscsictl -R -a
iscsictl -R -n nickname [-c path]
iscsictl -L [-v] [-w timeout]
like, ten whole shapes of the same command. iconic honestly π«Ά
π¦ DESCRIPTION π¦
The iscsictl utility configures the iSCSI initiator. yes that's the whole point. main character energy only.
here's every option, no cap, nothing skipped:
--libxoβ generate output vialibxo(3)in a whole selection of different human and machine readable formats π seexo_options(7)for the deets on the command line arguments.-Aβ Add session. adding era.-Mβ Modify session. glow-up era.-Rβ Remove session. blocking, unfollowing, etc.-Lβ List sessions. the vibes check π-aβ When adding, add all sessions defined in the configuration file. When removing, remove all currently established sessions. all of them. periodt.-cpathβ path to the configuration file. the default is/etc/iscsi.conf.-ddiscovery-hostβ target host name or address used for SendTargets discovery. when you use it, it adds a temporary discovery session, does the discovery, then adds sessions for each discovered target, and removes the temporary discovery session. poof β¨ gone.-eon|offβ enable or disable the session. lowkey ignored for discovery sessions, but highkey gets passed down to the normal sessions they add.-isession-idβ session ID, as displayed byiscsictl -v.-nnicknameβ the nickname of a session defined in the configuration file π-pportalβ target portal β host name or address β for statically defined targets.-rβ use iSER (iSCSI over RDMA) instead of plain iSCSI over TCP/IP. switching it up fr fr.-ssecretβ CHAP secret. shhh π-ttargetβ target name.-uuserβ CHAP login.-vβ verbose mode. say more, queen.-wtimeoutβ instead of returning immediately, wait up totimeoutseconds until all configured sessions are successfully established. patience is a virtue bestie.
Certain parameters are necessary when adding a session. you can specify these either via command line (using the -t, -p, -u, and -s options), or configuration file (using the -a or -n options). some functionality β for example mutual CHAP β is only available via configuration file. sorry, them's the rules π
Since connecting to the target is performed in background, a non-zero exit status does not mean the session was successfully established. π like, it does not mean that. use either iscsictl -L to check the connection status, or the -w flag to wait for session establishment.
π¨ also: for the iSCSI initiator to actually be able to connect to a target, the iscsid(8) daemon must be running. no daemon, no session. that's the whole thing.
π FILES π
/etc/iscsi.confβ iSCSI initiator configuration file. the blueprint β¨
π₯ EXIT STATUS π₯
The iscsictl utility exits 0 on success, and >0 if an error occurs. simple as that π«Ά
π EXAMPLES π
attach to a target
Attach to target iqn.2012-06.com.example:target0, served by 192.168.1.1:
iscsictl -A -t iqn.2012-06.com.example:target0 -p 192.168.1.1
discovery, but make it disabled
Perform discovery on 192.168.1.1, and add disabled sessions for each discovered target; use -M -e on to connect them:
iscsictl -A -d 192.168.1.1 -e off
the great disconnect
Disconnect all iSCSI sessions:
iscsictl -Ra
π SEE ALSO π
libxo(3), xo_options(7), iscsi(4), iscsi.conf(5), iscsid(8) β go read them, they're the supporting cast and they ate π
β HISTORY β
The iscsictl command appeared in FreeBSD 10.0. a legend since day one.
π§ AUTHORS π§
The iscsictl utility was developed by Edward Tomasz Napierala <trasz@FreeBSD.org> under sponsorship from the FreeBSD Foundation. we love a sponsored icon π
so that's the page!! Debian build, dated July 16, 2025 β mwah π go forth and configure your initiator, bestie. slay π¦β¨
π¦ where this page comes from
- freebsd 15.1: base 15.1
- Copyright (c) 2012 The FreeBSD Foundation
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms