THE MASTER FILE DIRECTORY The master file directory (MFD) is the major file management table for a
virtual disk. As mentioned earlier, it resides on cylinder 0, track 0, record 4 of each virtual disk. Six types of information contained in
the master file directory: The disk addresses of the FST entries describing user files on that
disk. A 4-byte "sentinel," which can be either FFFD or FFFF. PFPD specifies that extensions of the QMSK (described below) follow. PFPF specifies that no QMSK extensions follow. Extensions to the QMSK, if any. General information describing the status of the disk: ADTNUM -- The total number of BOO-byte blocks on the user's disk. ADTUSED ADTLEFT ADTLAST disk.
The number of blocks currently in use on the disk.
Nu.ber of blocks remaining for use (ADTNUM - ADTUSED). Relative byte address of the last record in use on the ADTCYL -- Number of cylinders on the user's disk. Unit Type --A 1-byte field describing the type of the disk: oa
for a 2314, 09 for a 3330. A bit mask called the QMSK, which keeps track of the status of the
records on disk. The QMSK is described in more detail below.
Another bit map, called the QQMSK, which is used only for 2314
disks and performs a function similar to that of QMSK. Figure 16 shows the structure of the master file directory. Figure
12 shows the relationship of the Master Pile Directory, which resides on
disk, to data blocks brought into storage for file management purposes,
for example, FSTs and chain links. KEEPING TRACK OF READ/WRITE DISK STORAGE: QMSK AND QQMSK Because large areas of disk space need not be contiguous in CMS, but are
composed of aOO-byte blocks chain-linked together, disk space management
needs to determine only the availability of blocks, not extents. The
status of the blocks on any read/write disk (which blocks are available
and which are currently in use) is stored in a table called QMSK. The
term QMSK is derived from the fact that a 2311 disk drive has four aOO-byte blocks per track. One block is a "quarter-track", or QTRK, and
a 200-byte area is a "guarter-quarter-track", or QQTRK. The bit .ask
for 2314, 2319, 3340, or 3330 records is called the QMSK, although each aOO-byte block represents less than a quarter of a track on these
devices. 2-90 IBM VM/370 System Logic and Program Determination--Volume 2
On a 2314 or 2319 disk, the blocks are actually grouped fifteen aOO-byte blocks per even/odd pair of tracks. An even/odd pair of tracks
is called a track group. On a 3330 disk, the blocks are grouped
fourteen SaO-byte blocks per track. On a 3340 disk, the blocks are
grouped into eight aOO-byte blocks per track. When the system is not in use, a user's resides on the File Directory; during a session it is maintained on disk, but also
resides in real storage. QMSK is of variable length, depending on how many cylinders exist on the disk.
Each bit is associated with a particular block on the disk. The
first bit in QMSK corresponds to the first block, the second bit to the
second block, and so forth, as shown in Figure 17. When a bit in QMSK is set to 1, it indicates that the corresponding block is in use and not available for allocation. A O-bit indicates
that the corresponding block is available.. The data blocks are referred
to by relative block numbers throughout disk space management, and the
disk I/O routine, DMSDIO, finally converts this number to a CCHHR disk
address. A table called QQMSK indicates which 200 byte segments (QQTRK) are
available for allocation and which are currently in use. QQ!SK contains 100 entries, which are used to indicate the status of up to 100 QQTRK
records. An entry in QQMSK contains either a disk address, pointing to
a QQTRK record that is available for allocation, or zero. QQ8SK is used
only for 2314 files; for 3330, 3340, and 3350, the first chain link
occupies the first 200-byte area of an aOO-byte block.
The QMSK and QQMSK tables for read-only disks are not brought into
storage, since no space allocation is done for a disk while it is
read-only. They remain, as is, on the disk until the disk is accessed
as a read/write disk. CMS Method of operation and Progra. Organization 2-91
Previous Page Next Page