9.3. Tape driver (st)

The tape driver interface is documented in the file /usr/src/linux/drivers/scsi/README.st and on the st(4) man page (type man st). The file README.st also documents the different parameters and options of the driver together with the basic mechanisms used in the driver.

The tape driver is usually accessed via the mt command (see man mt). mtx is an associated program for controlling tape autoloaders (see mtx.sourceforge.net).

The st driver detects those SCSI devices whose peripheral device type is "Sequential-access" (code number 1) unless they appear on the driver's "reject_list". [Currently the OnStream tape drives (described in a following section) are the only entry in this reject_list.]

The st driver is capable of recognizing 32 tape drives. There are 8 device file names for each tape drive: a rewind and non-rewind variant for each of 4 modes (numbered 0 to 3). See the tape device file name examples in Section 3.2 on device names. Any number of tape drives (up to the overall limit of 32) can be added after the st driver is loaded.

ATAPI tape drives can be controlled by this driver with help from the ide-scsi pseudo adapter driver. The discussion in Section 9.2.4 also applies for ATAPI tape drives (and ATAPI floppies).

9.3.1. st boot parameters


st=xxx[,yyy] where xxx is one of the following:
buffer_kbs:<n>
write_threshold_kbs:<n>
max_buffers:<n>
max_sg_segs:<n>

(The old boot parameters st=aa[,bb[,cc[,dd]]] supported but deprecated)

The default driver buffer size (buffer_kbs) is 32 (i.e. 32 KB). The default asynchronous write threshold (write_threshold_kbs) is 30 (i.e. 30 KB). The default number of buffers allocated at initialization (max_buffers) is 4. The default number of scatter/gather segments to use (max_sg_segs) is 32.

9.3.2. st module parameters


buffer_kbs=<n>
write_threshold_kbs=<n>
max_buffers=<n>
max_sg_segs=<n>

9.3.3. st proc interface

None.

9.3.4. osst driver for OnStream devices

There is an auxiliary tape driver for tape drives manufactured by OnStream. It is an additional upper level driver and can co-exist with the st driver. Its driver name is "osst" (as is its module name).

The OnStream SC-x0 SCSI tape drives can not be driven by the standard st driver, but instead need this special osst driver and use the /dev/osst<x> char device nodes (major 206). [Where <x> follows the same naming scheme as st devices outlined in Section 3.2.] Via usb-storage and ide-scsi, you may be able to drive the USB-x0 and DI-x0 drives as well. Note that there is also a second generation of OnStream tape drives (ADR-x0) that supports the standard SCSI-2 commands for tapes (QIC-157) and can be driven by the standard driver st. For more information, you may have a look at the kernel source file /usr/src/linux/drivers/scsi/README.osst. More info on the OnStream driver may be found on linux1.onstream.nl/test/.

mirror server hosted at Truenetwork, Russian Federation.