How data is stored on systems before z/OS V1R13

On systems before z/OS® V1R13, zFS can store data in fragmented blocks to conserve disk space. On these systems, each small file does not need to use a full 8-KB block of disk space. However, as a result of this method of storing data, a problem can occur when data is stored using zFS. That is, the amount of free space that is displayed by the z/OS UNIX df command might not give the entire picture of free space. The df -k command displays free space in a file system in 1-KB units. In zFS, this space is a combination of full 8-KB blocks plus the free 1-KB fragments in fragmented blocks. For example, as Figure 1 shows, if there were two 8-KB blocks and twenty 1-KB blocks that are left, df -k reports 36 KB available.
Figure 1. Disk space allocation example 1
Graphic showing free, full, and fragmented 8K blocks on systems before z/OS V1R13
Because this is a combination of 8-KB blocks and 1-KB blocks, it is possible that many 1-KB blocks are available but no 8-KB blocks remain. As shown in Figure 2 for example, if there were 0 8-KB blocks left and 20 1-KB blocks available, df -k reports 20 KB available. If you try to create a 10-KB file, you might think that there is plenty of space. However, a 10-KB file is larger than 7 KB, and therefore uses full 8 KB blocks. Because there are no 8-KB blocks available, there is no room for a 10 KB file, even though there is 20-KB free space.
Figure 2. Disk space allocation example 2
Graphic showing a combination of 8-KB blocks and 1-KB blocks with many 1-KB blocks available but no 8-KB blocks on systems before z/OS V1R13

Other rules can further restrict how free space is used. A file that is 7 KB must be stored in 7 contiguous fragments. Therefore, even if there is 20 KB available in the file system, if there is no fragmented block with 7 contiguous 1-KB blocks available, the file system will report that there is no space for the file. Also, a file that is stored as fragments cannot share the same 8-KB block as a directory stored as fragments.

Fragments save disk space, but make space allocation more complicated. To provide the maximum options for space allocation, you need to have free 8-KB blocks. The aggrfull option of MOUNT and IOEFSPRM indicates the number of free 8-KB blocks. If you are out of 8-KB blocks, you will be limited in how much additional file space that can be allocated in the file system. You should grow the aggregate or allow it to be dynamically extended.

When a zFS compatibility mode aggregate becomes full, you can make more space available. This happens automatically if you have specified aggrgrow for the aggregate and you specified a secondary allocation size when you defined the aggregate (that is, the VSAM linear data set). You can increase the size of the aggregate with the zfsadm grow command. Of course, in each of these cases, you must have space available on the volume to extend into. Or, you might be able to erase some files from the file system to free up some space.

Note that because of the difference between how HFS and zFS manage disk space and block sizes, certain z/OS UNIX commands, such as df and du might display information differently.