z/OS DFSMS Using Data Sets
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Calculating DASD Space Used

z/OS DFSMS Using Data Sets
SC23-6855-00

This topic describes how the system calculates DASD space for new and existing extended-format data sets.

Space for a new data set: If you specify the BLKSIZE parameter or the average block size when allocating space for a new extended-format data set, consider the 32-byte suffix that the system adds to each block. Programs do not see this suffix. The length of the suffix is not included in the BLKSIZE value in the DCB, DCBE, JFCB, or DSCB.

Space for an existing data set: Some programs read the data set control block (DSCB) to calculate the number of tracks used or the amount of unused space. For extended-format data sets, the fields DS1LSTAR and DS1TRBAL have different meanings than for sequential data sets. You can change your program to test DS1STRIP, or you can change it to test DCBESIZE in the DCBE. DSCB fields are described in z/OS DFSMSdfp Advanced Services. For the DCBE fields, see z/OS DFSMS Macro Instructions for Data Sets.

Extended-format data sets can use more than 65␠535 tracks on each volume. They use DS1TRBAL with DS1LSTAR to represent one less than the number of tracks containing data. Thus, for extended-format data sets, DS1TRBAL does not reflect the amount of space remaining on the last track written. Programs that rely on DS1TRBAL to determine the amount of free space must first check if the data set is an extended-format data set.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014