/etc/istgt/istgtcontrol.conf
Configuration file
Istgt iscsi target command utility
istgtcontrol [options]
<command>
[<file>]
istgtcontrol is a command and control utility for istgt(1). It can be used to query and change the status of a local or remote istgt instance.
istgtcontrol supports the commands denoted below to interact with the istgt instance. By default it connects and authenticates to the iSCSI target portal specified in the istgtcontrol.conf configuration file and uses CHAP credentials denoted there, if any. Both can be overridden by using the respecitve command line arguments.
istgtcontrol understands the following commands which can be forwarded to istgt:
noopDo not actually do anything, but test responsiveness of the portal and test CHAP credentials only.
versionRetrieve the istgt version number providing the iSCSI portal istgtcontrol connected to.
listList all, or the specified targets only, which shared by the portal.
loadLoad a new media to the specified unit. This command issues the same command as if a drive tray had been closed on a SCSI device.
unloadUnload a media from the specified unit. This command issues the same command as if the drive tray had been opened from a SCSI device.
change fileChange the loaded media by the specified unit. This command is equivalent as if a new media (for example a DVD-ROM or tape cartridge) had been inserted in the SCSI drive. The "file" argument is interpreted as filename to be loaded.
resetReset the specified LUN of the portal.
infoDisplay all connections of the portal
-c configUse specified file as configuration file instead of the default file.
-h hostOverride the target portal by the specified host name or IP address. This defaults to "localhost" if no other host was specified in the configuration file.
-p portOverride the target portal port by the specified port number. This defaults to "3261" if no other port was specified in the configuration file.
-t targetSpecifies the target IQN which should be affected by the command given. There may be a default given in the configuration file. The keyword "all" is accepted by some commands and matches all exported volumes.
-l lunSpecifies the target LUN which should be affected by the command given. This defaults to "0" unless another default was provided in the configuration file.
-f flagsSpecifies flags passed to the portal when loading a new media. This defaults to "ro". Supported flags are: "ro", "rw", "extend" and "dynamic".
-s sizeSpecifies the size of the meda to be loaded. The default is to auto-detect the media size.
-q
Quiet mode, supress non-critical outputs.
-v
Verbose mode, gives more output during operations.
-A methodSets the preferred authentication method for logging in to the portal. This overrides any method specified in the configuration file. Supported methods are either CHAP/Mutual or CHAP/Auto.
-U userSets the user to authenticate on the portal. This overrides any username specified in the configuration file.
-S secretSet the secret used to authenticate on the portal. This overrides any secret specified in the configuration file.
-M muserSet the mutual authentication user. This overrides any user specified in the configuration file.
-R msecretSet the mutual authentication secret. This overrides any secret specified in the configuration file.
-H
Display a brief usage summary and exit.
-V
Display the istgtcontrol version number and exit.
/etc/istgt/istgtcontrol.conf
Configuration file
Unchanged in 7 releases since Debian 7 (Wheezy).