On a PC (Windows), this usually means your hard drive is full. But on a Mainframe (z/OS), the logic is more subtle: the disk isn't necessarily full, but you have exceeded the space that was allocated to you.
Here's how to understand and solve this space allocation problem, based on advice from forum experts.
1. Diagnosis: Space Allocation on Mainframe
Unlike Windows where a file grows as long as there is space, the Mainframe requires that space be defined in advance (pre-allocated) via Extents.
The system works in two stages:
Primary Allocation: A large block of space reserved at the start of the job.
Secondary Allocations: Small additional blocks that the system fetches if the primary block is full (usually limited to 15 or 16 extensions).
Before asking the administration for more disk space, try to reduce the size of your data. The expert David suggests enabling binary compression. On large data with text or repetitions, this can reduce the size by 50% to 80%.
/* Compression activée pour cette table spécifique */
data WORK.A (compress=yes);
set DB2.GRANDE_TABLE;
run;
/* OU activée globalement pour toute la session */
options compress=yes;
1
/* Compression activée pour cette table spécifique */
2
DATA WORK.A (compress=yes);
3
SET DB2.GRANDE_TABLE;
4
RUN;
5
6
/* OU activée globalement pour toute la session */
7
options compress=yes;
Note: This slightly increases CPU usage, but significantly reduces I/O (Input/Output), which is often beneficial on Mainframe.
500: Size of the Primary allocation (in cylinders or tracks depending on the site configuration).
200: Size of the Secondary allocation.
The expert's calculation: David recommends a "90/10" strategy:
Estimate the final total size.
Allocate 90% of this size as Primary.
Allocate 10% as Secondary.
This avoids fragmentation and reduces the risk of late failure if the disk is physically fragmented.
4. Solution 3: The Heavy Artillery (Spanning Volumes)
Sometimes, a single physical disk (DASD volume) is not enough to hold your temporary table, even using all the available space (about 4300 cylinders on the old 3390 models).
The expert Chuck explains how to extend the WORK library across multiple physical volumes. This requires modifying the JCL to concatenate several disk allocations.
Note: This technique is reserved for advanced users who have access to detailed JCL configuration.
If you encounter the "File Full" error on Mainframe:
Compress (COMPRESS=YES): It's simple and often sufficient.
Increase the allocation (WORK='Prim Sec'): Request more cylinders in your JCL.
Check the SMS: Sometimes, the storage class (Storage Management Subsystem) automatically limits file sizes. In this case, you'll need to contact the system administrator.
Aviso importante
Los códigos y ejemplos proporcionados en WeAreCAS.eu son con fines educativos. Es imperativo no copiarlos y pegarlos ciegamente en sus entornos de producción. El mejor enfoque es comprender la lógica antes de aplicarla. Recomendamos encarecidamente probar estos scripts en un entorno de prueba (Sandbox/Dev). WeAreCAS no acepta ninguna responsabilidad por cualquier impacto o pérdida de datos en sus sistemas.
SAS y todos los demás nombres de productos o servicios de SAS Institute Inc. son marcas registradas o marcas comerciales de SAS Institute Inc. en los EE. UU. y otros países. ® indica registro en los EE. UU. WeAreCAS es un sitio comunitario independiente y no está afiliado a SAS Institute Inc.
Este sitio utiliza cookies técnicas y analíticas para mejorar su experiencia.
Saber más.