User's Guide

ANSI

Function:

The ANSI routines read and write magnetic tapes written in ANSI standard format (called ``Files-11'' by DEC).

There are six ANSI routines:

The ANSI routines are called in the following manner:
ansicommand -options arg1 arg2 ... argn
where ansicommand is one of the six routines, options are command line options, and arg1 through argn are arguments that go with the specified options. When arguments are specified, they must be in the same order as their corresponding options.

History:

The ANSI routines originate from the UNIX operating system. They were ported to the VMS operating system in September, 1992.

User Notes:

Specifying command-line options on a VMS system
When running on a VMS system, the individual character flags must be placed in double quotes (Example: ansiout "-TvDFbdrtRf" ...). Using the double quotes will ensure that upper case letters (if there are any) will remain in upper case.

Specifying conflicting command-line options
If two conflicting options are specified on the command line (e.g., specifying both the D and F options in ansiout), the LAST option specified will be used.

File version numbers
Since the ANSI routines originate from the UNIX environment where file version numbers are not supported, the ANSI routines cannot handle file version numbers. Unexpected results may occur if files exist on a VMS system with multiple version numbers. For example, suppose that xxx* is to be written out, and xxx;1, xxx;2, and xxx;3 exist. ansiout will write out three copies of xxx;3! This is because three files exist that match xxx*, but ansiout strips off the version number from the file name, so when xxx (no version number) is copied to tape, by default it is the latest version. The safest thing to do is to ensure that multiple version numbers are not present.

End of tape marks
Due to the varying behavior of tape drives upon encountering EOT marks, it is highly recommended that EOT marks be avoided. When running ansiout, use the 't' flag and conservatively estimate the length of the tape being written to. If an EOT is encountered while writing, the routine will now error out with a message and terminate.

Mounting of tapes
Mounting and dismounting is left to the user of the ANSI routines. The only time the ANSI routine gets involved in mounting/dismounting tapes is when spanning multiple tapes.

Error recovery in writing data and EOF marks
The original version of ansiout tried to recover from an error writing data to the tape but not if writing an EOF mark. Following much discussion and testing, the routine will now error out and terminate if an error is encountered while writing either data or an EOF mark.

Fixed length records
If the fixed length record flag is specified ('F'), the record and block size must be specified correctly or errors will result.

Directory specifications
Directory specifications are not supported. The user must be in the directory of interest before running the ANSI routine. This is because the ANSI standard tape format does not allow enough room for lengthy directory specifications in the file header.

ulout testing
Ulout has not been tested since the conversion to VMS. The only reason it has been included is because it existed previously as part of the ANSI tape code and calls some of the same routines. Ulout does compile, but until a need for it is expressed, it will not be tested and converted to VMS.

Bugs:

Tape drives
In general, more problems occur when using remote tape drives. If possible, it is suggested that a local drive be used. Also, the ANSI routines are very sensitive to problems with certain tape drives. If an error occurs with a certain drive, a different one should be tried.

Running on SUN workstations
In general, behavior in SUN workstations is unpredictable at best, and errors are not necessarily repeatable. However, the original version of the ANSI routines act much like the current VMS version (i.e., these problems were inherited from the original code). A description of some of the problems follows.

Getting a directory of a multi-volume tape set
ansidir may "hang" or error out when closing the second tape of a multi-volume set. The routine "hangs" or errors out after all reading has been done, so a complete directory listing will be generated. ansidir using only the second tape will complete successfully.