Allocate file resources

Resources are those parts of the server that are required by a job or task, including main storage, devices, the processing unit, programs, files, libraries, and folders. When you write a high-level language program, you should be aware of what resources the server has allocated for each file type.

Normally, the server will perform the allocation whenever a requested operation requires it. For example, the server allocates resources for each file that is used in a program when the file is opened.

To ensure that all of the resources that are needed by a program are available before the program is run, you can use the Allocate Object (ALCOBJ) CL command in the job before you run the program. In particular, the ALCOBJ command can allocate database files and most devices.

The following operations are examples of operations that require resource allocation: