TAPE(C) UNIX System V Name tape, mcart - magnetic tape maintenance program Syntax tape [ -csf8i ] [ -a arg ] command [ device ] mcart command [ device ] Description tape sends commands to and receives status from the tape subsystem. tape can communicate with QIC-02 cartridge tape drives, SCSI tape drives, and QIC-40, QIC-80 and Irwin mini-cartridge tape drives. (The mcart program is automatically invoked by tape when options specific to the Irwin driver are used.) tape reads /etc/default/tape to find the default device name for sending commands and receiving status. For example, the following line in /etc/default/tape will cause tape to communicate with the QIC-02 cartridge tape device: device = /dev/xct0 If a device name is specified on the command line, it overrides the default device. tape queries the device to determine its device type. If the device does not respond to the query, tape will print a warning message and assume the device is a QIC-02 cartridge tape. The Irwin driver has a special default file /etc/default/mcconfig that contains special driver options (see mcconfig(F) for details). In addition, the Irwin driver uses a daemon startup program, /etc/mcdaemon, to provide background ECC encode/decode. All driver messages are documented in the messages(M) manual page. Options You can explicitly specify the type of the device by using the device type flags, as follows: -c QIC-02 cartridge tape -s SCSI tape -f QIC-40 mini-cartridge tape -8 QIC-80 mini-cartridge tape -i Irwin mini-cartridge tape The -a flag allows you to pass an argument to commands that can use them. The format and setblk commands are the only command that currently can take an argument. A format argument is only valid with QIC-40 and QIC-80 tape drives, and a setblk argument is only valid with SCSI drives. The following commands can be used with the various tape drivers supported under UNIX. The letters following each description indicate which drivers support each command: A All drivers C QIC-02 cartridge tape driver S SCSI tape driver F QIC-40 and QIC-80 mini-cartridge tape drivers I Irwin mini-cartridge tape driver amount Report amount of data in current or last transfer. (C,S,F) erase Erase and retension the tape cartridge. (C,S,F) load Loads the tape cartridge. (S) reset Reset tape controller and tape drive. Clears error conditions and returns tape subsystem to power-up state. (C,S,F) reten Retension tape cartridge. Should be used periodically to remedy slack tape problems. Tape slack can cause an unusually large number of tape errors. (A) rewind Rewind to beginning of tape. (A) status The status output looks like this: status: status message soft errors: n underruns: m status message is a report of the current status of the drive; ``no cartridge,'' ``write protected,'' or ``beginning of tape'' are typical status messages. soft errors is the number of recoverable errors that occurred during the last tape operation. A recoverable error is one which is correctable by the drive or controller. An example of a non-recoverable ``hard'' error is an attempt to write to a write-protected cartridge. Note that if the number of soft errors greatly exceeds the manufacturer's specifications, the drive may require service or replacement. underruns is the number of times the tape drive had to stop and restart due to tape buffer underflows. Underruns are not an error indication, but that the data transfer did not occur at the drive's maximum data transfer rate. The number of underruns can be affected by system load. (C,S,F) unload Unloads the tape cartridge. (S) format Format the tape cartridge. Floppy controller-based tapes must be formatted before they can be used. This command takes approximately one minute per megabyte of tape capacity. If an argument is provided with the -a flag, the number of tracks specified by the argument will be formatted. Only even numbers less than or equal to the number of tracks on the tape are allowed. (See tape(HW) for more information.) If no argument is given, the entire tape will be formatted. (F,I) getbb Prints a list of bad tape blocks detected during the last tape operation. This listing can be saved in a file for use by the putbb command. (F) map Prints out a map of the bad blocks on the tape. The format is a series of lines of the format: track n: -------------X------... Each '-' represents a good block on the track; an 'X' represents a block marked as bad. (F) putbb Reads a list of bad tape blocks from the standard input and adds them to the bad block table on the tape. The format expected by putbb is the same as generated by the getbb command. (F) rfm Wind tape forward to the next file mark. (C,S) wfm Write a file mark at the current tape position. (C,S) setblk Set the tape block size to a specified byte size (S). For example, the following command sets the tape block size to 512 Bytes: tape -a 512 setblk Irwin-specific Commands The following commands are all specific to Irwin drives. drive displays information about the Irwin driver and the tape drive. An example display is: Special file: /dev/rctmini Driver version: 1.0.6a Drive type: 285XL Drive firmware: A0 Controller type: SYSFDC Unit select (0-3): 3 Special file is the name of the special file used to access the driver. Driver version is the version of the driver linked with the kernel. Drive type is an ``equivalent'' tape drive model number as determined by the MC driver. Since the exact model number of the tape drive depends on the drive's form factor and whether the drive is mounted in its own cabinet, the equivalent model number may not be the exact model of the installed tape drive. The following is a list of equivalent drives: 110: 110, 310, 410 120[XL]: 120, 220, 320, 420, 720, 2020 125: 125, 225, 325, 425, 725 145[XL]: 145, 245, 345, 445, 745, 2040 165: 165, 265, 465, 765 285XL: 285, 485, 785, 2080 287XL: 287, 487, 787, 2120 The brackets in the 120[XL] and 145[XL] mean the letters ``XL'' may or may not be present. When the letters ``XL'' appear, the drive is capable of servo writing extra long (i.e., 307.5 foot DC2120) tapes. Note: When this field displays ``125/145,'' either a 125 drive or an early model 145 drive with a DC1000 is present, the driver can't distinguish between the two. A 125 drive will only accept a DC1000 cartridge (a DC2000 or DC2120 will not fit). A 145 drive will accommodate DC1000, DC2000, or DC2120 cartridges. Drive firmware is the firmware part number and revision level. This line is present only for drives which report this information. Controller type: is a mnemonic for the floppy controller to which the tape drive is attached: Mnemonic Description _________________________________________________ SYSFDC System floppy controller ALTFDC Alternate floppy controller 4100MC Irwin 4100MC Micro Channel controller 4100MCB Second 4100MC Micro Channel controller 4100 Irwin 4100 PC Bus controller 4100B Second 4100 PC Bus controller Unit select (0-3) gives the controller's unit select, in the range 0 through 3. The unit select selects the drive. info displays Irwin cartridge information. For example: Cartridge state: Formatted Cartridge format: 145 Write protect slider position: RECORD Cartridge state is the current state of the cartridge's format. Cartridge format indicates the format on the cartridge's tape. The format is given in a code which is the same as the drive model on which the cartridge was originally formatted (see drive and tape(HW) for details). When the cartridge is blank, the code has the format which would be applied by the format command. Write protect slider position is RECORD or PROTECT. capacity cartridge capacity in 512-byte blocks. kapacity cartridge capacity in 1024-byte blocks. These two commands give the total usable data storage capacity of a formatted tape cartridge. Variations in cartridge capacity are due to differing numbers of bad blocks. Files Devices: /dev/rStp0 /dev/rct0 /dev/erct0 /dev/rmc1 /dev/nrStp0 /dev/nrct0 /dev/xct0 /dev/mcdaemon /dev/xStp0 /dev/rct2 /dev/rctmini /dev/rft0 /dev/nrct2 /dev/xctmini /dev/xft0 /dev/xct0 /dev/rmc0 /etc/default/tape /etc/default/mcconfig /etc/mcdaemon Include files: /usr/include/sys/tape.h /usr/include/sys/ct.h /usr/include/sys/ft.h /usr/include/sys/ir.h See Also backup(ADM), cpio(C), dd(C), restore(ADM), tape(HW), tar(C), xbackup(ADM), xrestore(ADM) mcconfig(F) messages(M) Notes See tape(HW) for a list of supported tape drives. The amount and reset commands can be used while the tape is busy with other operations. All other commands wait until the currently executing command has been completed before proceeding. When you are using the non-rewinding tape device or the tape commands rfm and wfm, the tape drive light remains on after the command has been completed, indicating that more operations may be performed on the tape. The tape rewind command may be used to clear this condition. For more information on devicefiles, (listed above), see the tape(HW) manual page. TAPE(HW) UNIX System V Name tape - magnetic tape device Description The tape device implements the UNIX interface with a tape drive. QIC-02 cartridge tape drives are supported by the ct device driver, QIC-40 and QIC-80 tape drives connected to the floppy disk controller are supported with the ft device driver, and Irwin tape drives connected to the floppy disk controller are supported with the mc device driver. Typically, the tar(C), cpio(C), dd(C), backup(ADM), xbackup(ADM), xrestore(ADM), or restore(ADM) commands are used to access a tape drive. A single tape drive with a raw (character, non-blocking) interface is supported, except for the SCSI tape driver which supports up to four devices. There are four standard tape device types. Devices beginning with the ``r'' prefix, (for ``raw device''), should be used for most normal tape work, while devices with the ``n'' prefix, (``for no rewind on hold''), should be used for storing and restoring multiple files. Devices beginning with the ``x'' prefix are control devices, which are used for sending ioctl(S) commands to the tape subsystem. Devices beginning with the ``e'' prefix (for ECC device) support a 2/64 error recovery scheme. Thus two 512-byte blocks out of every 64 blocks can be bad and the driver will correct the errors. This software ECC support provides a high degree of error recovery. ECC encoding and decoding for the ft and mc floppy tape drivers is automatically used with the standard ``r'' device; the ft and mc drivers do not support the ``n'' or ``e'' device types. On the QIC-40, QIC-80 and Irwin 80MB drives, for every 29K written to the tape, 3K of ECC data is written with it to provide error recovery. On the Irwin 10, 20, 40 and 60MB drives, for every 16K written to the tape, 2K of ECC data is written. QIC-40 and QIC-80 tapes must be formatted with the tape(C) command before use, unless you use QIC-40 or QIC-80 pre- formatted tapes, respectively. Similarly, Irwin tapes must be first servo-written and then formatted with tape(C) before use, unless you use Irwin pre-formatted tapes. The mc driver can read tapes formatted and written under XENIX but cannot write to them. The following table summarizes the base naming conventions for the tape drives supported: ct0,1 QIC24 unit 0,1 ct2,3 QIC11 unit 0,1 Stp0,1,2,3 SCSI tape unit 0,1,2,3 ft0 QIC-40 or QIC-80 floppy tape unit mc0 Irwin floppy tape unit ctmini default mini-cartridge device mt0,1 reel to reel unit 0,1 1600 bpi mt2,3 reel to reel unit 0,1 800 bpi mt4,5 reel to reel unit 0,1 6250 bpi The default tape device is stored in the file /etc/default/tape, which is also used by tape(C). /etc/default/tape should always contain the ``x'' (control) device name of the default device, and is normally updated by mkdev(ADM) tape. If the default device is an QIC-40, QIC-80 or Irwin tape drive, the appropriate device from the table above will be linked to the ctmini device node. QIC- 02 tape drives will always be accessed by the ct0,1 device nodes as shown in the table. If a SCSI tape drive is installed as the default device and there is no QIC-02 drive installed, it will be linked to the ct0 device node. If both SCSI and QIC-02 drives are installed, the SCSI device node cannot be linked to the ct0 device node. tape(C) describes the commands used to access tape drives. Definition of ioctl commands The following ioctl commands can be used with the various tape device drivers supported under UNIX. The letters following each description indicate which drivers support each ioctl command: A All drivers C QIC-02 cartridge tape driver S SCSI tape driver F QIC-40 and QIC-80 mini-cartridge tape drivers I Irwin mini-cartridge tape driver MT_STATUS Returns a device-independent structure holding the status of the drive. The tape_info structure is defined in /usr/include/sys/tape.h. (C,S,F) MT_DSTATUS Returns a device-dependent structure holding status information of the drive. (C,S,F) MT_RESET Resets the driver software and the tape drive. Interrupts tape commands in progress. (C,S,F) MT_REPORT Returns an integer code which determines the type of device which the driver controls. The type numbers are defined in /usr/include/sys/tape.h. (C,S,F) MT_RETEN Winds the tape forward to EOT and then backward to BOT. (C,S,F) MT_REWIND Rewinds the tape to BOT. (C,S,F) MT_ERASE Erases the data on the tape and retensions the cartridge. (C,S,F) MT_AMOUNT Returns an integer count of the amount of the last data transfer. (C,S,F) MT_FORMAT Formats the tape. Expects as an argument the number of tracks to format, which must be an even number. If no argument is provided, the default is 20 tracks for QIC-40 drives, and 28 tracks for QIC-80 drives. (F) MT_GETHDR Expects as an argument a pointer to a struct ft_header or struct ir_header and copies the header of the current tape into it. (F) MT_PUTHDR Takes a pointer to a struct ft_header or struct ir_header and writes it onto the tape. This command should be used with caution. (F) MT_GETNEWBB Takes a pointer to a struct ft_newbbt or struct ir_newbbt and copies in a list of bad blocks detected on the last write operation. (F) MT_PUTNEWBB Takes a pointer to a struct ft_newbbt or struct ir_newbbt, reads in the header from the tape, then writes a new bad block onto the tape with the new bad blocks from the provided bad block table. (F) MT_SETBLK Sets the block size (in bytes) of the tape blocks. Takes as an argument the size in bytes. (S) MT_GETVTBL Takes a pointer to a struct ft_vtbl and copies in the volume table from the tape. (F) MT_PUTVTBL Takes a pointer to a struct ft_vtbl and writes the volume table onto the tape. This command should be used with caution. (F) MT_RFM Winds the tape forward to the next file mark. (C,S) MT_WFM Writes a file mark at the current location on the tape. (C,S) MT_LOAD On devices which are capable of doing so, loads the tape into the drive. (S) MT_UNLOAD On devices which are capable of doing so, unloads the tape from the drive. (S) Irwin-specific ioctl Interface Device specific functions of the Irwin tape drive are accessed via special commands passed to the Irwin driver using the ioctl() interface. An Irwin driver interface library is available. This library provides a system independent interface to ioctl() via the entry point mcioctl(): #include "mc.h" int mcioctl(fh, cmd, arg) int fh; /* File handle from open() */ int cmd; /* MCCTL_* command code */ void *arg; /* Additional argument pointer */ mcioctl(fh, MCCTL_NOP, NULL) mcioctl(fh, MCCTL_VERSION, verbuf) mcioctl(fh, MCCTL_CAPACITY, capp) mcioctl(fh, MCCTL_LSEEK, lskbuf); mcioctl(fh, MCCTL_REWIND) mcioctl(fh, MCCTL_RETEN) mcioctl(fh, MCCTL_REWIND_NW) mcioctl(fh, MCCTL_RETEN_NW) mcioctl(fh, MCCTL_GETDRVCFG, cfgbuf) mcioctl(fh, MCCTL_GETCFG, cfgbuf) mcioctl(fh, MCCTL_SETCFG, cfgbuf) mcioctl(fh, MCCTL_GETTHDR, hdrbuf) mcioctl(fh, MCCTL_PUTTHDR, hdrbuf) mcioctl(fh, MCCTL_GETDLISTS, listbuf) mcioctl(fh, MCCTL_FLUSH) mcioctl(fh, MCCTL_FORMAT, fmtbuf) mcioctl(fh, MCCTL_FMTSTAT, fmtbuf) mcioctl(fh, MCCTL_ABORT) mcioctl(fh, MCCTL_DEVSTAT, dstatp) mcioctl(fh, MCCTL_GETERCTL, erctlp) mcioctl(fh, MCCTL_SETERCTL, erctlp) mcioctl(fh, MCCTL_GETER, ierrp) struct mcver *verbuf; /* version buffer */ long *capp; /* capacity in bytes */ struct mclseek *lskbuf; /* tape logical position descriptor */ struct mccfg *cfgbuf; /* configuration buffer */ char *hdrbuf; /* 1024 byte header buffer */ unsigned short * listbuf; /* 2048 byte defect list buffer */ struct mcfmt *fmtbuf; /* format control/status buffer */ unsigned short *dstatp; /* device status word */ unsigned short *erctlp; /* error control word */ unsigned short *ierrp; /* device specific error */ mcioctl() provides system independent ioctl interface to the Irwin driver. This subroutine is essentially a pass-trough. That is, arguments are passed through to ioctl(). If a device specific error occurs (i.e., a non-system error) at completion of the system ioctl() and the command is other than MCCTL_NOP or MCCTL_VERSION, mcioctl() executes ioctl(MCCTL_GETER) to retrieve the device specific error. The following ioctl commands are available for the Irwin driver: MCCTL_NOP No operation. The argument is ignored. A success status is returned. This command may be used as an aid in determining if a special file refers to the MC driver. MCCTL_VERSION Gets driver version information. The argument is the address of version information buffer (see struct mcver in /usr/include/sys/mc.h) to which the driver writes. MCCTL_CAPACITY Gets a tape's capacity in bytes. The argument is the address of a long integer. MCCTL_REWIND MCCTL_RETEN MCCTL_REWIND_NW MCCTL_RETEN_NW These four commands physically position the tape at high speed. MCCTL_RETEN and MCCTL_RETEN_NW run the tape to the early warning hole first. All four commands return the tape to the load-point hole. MCCTL_REWIND_NW and MCCTL_RETEN_NW start a request but don't wait for completion. MCCTL_GETDRVCFG MCCTL_GETCFG MCCTL_SETCFG These three commands provide access to configuration parameters for a particular a mini cartridge tape unit. The structure of these parameters is struct mccfg (defined in /usr/include/sys/mc.h) This structure has driver, tape drive, and cartridge related fields. Both MCCTL_GETDRVCFG and MCCTL_GETCFG copies the driver's the MCCFG structure to the caller's buffer. When MCCTL_GETDRVCFG is used, struct mccfg members with driver and tape drive related fields are returned. No error is given when a cartridge is absent. When MCCTL_GETCFG is used successfully, all fields are returned with valid data. An error is returned if no cartridge is present. MCCTL_SETCFG allows the caller to adjust certain fields in the driver's configuration. MCCTL_GETTHDR MCCTL_PUTTHDR MCCTL_GETTHDR and MCCTL_PUTTHDR read and write the 1024 byte tape header in block 0. MCCTL_PUTTHDR assumes an Irwin style header. The the following procedure is used to write the header: Tape block 0 is read to a buffer. The caller's 1024 byte header buffer is copied to the first, fifth, and when space permits, the ninth and thirteenth 1024-byte sectors in the buffer. When the cartridge format uses ECC (i.e., other than 110 cartridge format), the header's ECC in use field is set. When the cartridge format uses ECC, ECC is encoded. A check sum is calculated for the buffer. The buffer is written back to block 0. Block 0 is reread and the cartridge state is redetermined. A new checksum is calculated and compared against the original. MCCTL_GETDLISTS Returns lists used by the driver's flaw management. The caller gives the address of a buffer which is at least 2 KB in length. Four lists are copied to the buffer. Each list is comprised of physical tape block numbers stored as unsigned short integers and terminated with the value 0xffff. The lists are contiguous and given in the following order: Primary Defect List (PDL) Working Defect List (WDL) Grown Defect List (GDL) Relocation List (RL) MCCTL_FLUSH Flushes dirty buffers to tape. MCCTL_FLUSH forces dirty buffers in the Irwin driver's cache to be written to tape. The pointer argument is ignored. Control returns when data is written. Buffers are automatically flushed upon a close() or when the device is idle for a certain period (see mc_autoflush in struct mccfg in /usr/include/sys/mc.h). MCCTL_FORMAT MCCTL_FMTSTAT MCCTL_FORMAT starts a erase, servo-format-certify- initialize header or re-certify operations. The argument is the address of struct mcfmt (see /usr/include/sys/mc.h). Formatting operations performed depend upon the values in the structure's fm_cmd and fm_option fields, and struct mccfg mc_cartstate field. When an MCCTL_FORMAT command completes successfully, MCCTL_FMTSTAT is used to determine the progress (when a no-wait flag is set) or results of formatting. Like MCCTL_FORMAT, MCCTL_FMTSTAT also uses the struct mcfmt structure (typically the same one passed to MCCTL_FORMAT). MCCTL_ABORT Used to interrupt and terminate operations started by MCCTL_FORMAT. The pointer argument is ignored. Control returns after formatting has terminated. MCCTL_DEVSTAT Returns a 16-bit device status word to an unsigned short integer who's address is passed in the third argument of ioctl(). This field is intended for use by applications which use the tape drive interactively. The status bits are defined in struct mclseek in /usr/include/sys/mc.h. MCCTL_GETERCTL MCCTL_SETERCTL MCCTL_GETERCTL and MCCTL_SETERCTL give application access to the state of and control over certain error mechanisms. The argument is the address of a 16-bit error control variable which the Irwin driver writes with current values for MCCTL_GETERCTL and reads for MCCTL_SETERCTL. Certain flags may or may not have an effect depending on the implementation. Bit values for the error control variable are defined in /usr/include/sys/mc.h. MCCTL_GETER Gets device specific error: IE_*. In general the value 0 is returned to indicate success or -1 to indicate an error. When mcioctl() returns the value -1, an error has occurred. The error condition may have been detected in the operating system or in the driver. In order to discriminate the origin the global _mcerrno should be examined first (before errno). When non- zero, the error was returned by the driver. Values for _mcerrno are defined in /usr/include/ierrno.h with an IE_ prefix. Floppy Tape Drive Configuration and Media This section is concerned with QIC-40 and QIC-80 tape drives and supported floppy tape cartridges. Configuration Options for the Floppy Tape Driver (ft) Five configuration options are available for the floppy tape driver (ft) for QIC-40 and QIC-80 tape drives. To alter these variables, it is necessary to edit the configuration file /etc/conf/pack.d/ft/space.c, relink the kernel, and reboot the system with the new kernel. While all options may be edited manually in space.c, the first and second options - ft_drivetype and ft _select_mode - may also be modified using the mkdev(ADM) tape command. These options are summarized in the following table: __________________________________________________________ | Floppy Tape Drive Configuration Options | |_________________________________________________________| |Variable | Values | Editing | | | | mkdev Manual | |________________|_______________________|_______|________| |ft_drive_type | FT_QIC40 | yes | yes | | | FT_QIC40XL (FT_QIC60) | | | | | FT_QIC80 | | | | | FT_QIC80XL | | | |________________|_______________________|_______|________| |ft_select_mode | FT_HARD_SELECT | yes | yes | | | FT_SOFT_SELECT | | | |________________|_______________________|_______|________| |ft_alloc_switch | FT_OPEN_TIME | no | yes | | | FT_INIT_TIME | | | |________________|_______________________|_______|________| |ft_minbufs | 2 < x < (ft_maxbufs) | no | yes | |________________|_______________________|_______|________| |ft_maxbufs | (ft_minbufs) < x < 20 | no | yes | |________________|_______________________|_______|________| ft_drivetype When set from FT_QIC40 to FT_QIC40XL, or from FT_QIC80 to FT_QIC80XL, ft_drivetype enables support of extended length (307.5 ft) DC2120 mini-cartridges in the driver. FT_QIC60 is an obsolete value; FT_QIC40XL should be used instead. A QIC-40 drive should never be operated with ft_drivetype set to FT_QIC80 or FT_QIC80XL. Also, a QIC-80 drive should never be operated with ft_drivetype set to FT_QIC40 or FT_QIC40XL. If they are, your system may panic or hang, or data may be lost from the tape media ft_select_mode When set to FT_HARD_SELECT, the ft driver expects a normal tape drive with a drive select jumper to be present. If ft_select_mode is set to FT_SOFT_SELECT, the ft driver uses Soft Select mode to access the tape drive, which must be a Soft Select-compatible QIC-40 or QIC-80 tape drive with no drive select jumpers installed. ft_alloc_switch When set to FT_OPEN_TIME, the ft driver allocates memory when it is needed, and frees memory once it is no longer needed. Typically, memory is allocated at open time and released at close time. When ft_alloc_switch is set to FT_INIT_TIME, all memory allocation is done at init time (when the system boots) and the ft driver retains this memory. The advantage of init time allocation is that more memory is available for the ft buffers. The disadvantage is that this memory is held by the tape driver and cannot be used elsewhere in the system. ft_minbufs ft_maxbufs These variables set the minimum and maximum number of 32K buffers that the ft driver is allowed to use. The lower limit of the minimum is hard set to 2, with any value lower than 2 interpreted as 2. The upper limit of the maximum is hard set to 20, with numbers greater than 20 interpreted as 20. When the ft driver allocates memory for buffers, it requests ft_maxbufs first. If this fails, ft reduces its request by one and tries again. This continues until either the request is satisfied or ft_minbufs buffers fail to be allocated. If the request is satisfied, then ft proceeds. Otherwise, the tape operation fails and ENOMEM (Error, no memory for buffers) is returned. The exception to this is when ft_alloc_switch is set to FT_INIT_TIME (allocation takes place at init time). If the ft_minbufs are not available at init time, then ft resorts to allocation as needed (as if ft_alloc_switch were set to FT_OPEN_TIME). If this condition occurs, a warning is printed at init time. It is recommended that ft_minbufs be set to at least 3. Although the driver can operate with only two buffers, performance is seriously degraded; the tape never streams, and in fact produces an underrun for every 32K block written to the tape. Floppy Tape Cartridge Media There are three mini-cartridge types appropriate to floppy tape drives: ______________________________________ | Floppy Tape Mini-Cartridge Types | |_____________________________________| |Cartridge | Length | Width | Maximum | | | (ft) | (in) | Density | | | | | (ftpi) | |__________|________|_______|_________| |DC2000 | 205 | 0.25 | 12,500 | |DC2080 | 205 | 0.25 | 14,700 | |DC2120 | 307.5 | 0.25 | 14,700 | |__________|________|_______|_________| DC2000 and DC2080 are available unformatted or preformatted from the manufacturer. Irwin format tapes are incompatible with the floppy tape driver. If a 2120 cartridge is inserted into a drive, it can be detected as an extended length tape and will be formatted for 60 Mbytes on QIC-40 drives, and 120 Mbytes on QIC-80 drives. Some older QIC40 drives are not able to detect extended length tapes. These models should never be operated with a DC2120 inserted, since they will expect a 205 foot tape length. Drives cannot distinguish between blank (unformatted) DC2000 & DC2080. Never attempt to format a DC2080 in a QIC-40 drive, or a DC2000 in a QIC-80 drive. Media configurations for floppy tape drives are summarized in the following table: __________________________________________________________ | Floppy Tape Drive Media Configurations | |_________________________________________________________| |Drive | ft_drivetype | Media | Formatted | Operations | | | | | Capacity | | | | | | (MB) | | |_______|______________|_________|___________|____________| |QIC-40 | FT_QIC40 | DC2000 | 40 | r/w/f | |_______|______________|_________|___________|____________| |QIC-40 | FT_QIC40XL | DC2000 | 40 | r/w/f | | | | DC2120 | 60 | r/w/f | |_______|______________|_________|___________|____________| |QIC-80 | FT_QIC80 | DC2000 | 40 | r | | | | DC2080 | 80 | r/w/f | |_______|______________|_________|___________|____________| |QIC-80 | FT_QIC80XL | DC2000 | 40 | r | | | | DC2120 | 60 | r | | | | DC2080 | 80 | r/w/f | | | | DC2120 | 120 | r/w/f | |_______|______________|_________|___________|____________| Irwin Drive and Cartridge Models This section is concerned with Irwin tape drives and cartridges supported. Drive Models Many Irwin mini cartridge drives have a three digit model number. Each digit has a meaning. The high order digit encodes the form factor and cabinetry: 1xx 5-1/4 inch drive (mounted in system cabinet). 2xx 3-1/2 inch drive (mounted in system cabinet). 3xx 5-1/4 inch drive in a metal cabinet w/ power supply. 4xx 3-1/2 inch drive in a plastic cabinet (no supply). 7xx 3-1/2 inch drive in a metal cabinet w/ power supply. The middle digit gives the approximate capacity, in 10 Megabyte units for a standard capacity (not extra long) tape: x1x 10 Megabytes x2x 20 x4x 40 x6x 60 x8x 80 The low digit encodes the drive's normal data transfer rate (i.e., the floppy controller data clock rate). xx0 250 Kilobits/Second xx5 500 Kilobits/Second xx7 1 Megabit/Second In addition, a new 4-digit model numbering system is in use. These model numbers are associated with drives which are adaptable to different system hardware environments with accessory hardware kits. 2020 3-1/2 inch, 20 Megabyte, 250 Kilobits/Second 2040 3-1/2 inch, 40 Megabyte, 500 Kilobits/Second 2080 3-1/2 inch, 80/120 Megabyte, 500 Kilobits/Second 2120 3-1/2 inch, 80/120 Megabyte, 1 Megabit/Second Mini Cartridges There are three primary physical mini cartridges types: DC1000 185 feet of 0.150 inch wide tape (same as TC-200) DC2000 205 feet of 0.250 inch wide tape (same as TC-400) DC2120 307.5 feet of 0.250 inch wide tape The DC1000 cartridge is physically thinner than DC2000 and DC2120 cartridges. The DC2000 and DC2120 have the same physical form but the DC2120 has a longer tape. These cartridges are distinguished by their labels. Each physical cartridge type has at least two cartridge formats: ___________________________________________________________________________ | Mini (Irwin) Cartridge Format Parameters | |___________________________________________________________________________| | | AccuTrak | | | | | Sectors | | |Cart- | Reorder | Cart- | Total | | Blocks | per | | |ridge | Number | ridge | Tape | Trks | per | Block | Density | |Format | see note | | Blocks | | Track | Data ECC | (ftpi) | |_______|__________|________|________|______|________|______|_____|_________| |110 | 1000-10 | DC1000 | 1264 | 8 | 158 | 8 | 0 | 6400 | |120 | 2000-20 | DC2000 | 1190 | 14 | 85 | 16 | 2 | 6400 | |120XL | 2000-30 | DC2120 | 1792 | 14 | 12 | 16 | 2 | 6400 | |125 | 1000-20 | DC1000 | 1320 | 12 | 110 | 16 | 2 | 10000 | |145 | 2000-40 | DC2000 | 2480 | 20 | 124 | 16 | 2 | 10000 | |145XL | 2000-60 | DC2120 | 3720 | 20 | 186 | 16 | 2 | 10000 | |165 | 2000-64 | DC2000 | 3936 | 24 | 164 | 16 | 2 | 13200 | |285 | 2000-80 | DC2000 | 2752 | 32 | 86 | 29 | 3 | 11600 | |285XL | 2000-120 | DC2120 | 4160 | 32 | 130 | 29 | 3 | 11600 | |_______|__________|________|________|______|________|______|_____|_________| Notes: The suffix part of the AccuTrak Reorder Number is an approximate cartridge capacity in Megabytes. All formats use 1024 byte MFM encoded sectors. _________________________________________________________________ | Drive Read/Write Compatibility for Mini Cartridge Formats | |________________________________________________________________| | Drive Model (See Note) | |________________________________________________________________| | | | 2020 | | 2040 | | | | | | | | 720 | 725 | 745 | | | | | | | | 420 | 425 | 445 | 765 | 2080 | 2120 | | |Cart- | 410 | 320 | 325 | 345 | 465 | 785 | 787 | | |ridge | 310 | 220 | 225 | 245 | 265 | 485 | 487 | Cart- | |Format | 110 | 120 | 125 | 145 | 165 | 285 | 287 | ridge | |_______|_____|________|_____|______|_____|______|______|________| |110 | rw | rw | r- | r- | r- | r- | r- | DC1000 | |120 | -- | rw | -- | r- | r- | r- | r- | DC2000 | |120XL | -- | rw | -- | r- | r- | r- | r- | DC2120 | |125 | -- | -- | rw | rw | r- | r- | r- | DC1000 | |145 | -- | -- | -- | rw | r- | r- | r- | DC2000 | |145XL | -- | -- | -- | rw | r- | r- | r- | DC2120 | |165 | -- | -- | -- | -- | rw | r- | r- | DC2000 | |285 | -- | -- | -- | -- | -- | rw | rw | DC2000 | |285XL | -- | -- | -- | -- | -- | rw | rw | DC2120 | |_______|_____|________|_____|______|_____|______|______|________| Key: r Drive reads cartridge format w Drive writes cartridge format - Incompatible: When a cartridge is formatted but incompatible for reading or writing, the driver reports that the cartridge is either incompatible or erased. Extra Long (XL) DC2120 Cartridge Compatibility Extra long (i.e., DC2120) cartridges are incompatible with the following drives as the drive will not physically accommodate the cartridge: 110, 310, 410, 125, 225, 325, 425, and 725 Even though DC2120 cartridges are physically accepted in the following drives, they may not be formattable: 120, 220, 320, 420, 720, 2020, 145, 245, 345, 445, 745, 2040 Drives manufactured previous to about 1989 don't recognize the longer tape. However, the MC driver is able to read and write preformated extra long tapes in these drives, but it is unable to correctly format them. Formatting will start, but terminate in error. To determine whether a drive supports formatting of DC2120 cartridges, use the mcart utility. If the command mcart drive reports a drive type with the suffix XL, formatting of DC2120 cartridges is supported. Files /dev/rStp0 /dev/rct0 /dev/erct0 /dev/rmc1 /dev/nrStp0 /dev/nrct0 /dev/xct0 /dev/mcdaemon /dev/xStp0 /dev/rct2 /dev/rctmini /dev/rft0 /dev/nrct2 /dev/xctmini /dev/xft0 /dev/xct0 /dev/rmc0 Include files: /usr/include/sys/tape.h /usr/include/sys/ct.h /usr/include/sys/ft.h /usr/include/sys/ir.h /usr/include/sys/mc.h /usr/include/sys/mcheader.h Notes After certain tape operations are executed, the system returns a prompt before the tape controller has finished its operation. If the user enters another tape command too quickly, a ``device busy'' error is returned until the tape device is finished with its previous operation. Periodic tape cartridge retensioning and tape head cleaning are necessary for continued error-free operation of the tape subsystem. Use tape(C) to retension the tape. See Also backup(ADM), xbackup(ADM), cpio(C), dd(C), format(C), mkdev(ADM), tape(C), tar(C), restore(ADM), xrestore(ADM) TAPE(HW) MKDEV(ADM) UNIX System V Name mkdev - calls scripts to add peripheral devices Syntax /etc/mkdev dos /etc/mkdev fd /etc/mkdev fs [ device file ] /etc/mkdev hd [ [ disk ] [ controller| adapter ] ] [ lun ] /etc/mkdev mouse /etc/mkdev serial /etc/mkdev shl /etc/mkdev streams /etc/mkdev tape Description mkdev creates the device file(s) associated with a peripheral device. Based on the argument supplied, the mkdev command calls a script found in the directory /usr/lib/mkdev. (There may be scripts found in this directory that are specific to a given application or software package that are not documented here.) If no arguments are listed, mkdev prints a usage message. /etc/mkdev dos initializes necessary devices and configures the system to support mounted DOS filesystems. /etc/mkdev hd creates device files for use with a peripheral hard disk. The device files for an internal hard disk already exist. invokes the following utilities: dparam(ADM), badtrk(ADM), fdisk(ADM), and divvy(ADM). mkdev hd includes an extended syntax for use on multiple controllers. These syntax extensions use numbers to refer to the disk and controller numbers. In addition, the codes ST506-, OMTI-, and SCSI- can be used to refer to the controller/adapter number, as shown in the tables below. ST506 disks will install with one of the following commands: mkdev hd 0 0 (or ST506-0) first disk on first controller mkdev hd 1 0 (or ST506-0) second disk on first controller mkdev hd 0 1 (or ST506-1) first disk on second controller mkdev hd 1 1 (or ST506-1) second disk on second controller ESDI disks will install with one of the following commands: mkdev hd 0 0 (or OMTI-0) first disk on controller (root disk) mkdev hd 1 0 (or OMTI-0) second disk on controller SCSI disks require three pieces of information: the drive number, the adapter number, and the lun (logical unit number). SCSI disks will install with the following command: mkdev hd [0-7] [SCSI-0 or SCSI-1] [0-7] mkdev hd must be invoked twice to install a SCSI disk. The first time, the kernel will be reconfigured to support the new disk. The second time, the disk will be initialized. Use the same mkdev hd arguments both times. /etc/mkdev serial creates device files for use with serial cards. The device files for the first and second ports already exist. Additional device files must be created for the ports added when expansion cards are added to the system. /etc/mkdev streams configures the kernel for streams support. /etc/mkdev fs performs the system maintenance tasks required to add a new filesystem to the system once the device is created (mknod(C)) and the filesystem is made (mkfs(ADM)). It creates the /file and /file/lost+found directories, reserves slots in the lost+found directory, (if either already exist, they are used unmodified) and modifies /etc/checklist, /etc/default/filesys and /etc/default to check (fsck(ADM)) and mount (mount(ADM), mnt(C), rc(C)) the filesystem as appropriate. It is usually used in conjunction with mkdev hd when adding a second hard disk to the system or with mkdev fd when creating a mountable filesystem on a floppy, but can be used on any additional filesystem (for example, on a large internal hard disk). /etc/mkdev fd creates bootable, root and filesystem floppy disks. Several floppies can be created during a single mkdev fd session, but mkdev does not display a prompt to remove the first floppy and insert the next one. Insert the next floppy when mkdev prompts ``Would you like to format the floppy first? (y/n).'' /etc/mkdev tape configures the tape driver in preparation for linking a new kernel that includes tape support. It adds a standard cartridge tape driver, a mini-cartridge tape driver, a QIC-40 or QIC-80 floppy tape driver, or a SCSI tape driver. In configuring a cartridge tape drive, the current driver configurations can be displayed, and changed if necessary. A zero in any of the fields means the driver automatically detects the type of tape device installed and uses the built-in values for that device. If the autoconfiguration values are not correct for your tape drive, refer to your hardware manual for the correct values, reconfigure the driver and relink the new kernel. mkdev tape can also be used to remove a tape driver from the kernel. /etc/mkdev shl initializes necessary devices and configures kernel parameters associated with the number of shell layers sessions available on the system. /etc/mkdev mouse initializes necessary devices and configures the system to use any supported mouse. Once the driver is configured, you are prompted for re- linking the kernel. The appropriate devices in /dev are created. The various init scripts prompt for the information necessary to create the devices. Files /usr/lib/mkdev/* See Also badtrk(ADM), divvy(ADM), dparam(ADM), fd(HW), fdisk(ADM), filesys(F), format(C), hd(HW), lp(HW), mkfs(ADM), mknod(C), mount(ADM), serial(HW), usemouse(C), tape(HW) The System Administrator's Guide has chapters devoted to the installation of most peripheral devices. Value Added mkdev is an extension of AT&T System V provided by the Santa Cruz Operation. MKDEV(ADM)