Previous Topic: Advanced TopicsNext Topic: How You Identify Resources on ENQ and RESERVE Requests


z/OS Resource Serialization

z/OS provides the ENQ facility and the RESERVE facility to serialize access to resources. An ENQ macro specifies a resource name. A RESERVE macro specifies a resource name and a DASD device. The DASD device is specified by the UCB=keyword of the RESERVE macro.

When a task needs access to a resource, z/OS (or the task) issues an ENQ request to tell other tasks which resource is needed and what type of access the task needs. Tasks can request two types of access to a resource:

z/OS makes a requester wait when:

z/OS places the task that currently holds the resource at the top of the queue. Subsequent tasks are listed on a first-come, first-serve basis. z/OS makes subsequent tasks wait until they can obtain the type of access they need for that resource.