In-use attribute

When a data set or a z/OS® UNIX file is dynamically allocated, the system assigns it the in-use attribute. You can request that the system remove the in-use attribute by requesting that the system deallocate the data set or z/OS UNIX file, or by requesting the remove-in-use function. When the system marks a dynamically allocated data set or z/OS UNIX file as “not-in-use,” it does not deallocate the resource:
  • For a data set that has been marked "not-in-use", the data set becomes eligible for use in a subsequent dynamic allocation request.
  • For an z/OS UNIX file that has been marked "not-in-use", the file cannot be reused by a subsequent allocation. Because there is no benefit to marking an z/OS UNIX file "not-in-use", rather than deallocating it, you should always deallocate z/OS UNIX files.

In addition, the system keeps track of data set use, and knows which data sets have not been in use for the longest time. These data sets might be deallocated automatically when the number of allocations for a step exceeds the control limit. See Control limit and Permanently allocated attribute for more information on when and why a data set is deallocated automatically.