up | Inhaltsverzeichniss | Kommentar

Manual page for ST(4S)

st - driver for SCSI tape devices

CONFIG -- SUN-3, SUN-3/400, SUN-4, SPARCsystem 400 SERIES

controller si0 at vme24d16 ? csr 0x200000 priority 2 vector siintr 0x40
controller si1 at vme24d16 ? csr 0x204000 priority 2 vector siintr 0x41
controller si0 at obio ? csr 0x140000 priority 2
tape st0 at si0 drive 040 flags 1
tape st1 at si0 drive 050 flags 1
tape st2 at si0 drive 030 flags 1
tape st3 at si0 drive 020 flags 1
tape st4 at si1 drive 040 flags 1
tape st5 at si1 drive 050 flags 1
tape st6 at si1 drive 030 flags 1
tape st7 at si1 drive 020 flags 1

controller sc0 at vme24d16 ? csr 0x200000 priority 2 vector scintr 0x40
tape st0 at sc0 drive 040 flags 1
tape st1 at sc0 drive 050 flags 1

The first two controller lines above specify the first and second SCSI host adapters for Sun-3, Sun-3/400, Sun-4, and SPARCsystem 400 VME systems. The third controller line specifies the first and only SCSI host adapter on Sun-3/50 and Sun-3/60 systems.

Following the controller specification lines are eight lines which define the available tape devices, st0-st7. The first four tape devices, st0-st3 are on the first controller, si0. The next four tape devices, st4-st7 are on the second controller, si1. For small configurations, only the first controller, si0, is used. For larger configurations, a second controller, si1, is added.

The flags field is used to specify the SCSI device type to the host adapter. The flags field must be set to 1 to identify tape devices.

The drive value is calculated using the formula: SCSI bus, to select a specific target and logical unit number. The value to enter in the drive field of the configuration line is calculated using the formula:

8*target + lun

where target is the SCSI target, and lun is the SCSI logical unit number. Note the drive number is displayed in octal and not decimal as was done in earlier releases. For boot proms, this unit number must be specified in hex rather than decimal; for example, st4 is unit 20, not 32 (decimal) or 040 (octal).

The next configuration block, following si0 and si1 above, describes the older sc0 host adapter configuration. It follows the same configuration description as the si0 host adapter.

CONFIG -- SPARCsystem 300 SERIES

controller sm0 at obio ? csr 0x66000000 priority 2
controller si1 at vme24d16 ? csr 0x204000 priority 2 vector siintr 0x41
tape st0 at sm0 drive 040 flags 1
tape st1 at sm0 drive 050 flags 1
tape st2 at sm0 drive 030 flags 1
tape st3 at sm0 drive 020 flags 1
tape st4 at si1 drive 040 flags 1
tape st5 at si1 drive 050 flags 1
tape st6 at si1 drive 030 flags 1
tape st7 at si1 drive 020 flags 1

For small configurations, only the on-board controller, sm0, is used. For larger configurations, a second controller, si1, is added. This configuration follows the same rules described above in the first CONFIG section.

CONFIG -- Desktop SPARCsystems

scsibus0 at esp
scsibus1 at esp
tape st0 at scsibus0 target 4 lun 0
tape st1 at scsibus0 target 5 lun 0
tape st2 at scsibus1 target 4 lun 0
tape st3 at scsibus1 target 5 lun 0

The desktop SPARCsystems configuration files specify a device driver, esp, and the SCSI buses attached to that device driver. The first and second tape devices (st0 and st1) are attached on scsibus0, and the second and third tape devices (st2 and st3) are attached on scsibus1. These devices are attached at the Target and Logical Unit addresses specified.

CONFIG -- SPARCsystem 600MP SERIES

scsibus0 at esp
tape st0 at scsibus0 target 4 lun 0
tape st1 at scsibus0 target 5 lun 0
tape st2 at scsibus0 target 1 lun 0
tape st3 at scsibus0 target 0 lun 0

scsibus1 at esp
tape st4 at scsibus1 target 4 lun 0
tape st5 at scsibus1 target 5 lun 0

scsibus2 at esp

scsibus3 at esp
tape st6 at scsibus3 target 4 lun 0
tape st7 at scsibus3 target 5 lun 0

scsibus4 at esp

Like the desktop SPARCsystems, the SPARCsystem 600MP series configuration files specify a device driver, esp, and the SCSI buses attached to that device driver. The first through fourth tape devices (st0, st1, st2, and st3) are attached on scsibus0, the fifth and sixth tape devices (st4 and st5) are attached on scsibus1, and the seventh and eighth tape devices (st6 and st7) are attached on scsibus3. These devices are attached at the Target and Logical Unit addresses specified.

CONFIG -- SUN-3/80 SYSTEMS

controller sm0 at obio ? csr 0x66000000 priority 2
tape st0 at sm0 drive 040 flags 1
tape st1 at sm0 drive 050 flags 1
tape st3 at sm0 drive 030 flags 1
tape st4 at sm0 drive 020 flags 1

Sun-3/80 systems use an on-board SCSI host adapter, sm0, which follows the same rules described above in the first CONFIG section.

CONFIG -- SUN-4/110 SYSTEMS

controller sw0 at obio 2 csr 0xa000000 priority 2
tape st0 at sw0 drive 040 flags 1
tape st1 at sw0 drive 050 flags 1

The Sun-4/110 uses an on-board SCSI host adapter, sw0, which follows the rules described above in the first CONFIG section.

CONFIG -- SUN-3/E SYSTEMS

controller se0 at vme24d16 ? csr 0x300000 priority 2 vector se_intr 0x40
tape st0 at se0 drive 040 flags 1
tape st1 at se0 drive 050 flags 1

The Sun-3/E uses a VME-based SCSI host adapter, se0, which follows the rules described above for the first CONFIG section.

CONFIG -- Sun386i SYSTEMS

controller wds0 at obmem ? csr 0xFB000000 dmachan 7 irq 16 priority 2
tape st0 at wds0 drive 32 flags 1

The Sun386i configuration follows the rules described above in the first CONFIG section.

DESCRIPTION

The st device driver is an interface to various SCSI tape devices. Supported 1/4'' cartridge devices include the Archive Viper QIC-150 streaming tape drive, the Emulex MT-02 tape controller, and the Sysgen SC4000 tape controller (except on desktop SPARCsystems and SPARCsystem 600MP series machines). Supported 1/2'' and 8mm devices include the HP-88780 1/2'' tape drive and the Exabyte EXB-8200/8500 8mm cartridge tape subsystem. st provides a standard interface to these various devices; see mtio.4 for details.

The driver can be opened with either rewind on close (/dev/rst*) or no rewind on close (/dev/nrst*) options. A maximum of four tape formats per device are supported (see FILES below). The tape format is specified using the device name. The four rewind on close formats for st0, for example, are /dev/rst0, /dev/rst8, /dev/rst16, and /dev/rst24.

Read Operation

If the driver is opened for reading in a different format than the tape is written in, the driver overrides the user selected format. For example, if a 1/4'' cartridge tape is written in QIC-24 format and opened for reading in QIC-11, the driver will detect a read failure on the first read and automatically switch to QIC-24 to recover the data.

Note: if the /dev/*st[0-7] format is used, no indication is given that the driver has overridden the user selected format. Other formats issue a warning message to inform the user of an overridden format selection. Some devices automatically perform this function and do not require driver support (1/2'' reel and QIC-150 tape drives, for example).

Write Operation

Writing from the beginning of tape is performed in the user-specified format. The original tape format is used for appending onto previously written tapes. A warning message is issued if the driver has to override the user-specified format.

EOT Handling

The Emulex and Sysgen drives have only a physical end of tape (PEOT); thus it is not possible to write past EOT. All other drives have a logical end of tape (LEOT) before PEOT to guarantee flushing the data onto the tape. The amount of storage between LEOT and PEOT varies from less than a megabyte to about 20 megabytes depending on the tape drive. Further writing, except for trailer records, is inhibited to prevent running off the end of the reel.

If EOT is encountered while writing an Emulex or Sysgen tape, no error is reported but the number of bytes transferred is zero and no further writing is allowed. On all other drives, the current transfer is completed, returning the number of bytes written. The next write will return zero, at which time it is possible to write trailer records after first writing an EOF.

The Desktop SPARCsystems tape driver differs in EOT handling and supports writing trailer records without first writing an EOF. The first write that encounters EOT will return a short count or zero. If a short count is returned, then the next write will return zero. After a zero count is returned, the next write returns a full count or short count. A following write will return zero again.

It is important that the number and size of trailer records be kept as small as possible to prevent data loss. For this reason, this practice is not recommended.

Reading past logical EOT is transparent to the user. Reading is only stopped by reading EOF's. For 1/2'' reel devices, it is possible to read off the end of the reel if you read past the two file marks which mark the end of recorded media. All other devices have safeguards to eliminate this problem.

Ioctls

The behavior of SCSI tape positioning ioctls is the same across all devices which support them. However, not all devices support all ioctls. The driver returns an ENOTTY error on unsupported ioctls.

The retension ioctl only applies to 1/4'' cartridge tape devices. It is used to restore tape tension, thus improving the tape's soft error rate after extensive start-stop operations or long-term storage.

Note: the error status is reset by the MTIOCGET get status ioctl call or the next read, write, or other ioctl operation. If no error has occurred (sense key is zero), the current file and record position is returned.

ERRORS

EACCES
The driver is opened for write access and the tape is write protected. For writing with QIC-150 tape drives, this error is also reported if the wrong tape media is used for writing.
EBUSY
The tape driver is in use by another process. Only one process can use the tape drive at a time. The driver will allow a grace period of two minutes for the other process to finish before reporting this error.
EINVAL
The number of bytes read or written is not a multiple of the physical record size (fixed-length tape devices only).
EIO
During opening, the tape device is not ready because either no tape is in the drive, or the drive is not on-line. Once open, this error is returned if the requested I/O transfer could not be completed.
ENOTTY
This indicates that the tape device does not support the requested ioctl function.
ENXIO
During opening, the tape device does not exist.
EPERM
Another system has reserved the tape drive for its use. The tape drive cannot be used until the other system releases it.

FILES

For 1/2'' reel tape devices (HP-88780):

/dev/rst[0-7]
800 BPI density
/dev/rst[8-15]
1600 BPI density
/dev/rst[16-23]
6250 BPI density
/dev/rst[24-31]
data compression
/dev/nrst[0-7]
non-rewinding 800 BPI density
/dev/nrst[8-15]
non-rewinding 1600 BPI density
/dev/nrst[16-23]
non-rewinding 6250 density
/dev/nrst[24-31]
non-rewinding data compression

For helical-scan tape devices (Exabyte):

/dev/rst[0-7]
Standard EXB-8200 (2GB) Format
/dev/rst[8-15]
EXB-8500 (5GB) Format
/dev/rst[16-23]
Compressed Format (EXB-8500 only)
/dev/rst[24-31]
Compressed Format (EXB-8500 only)
/dev/nrst[0-7]
non-rewinding Standard EXB-8200 (2GB)Format
/dev/nrst[8-15]
non-rewinding EXB-8500 (5GB) Format
/dev/nrst[16-23]
non-rewinding Compressed Format (EXB-8500 only)
/dev/nrst[24-31]
non-rewinding Compressed Format (EXB-8500 only)

For QIC-150 tape devices (Archive Viper):

/dev/rst[0-7]
QIC-150 Format
/dev/rst[8-15]
QIC-150 Format
/dev/rst[16-23]
QIC-150 Format
/dev/rst[24-31]
QIC-150 Format
/dev/nrst[0-7]
non-rewinding QIC-150 Format
/dev/nrst[8-15]
non-rewinding QIC-150 Format
/dev/nrst[16-23]
non-rewinding QIC-150 Format
/dev/nrst[24-31]
non-rewinding QIC-150 Format

Note: The drive will automatically read both QIC-11 and QIC-24 formats too.

For QIC-24 tape devices (Emulex MT-02 and Sysgen SC4000):

/dev/rst[0-7]
QIC-11 Format
/dev/rst[8-15]
QIC-24 Format
/dev/rst[16-23]
QIC-24 Format
/dev/rst[24-31]
QIC-24 Format
/dev/nrst[0-7]
non-rewinding QIC-11 Format
/dev/nrst[8-15]
non-rewinding QIC-24 Format
/dev/nrst[16-23]
non-rewinding QIC-24 Format
/dev/nrst[24-31]
non-rewinding QIC-24 Format

Note: QIC-24 is the preferred format for all systems except Sun-2's. For Sun-2 systems, QIC-11 is preferred.

Note: Only four tape devices were supported in SunOS4.1. Thus only the first four device names above can be used if you are running this release. Releases following 4.1 PSR A (inclusive) support all device names.

SEE ALSO

cpio.1 mt.1 tar.1 mtio.4 dump.8 restore.8

DIAGNOSTICS

st?:  I/O request timeout
A tape I/O operation has taken too long to complete. A device or host adapter failure may have occurred.

st?:  warning, unknown tape drive found
The driver does not recognize the tape device. Only the default tape density is used; block size is set to the value specified by the tape drive.

st?:  write protected
The tape is write protected.


st?:  wrong tape media for writing, use DC6150 tape (or equivalent)
For QIC-150 tape drives, this indicates that the user is trying to write on a DC-300XL (or equivalent) tape. Only DC-6150 (or equivalent) tapes can be used for writing.
Note: DC-6150 was formerly known as DC-600XTD.

st?:  warning, rewinding tape
The driver is rewinding tape in order to set the tape format.

st?:  warning, using alternate tape format
The driver is overriding the user-selected tape format and using the previously used format.

st?:  warning, tape rewound
For Sysgen tape controllers, the tape may be rewound as a result of getting sense data.

st?:  format change failed
The specified tape density or format is not supported by the tape drive. This is detected by the tape drive rejecting the mode select command to change the tape density/format.

st?:  warning, The tape may be wearing out or the head may need cleaning.
The number of allowable records re-read or re-written (e.g. soft errors) has exceeded the specified limit for the tape media. This indicates the tape media is wearing out. No data loss has occurred on the tape yet. This message is an early warning that continued usage will result in unrecoverable errors. Continued usage of this tape is not recommended.

This error message can also be issued if the tape heads are dirty. Tape oxide buildup on the head interferes with reading and writing data. If the head has not been cleaned recently, it should be cleaned and the tape retested to determine the source of this error.

If this error message is persistent over different known good tapes, this is indicative of a tape drive hardware problem.

st?:  read retries= count (rate %), file= %d, block= %d
st?:  write  retries= count (rate %), file= %d, block= %d
These messages display the measured soft error rate of the tape at the time the driver is closed. The count indicates the number of soft errors. The number of soft errors as a percentage of total blocks transferred is rate. The rate should remain relatively constant across the tape. Sudden jumps indicate worn spots on the tape. The retry count is reset every time the tape is rewound.

Ballpark upper limits for read retries is 3%. For write retries, the upper limit is 10%. The exact specifications depend on the tape device in use.

st?:  <cmd> failed
st? error:  sense key(0x%x): %s error, code(0x%x): %s
An error has occurred. The first line identifies the command name, <cmd>. The second line reports the sense key error code and message string. In addition, the error code and message string may be reported depending on whether this extension is supported by the tape drive. This information is intended for diagnostic purposes.

st?:  stread: not modulo %d block size
st?:  stwrite: not modulo %d block size
The read or write request size must be a multiple of the %d physical block size. Typically, this means a read or write of less than 512 bytes was requested. Note: the block size can vary with the tape drive in use.

st?:  file positioning error
st?:  block positioning error
The driver was unable to position the tape to the desired file or block (record). This is probably caused by a damaged tape.

st?:  tape synchronization lost
The user hit CTRL-C while a tape operation was in progress, causing the tape position to be lost. The tape will be rewound on the next open to resynchronize. Note: other signals may also have a similar effect.

st?:  no iopb space for buffer
The driver could not allocate space for its internal working buffer because the kernel is out of resources; too many devices were configured into the system.

Additional SPARCsystem Diagnostics

The diagnostics for desktop SPARCsystems and the < SPARCsystem 600 series are much like those described above. The following diagnostics are unique to these systems:

st?:  SCSI transport failed: reason 'xxxx': {retrying|giving up}
The host adapter has failed to transport a command to the target for the reason stated. The driver will either retry the command or, ultimately, give up.

BUGS

Foreign tape devices which do not return a BUSY status during tape loading prevent user commands from being held until the device is ready. The user must delay issuing any tape operations until the tape device is ready. This is not a problem for Sun-supplied tape devices.

Foreign tape devices which do not report a blank check error at the end of recorded media cause file positioning operations to fail. Some tape drives, for example, mistakenly report media error instead of blank check error.

Systems using the older sc0 host adapter or the Sysgen SC4000 tape controller prevent disk I/O over the SCSI bus while the tape is in use (during a rewind, for example). This problem is caused by the fact that they do not support disconnect/reconnect to free the SCSI bus. Newer tape devices, like the Emulex MT-02, and host adapters, like si0, eliminate this problem.

Some older Sysgen drives support only the QIC-11 format. This can be determined using mt.1

WARNINGS

The Sysgen SC4000 tape controller is being obsoleted.


index | Inhaltsverzeichniss | Kommentar

Created by unroff & hp-tools. © somebody (See intro for details). All Rights Reserved. Last modified 11/5/97