LSTAPE(8)
π lstape(8) β list tape devices, bestie π
okay so the manual name is literally lstape(8) and we're folding it in right here at the top instead of copying the boring header line. Periodt. β¨
π NAME π
lstape β list tape devices. π
β¨ SYNOPSIS β¨
lstape [-h|--help] [--scsi-only|--ccw-only] [-v|--version]
[-V|--verbose]
[--online|--offline] [-s]
[-t <device-type>[,<device-type>]...]
[<device-bus-ID>...]
π¦ DESCRIPTION π¦
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. π
β οΈ heads up, bestie: thelstapecommand without the--ccw-onlyoption causes extra SAN traffic for each SCSI tape or changer device by invoking thesg_inqcommand. That's a real vibe check for your SAN, so know before you run it. π
π OPTIONS π
-hor--helpβ Print help text. π«Ά-vor--versionβ Print the version of thes390-toolspackage and the command. β¨-Vor--verboseβ Adds additional information that does not fit into a single line of output. This is currently only used for SCSI devices. π--scsi-only|--ccw-onlyβ 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. π«-s|--shortidβ 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. πΈ--online|--offlineβ Limit output to either online or offline devices. This filter has no effect on the output of SCSI devices. π¦-t <device-type>[,<device-type>]...β this one shows up in the synopsis, bestie. The original page doesn't give it its own description in the OPTIONS section, so I'm not gonna invent one β it stays here so nothing goes missing. π«Ά<device-bus-ID>β Limits the output to information about the specified tape device or devices only. For CCW-attached devices only. π
π OUTPUT FIELDS FOR SCSI TAPE/CHANGER DEVICES π
- Generic β SCSI generic device file for the tape drive, for example
/dev/sg0."N/A"if the SCSI generic (sg) kernel functionality is not available. π - Device β Main character device node file for accessing the tape drive or medium changer. SCSI tape devices 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. The
lstapecommand tries to determine the device driver. 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 device driver could not be determined. π - Target β Linux SCSI device name in
H:C:T:Lformat. β¨ - Vendor β The vendor field from the SCSI device. πΈ
- Model β The model field from the SCSI device. π¦
- Type β
"tapedrv"for a tape drive or"changer"for a medium changer. π - State β The state of the SCSI device object in the kernel. Any state other than
"running"can indicate problems. β οΈ
For SCSI devices, the --verbose option additionally displays:
- HBA β The device bus-ID of the FCP device or of the
virtio-scsi-ccwvirtual HBA through which the tape drive is attached."N/A"if the device does not have a sysfs ancestor with subsystem ccw. π«Ά - WWPN β The WWPN (worldwide port name) of the tape drive in the SAN.
"N/A"if device is not attached through zfcp. π - Serial β The serial number.
"NO/INQ"if there is nosg_inqcommand available."NO/SG"if no SCSI generic (sg) kernel support is available. π
π₯ EXAMPLES π₯
lstape
List all tape devices that are available. π
lstape --ccw-only --online
Show all channel-attached tape devices that are online. β¨
lstape --scsi-only --verbose
Show all SCSI tape or changer devices with maximum information. π
this iconic little page is brought to you by s390-tools, Jun 2018 edition β mwah, bye bestie! ππ«Ά
π¦ where this page comes from
- opensuse-leap 16.0: s390-tools 2.44.1-160000.1.1 Β· MIT
- Copyright 2017, 2018 IBM Corp
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms