T-DEVICE

Temporarily redefines the tape device definition for a specified tape unit for the current session.

Syntax

T-DEVICE {tape_unit {device_path {device_type}}}{(options}

Syntax elements

tape_unit An integer that specifies the tape unit for which the tape device is to be redefined.

If tape_unit is not specified, all tape units configured on the database are reset to their default tape definitions, as specified in the database configuration file.

device-path Specifies the new device to be defined for the specified tape unit.

For a remote tape unit, the syntax of the device-path parameter is as follows:

host{;port};device;type{;flags}

where:

host is the DNS name or TCP/IP address of the remote host.

port is an optional port number to be used on the remote machine - default: 52001.

device is the full path to the device on the remote host. Note that the device path must include any modifier required by the remote host (for example, no rewind, density).

type is the Reality tape type number of the drive on the remote machine.

flags Optional remote tape specific flags:

A Asynchronous mode (default).

S Synchronous mode.

If device-path is not specified, the specified tape unit is reset to its default device setting, as specified in the database configuration file.

Notes

  • If device-path specifies a tape image with a path containing spaces, you must enclose the complete path in double quotes.
  • If the TCLDELIMITER environment option is set, you cannot use backslashes in tape image paths entered at the TCL command prompt; either enclose the path in quotes or use forward slashes (/) instead.

device_type Specifies the new device type for the specified tape unit. The following numbers can be assigned:

1 1/2 inch tape (UNIX hosts only).

2 8mm Exabyte tape.

3 1/4 inch (QIC) cartridge.

5 DLT or 4mm (DAT) cartridge.

8 remote tape device.

9 tape image.

If device_type is unspecified, but tape_unit and device_path are specified, device_type defaults to 9 (tape image).

Options

E Check tape image exists (fail if it doesn't).

R Open existing image read only (implies option E is present).

Comments

Ensure that the specified tape unit is not currently assigned, otherwise T-DEVICE will fail.

After T-DEVICE has been executed, re-assign the specified tape unit to your terminal, using the T-ATT or ASSIGN command, to enable the tape unit to be accessed.

Note that T-DEVICE does not validate the specified device path. Validation is performed by the T-ATT or ASSIGN command when you re-assign the tape unit.

After running T-DEVICE, the T-STATUS command reports the status of the new tape device, showing whether or not it is assigned.

T-DEVICE only affects the current port. The tape device definition set by T-DEVICE is lost when the current port is logged off.

Tape images

For tape images, you can specify:

These options are specified as part of the device-path definition in the same way as in the database config file.

Data encryption

If required, you can specify that the data you save should be encrypted by Reality, by appending :kencryptionKey to the tape device definition. encryptionKey is the item-id of an encryption key item in the REK file. For example:

/user1/daveh/image.rti:kMYENCKEY

encrypts the data in the tape image file /user1/daveh/image.rti using the encryption key item MYENCKEY.

Notes:

  • The block size used with encrypted tape devices must be a multiple of 8.
  • When restoring data that was saved using an encrypted tape drive, you must first ensure that the source database's REK file is loaded (see LOAD-REK) and create an encrypted drive using the encryption key that was used when saving the data.

Examples

T-DEVICE 2 /dev/rmt/ctapen 3
(UNIX)
T-DEVICE 2 \\.\Tape0c 3
(Windows)

Redefines tape unit 2 as a quarter inch cartridge /dev/rmt/ctapen.

T-DEVICE 3 /user1/daveh/tape3

Redefines tape unit 3 as a tape image device /user1/daveh/tape3.

T-DEVICE 2 "C:\Documents and Settings\Pauls\My Documents\Temp\tape2.rti"

Redefines tape unit 2 as a tape image device C:\Documents and Settings\daveh\My Documents\Temp\tape2.rti.

T-DEVICE 1

Resets tape unit 1 to its default tape definition specified in the database configuration file.

T-DEVICE

Resets all tape units to their default tape definitions specified in the database configuration file.

T-DEVICE 1 shadowfax;/dev/rmt/1mbn;2 8

Redefines tape unit 1 as the 8mm (type 2) device on the shadowfax host.

T-DEVICE 3 shadowfax;/users/pauls/tape3.rti;9:c2:kENCKEY1 8

Redefines tape unit 3 as the tape image file /users/pauls/tape3.rti on the shadowfax host. Before transmission to the remote host, the data is compressed at level 2 and encrypted using the key item ENCKEY1.