DOKK / manpages / debian 10 / s390-tools / lstape.8.en
LSTAPE(8) System Manager's Manual LSTAPE(8)

lstape - list tape devices.

[-h|--help] [--scsi-only|--ccw-only] [-v|--version] [-V|--verbose]
[--online|--offline] [-s]
[-t <device-type>[,<device-type>]...]

The lstape command lists all available tape devices on the current host. For channel attached tape devices this output is the same as the contents of /proc/tapedevices (which is obsolete) but also includes offline devices. By default all tape devices are displayed.

Since SCSI tape devices are accessed differently to channel attached tape devices they are only visible if they are known to the SCSI layer. There are at least two possible drivers that can claim a SCSI tape device and the lstape command tries to find out which one this is. For the generic tape and changer driver the device names start with "st" or "sch", while for the IBM tape driver this would be "IBMtape" or "IBMchanger". If "N/A" is shown, the correct driver could not be obtained. This happens for example if there is no sg_inq command installed which is required to read the drive's serial number which in turn is used to find out the device number of the IBM tape driver.

The serial number of a SCSI tape can be displayed with the --verbose option. If there is no sg_inq command available "NO/INQ" is shown as the tape's serial.

Print help text.

Print the version of the s390-tools package and the command.

Adds additional information that does not fit into a single line of output. This is currently only used for SCSI devices.

Limit output to either SCSI or channel attached tape devices. The output without SCSI devices is the same as it was with previous versions of this command.

Using this option will list only tape devices that are in channel subsystem 0, with subchannel set 0. All other devices will be suppressed and the leading "0.0." for bus IDs of the remaining devices will be removed. Since this is specific to CCW devices this option has no effect on the output of SCSI tape devices.

Limit output to either online or offline devices. This filter has no effect on the output of SCSI devices.

Limit output to given device types (currently only applies to channel attached tape devices).

<device-type> =
Device type of devices that should be displayed (e.g. 3490).

lstape

List all tape devices that are available

lstape --ccw-only -t 3490 --online

Show all 3490 CCW devices that are online.
Jul 2007 s390-tools