How to write compressed tapes on

reference platforms:

IRIX, AIX, Digital UNIX

Francesco Prelz, May 2, 1997

The easiest way to write tapes in compressed mode is through the Fermilab tape access product, FTT. The only drawback of this approach is that there is no FORTRAN callable programmer's interface for FTT. There is no data compression explicit support in the other Fermilab tape utilities, such as DAFT and RBIO. Here's a prototype example of how to set compression via FTT (FTT will automatically take care of choosing/configuring the correct device driver for a given compression setting):

#include "ftt.h"

ftt_descriptor fd_out;
int tape_dens, tape_cmp, tape_blksize;

fd_out = ftt_open("file_name",FTT_RDWR);
ftt_get_mode(fd_out, &tape_dens, &tape_cmp, &tape_blksize);

/* Set compression ON */
tape_cmp = 1;

ftt_set_mode(fd_out, tape_dens, tape_cmp, tape_blksize);

/* The above MUST be done before the tape is written
or otherwise accessed */

Silicon Graphics, IRIX

IBM, AIX

Digital UNIX

How to enable compressed mode 8505 access on Alphas:

WARNING: this procedure is rather complicated, and should be performed by a knowledgeable system administrator. Don't read on if you are not one.

In order to be able to write compressed tapes on an Alpha via FTT, /usr/sys/data/cam_data.c needs to be modified so that the device driver "minor" devices are assigned as follows (This is not the current setup on e*831):

/*
rmtXl is 2.3 GB format
rmtXh is 5.0 GB format
rmtXa is 2.3 GB format with compression
rmtXm is 5.0 GB format with compression
*/
exb8505_dens = {
{
{ /* Minor 00 or rmtXl */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_54000_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 01 or rmtXh */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_45434_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 02 or rmtXm */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
0x8c, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 03 or rmtXa */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
0x90, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 04 */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_45434_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 05 */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_45434_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 06 */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_45434_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
},

{ /* Minor 07 */
/* Flags */
DENS_VALID | DENS_BUF_VALID ,
/* Density code Compression code Speed setting */
SEQ_45434_BPI, NULL, NULL,
/* Buffered setting Blocking */
1, NULL
}

}
}; /* end of exb8505_dens */

/* End density structures.. Please extend the table
* for your own tape drives.. The table is designed
* to allow for flexibility and customer selections
*/

The above fragment has to be inserted just before the "End density structures" comment in /usr/sys/data/cam_data.c. Also, the following device description has to be added to the cam_devdesc_tab array (at the very end of the /usr/sys/data/cam_data.c file).:

/* EXABYTE EXB-8505 */
{ "EXABYTE EXB-8505", 16, "EXB-8505",
(ALL_DTYPE_SEQUENTIAL << DTYPE_SHFT) | SZ_8MM_CLASS,
(struct pt_info *)ccmn_null_sizes, SZ_NO_BLK, 0x3c000,
&exb8505_dens, &exb8505_mod, SZ_NO_FLAGS,
NO_OPT_CMDS, 240, SZ_NO_QUE, DD_REQSNS_VAL | DD_INQ_VAL,
36, 64
},

This must be inserted just before the { 0 }.

After modifying the /usr/sys/data/cam_data.c as described, the kernel needs to be rebuilt (doconfig), and FTT needs to be rebuilt with the OSF1KERNELTABLES flag defined. This should make the FTT prototype given at the top of this page work.

Comments about this page should be sent to Francesco Prelz