• Aucun résultat trouvé

ANSI and DOS Format

Dans le document Guide Order (Page 164-174)

RSTS/E has two file structures for tapes:

o ANSI format, because it complies with the standards of the American National Standards Institute.

o DOS format, because RSTS/E adopted it from the Disk Operating System format.

The ANSI format is an industry standard. The advantages to using ANSI format tapes are:

o Portability - If you expect to move the contents of a tape from one system to another, it is very possible that the other systems will recognize ANSI format.

o Multiple tapes - The files you copy can be stored on more than one reel of tape.

Working with Devices 6-7

Note -Where ANSI is used in RSTS/E documentation, it refers to the

RSTS/E implementation of American National Standard X3.27 -1978, magnetic tape labels and file structure for information exchange.

RSTS/E implements a subset of this standard.

In addition, RSTS/E uses U (undefined) record format, which is not defined in ANSI standard X3.27 -1978.

The advantages of using DOS tape are:

o Files are associated with PPNs.

o Files are better for storing binary files that have no attributes, such as .OBJ (object) or .BAC (compiled BASIC-PLUS) files.

When you initialize a tape with the INITIALIZE command, you can select either ANSI or DOS format. Later, when you mount the tape, you must again tell the system whether the tape is in ANSI or DOS format. If you do not specify a format, the system uses the default determined by your system manager.

There are two ways to tell if a tape containing data is written in DOS or ANSI format:

o Look for a label on the tape. The person who put data on the tape may have placed a label on the tape and written DOS or ANSI on it.

o Try mounting the tape as either DOS or ANSI. When you mount a tape on a drive, RSTS/E checks the format. If you entered the right format, you can continue with tape operations. If you entered the incorrect format, RSTS/E displays the error message ?Bad directory for device, in which case you can try again using the other format.

If the tape is in ANSI format, then files on the tape do not have PPNs. They have only names and types.

If the tape is in DOS format, then each file on the tape has a PPN. The PPN of a tape is like the directory on a disk file. For example, a DOS format tape on drive MTD: might contain a file whose specification is:

MTO:[l,ZJSLOW.RUN

Another file on the tape might have the specification:

MTO:[3,4SJGOOD.RUN

6-8 Working with Devices

ALLOCATE

Physical Device Commands

ALLOCATE

This section contains descriptions of some commands you use when working with physical devices. See the RSTSIE System Manager's Guide for commands and functions that require additional privileges to use.

The ALLOCATE command reserves a physical device for your use during the current session and optionally establishes a logical name for the device. Once a device has been allocated, other users cannot access the device until you specifically deallocate it or log out. You can allocate a device only when it is not allocated by another job.

Format

ALLOCATE device-name[:] [logical-name[:]]

Prompts

Device: device-name

Command Parameters device-name[:]

A logical or physical name.

logical-name[:]

Specifies a one- to six-character logical name to be associated with the device.

RSTS/E automatically translates any references you make to the logical name to a physical device associated with the name. The logical name parameter is optional.

Worldng with Devices 6-9

DEALLOCATE

DEALLOCATE

The DEALLOCATE command releases a device that you reserved for private use, so that other users may have access to "it. (However, note that DEALLOCATE does not deassign any logical name you may have assigned to the device; for that you need the DEASSIGN command.)

Format

DEALLOCATE [device-name[:] ] Command Qualifiers

fALL Prompts

Device: device-name[:]

Command Parameters device-name [ :]

Specifies the name. of the device to be deallocated. The device name can be a physical device name or a logical name. The device name parameter is required unless you specify the / ALL qualifier.

Command Qualifiers fALL

Requests that all devices you have currently allocated be deallocated.

If you specify / ALL, you cannot specify a device name.

6-10 Working with Devices

MOUNT

MOUNT

The MOUNT command prepares a tape or disk for processing by system commands or user programs. Issue the MOUNT command after you physically mount the tape or disk and put the drive on line.

- - - Note

The MOUNT command has additional capabilities for users with greater levels of privilege. See the RSTSIE System Manager's Guide for more information.

If the MOUNT command fails with the error message ?Disk pack needs REBUILDing, but you do not have sufficient privileges, have your system manager mount the disk.

Format For disks:

MOUNT device-name[:] pack-id [logical-name] ] For magnetic tapes:

MOUNT device-name[:] {[label]}

Command Qualifiers I[NO]WRITE

Qualifiers for Disks /PRIVATE

I[NO]SHARE

Qualifiers for Tapes IDENSITY=n

IFORMAT = ANSI IFORMAT=DOS IFORMAT = FOREIGN Prompts

Device: device-name[:]

Defaults See description Defaults /PRIVATE IS HARE

Label: label (for ANSI tapes only) Pack-id: pack-id (for disks only)

Working with Devices 6-11

MOUNT

Depending on whether you are mounting a tape or disk, the MOUNT command:

• Specifies a tape's density and format

o Checks that a tape or disk's device specification is correct o Checks that a tape or disk has been initialized

o Verifies that a tape or disk drive had not been allocated to another user o Allocates a tape drive (reserves it for your use)

o Verifies that a disk or tape is physically loaded on the device you specified

o Verifies that the pack-id on a disk or the label on a tape (except for DOS tape) matches the label you specified

o Allows you to mount a private pack for your own use Command Parameters

device-name[: ]

Specifies the physical or logical name of the drive on which a device is to be logically mounted.

pack-id logical-name label

Identifies the tape or disk to be mounted. The pack-id, logical-name, or label can have from one to six alphanumeric characters.

The label is required when you mount a disk or a tape in ANSI format. It is not required (and is ignored) when you ·mount a tape in DOS or foreign format.

Command Qualifiers IDENSITY=n

Specifies the density in bits per inch (bpi) at which the tape will be read or written. This qualifier is valid only with tapes.

You can specify 800 or 1600 bpi, depending on the density supported by the tape drive. The default density depends on your installation.

IFORMAT = ANSI IFORMAT=DOS IFORMAT = FOREIGN

Indicates whether the tape is in a standard format used by the RSTS/E operating system. This qualifier is valid only with tapes.

6-12 Working with Devices

MOUNT

A tape is FOREIGN if it is not in ANSI or DOS format. If you mount a tape with /FORMAT=FOREIGN, the program you use to read the tape must be able to process any labels on the tape.

/PRIVATE

Allows you to mount a private disk, accessible only to those users who have accounts on the disk. (Your system manager designates whether disks are public or private.)

/SHARE INOSHARE

Determines. whether the private disk you use is shared. The INOSHARE qualifier allows you to mount a private disk that is accessible only to the job that mounts it. The /SHARE qualifier allows all users who have accounts on the disk to access it. The !PRIVATE and /SHARE qualifiers have the same meaning. If you specify INOSHARE, you cannot specify !PRIVATE.

The default is /SHARE.

!WRITE INOWRITE

Controls whether or not you can write data to a tape or disk. The !WRITE qualifier allows you to modify the data contained on a tape or disk. If you specify INOWRITE, you cannot modify the data.

You can specify INOWRITE to provide read-only access to protect files. For a disk, this is equivalent to write-protecting it. For a tape, the drive itself must be write-protected; INOWRITE simply generates an error message if the device is not write-protected.

When the device is not write-protected, !WRITE is the default for tapes. When the disk drive is not write-protected, !WRITE is also the default for disks (initialized as read/write). However, INOWRITE is the default if the drive is write-protected.

Therefore, if you receive the warning message %Device write protected, you have logically mounted your disk or tape with read-only access. The default is also INOWRITE for disks initialized as read-only.

Working with Devices 6-13

INITIALIZE

INITIALIZE

The INITIALIZE command deletes any data on a tape and writes a new label.

INITIALIZE allocates the tape drive if it is not already allocated.

Use INITIALIZE to prepare a new tape or a tape that contains no useful files. Use MOUNT to prepare an already initialized tape that contains files you want to keep.

- Note ---See the RSTSIE System Manager's Guide for information on using INITIALIZE with disks.

Format

INITIALIZE device-name[:] [label]

Command Qualifiers IFORMAT = ANSI IFORMAT=DOS IDENSITY=n Prompts Device:

Label:

Proceed (Y or N):

device-name[:]

label

Note ---The label prompt appears only for a tape in ANSI format or if

IFORMAT

=

ANSI is specified. The proceed prompt asks you to confirm whether you want to initialize the tape. Type yes or no (Y or N) in response to the prompt.

Command Parameters device-name[: ]

Specifies the name of the drive on which the tape is physically mounted.

label

Specifies the identification to be encoded on the tape. You can specify a maximum of six alphanumeric characters. For an ANSI-format tape, the label is required. For a DOS-format tape, the label is ignored, because DOS tapes do not have labels.

6-14 Working with Devices

INITIALIZE

Command Qualifiers IDENSITY=n

Specifies the density in bpi at which to write the tape. You can specify a density of either 800 or 1600 bpi if the tape drive supports it.

If you do not specify a density, the system uses the default specified by your system manager.

IFORMAT = ANSI IFORMAT=DOS

Specifies the tape format. If you do not specify a format, DeL uses the default determined by your system manager.

Working with Devices 6-15

DISMOUNT

DISMOUNT

The DISMOUNT command releases a disk or tape previously accessed with a MOUNT command. Use the DISMOUNT command before you take the drive off line, or before you physically dismount the tape or disk.

Note ---The DISMOUNT command has additional capabilities for users with greater levels of privilege. See the RSTSIE System Manager's Guide for more information.

The DISMOUNT command deallocates the device if it was allocated to you. You cannot DISMOUNT a device if there are open files on it. If you try, RSTS/E displays the error message:

?Account or device in use Format

DISMOUNT device-name[:] [label]

Command Qualifiers (for tapes only)

I[NO]UNLOAD Prompts Device:

Pack-id:

device-name[:]

pack-id label

Command Parameters device-name[: ]

Defaults

IUNLOAD

Specifies the name of the device to be dismounted. If you omit a unit number, the default depends on the type of device.

label

Specifies the identification label of the device. Unless you have additional privilege, you must specify a disk's pack-id label to dismount it. For tapes, the label is optional (and is ignored).

Command Qualifiers IUNLOAD

/NOUNLOAD

Rewinds and unloads the tape. This protects the tape against unauthorized access by other users. The default is IUNLOAD.

6-16 Working with Devices

Dans le document Guide Order (Page 164-174)