You are currently on IBM Systems Media’s archival website. Click here to view our new website.

MAINFRAME > Administrator > Workload Management

Leverage DCOLLECT Data With (or Without) REXX

At most of today’s data centers, storage administrators typically leverage a variety of space management and monitoring tools. For some however, these tools can be somewhat esoteric to use. Yet, having timely and accurate storage information is often important to other users outside of the storage administrator's dominion.

What’s a storage administrator to do? One way to provide such information is to develop homegrown tools using facilities already available within the OS. Under z/OS, IBM’s Data Facility Storage Management Subsystem (DFSMS) Data Collection Facility (DCOLLECT) provides such capabilities.

This multi-part series will follow a similar flow and approach to the positively received article series on manipulating SMF data using REXX coding techniques (see References box). We show how to use REXX to process DCOLLECT data to assess your mainframe storage environment. The series will discuss:

  1. A brief introduction to DCOLLECT terminology and data structures
  2. REXX building block abstractions
  3. How to process commonly used DCOLLECT record types

The intent of part one is to review a few DCOLLECT concepts and terminology to lay out a basic framework before delving later in to REXX concepts and applied examples in subsequent installments.

DCOLLECT: An Introduction

DCOLLECT collects stored data set, volume usage and information storage controlled by DFSMShsm into a sequential file to use as input to other programs or applications that require the collected data. It’s a function of the DFSMS access method services and is documented in the IBM publication “DFSMS Access Method Services Commands” (SC23-6846), referred to as the “DCOLLECT pub” throughout this article.

Running DCOLLECT produces a snapshot of the requested storage information as it exists at that time. DCOLLECT does not monitor the information continuously. This information can then be used for accounting, planning, statistical and/or any other purposes. DCOLLECT can be used to produce measurement data on a variety of storage aspects such as:

  • Active data sets: Space usage and data set attributes for selected disk volumes or SMS storage groups
  • VSAM data sets: Detailed information that relates to VSAM data sets for selected disk volumes and storage groups
  • Disk volumes
  • Inactive data: DFSMShsm-managed data relating to inactive data management for both backed up and migrated data sets
  • Migrated data sets: Information about space utilization and the data set attributes of migrated data sets
  • Backed-up data sets: Information about space utilization and the data set’s attributes for every backed up data set
  • Capacity planning for DFSMShsm-managed data: The collection of both tape and disk capacity planning is possible for DFSMShsm-managed volumes for ML0 and ML1
  • Tape volume statistics and data, if managed by DFSMShsm
  • SMS configuration data: DCOLLECT provides information about SMS configurations that can be collected from an active control data set or a source control data set, or from the active configuration itself

Gathering DCOLLECT Data

To gather raw DCOLLECT data, one needs to submit a job control language (JCL) job that invokes the IDCAMS program to execute the DCOLLECT function. You can build your own JCL from scratch or leverage the Interactive Storage Management Facility (ISMF) panels to assist with the JCL generation.

Using Your Own JCL

Chapter 11 of the DCOLLECT pub describes the syntax of the DCOLLECT command as well as providing several JCL example scenarios. Figure 1 shows a simple example of invoking DCOLLECT to gather data for all volumes that are online. Note that the output data set used by DCOLLECT must be created prior to calling the function. It must have a physical sequential organization (PS) and a record format of variable (V) or variable blocked (VB), shown by the OFILE DD of the DCOLLECT step.

Alternatively you can use the online ISMF panels to generate JCL for the IDCAMS DCOLLECT command.

ISMF Panels

Note that to get to the ISMF DCOLLECT panels, you must be authorized as an ISMF Storage Administrator in the following steps.

Enable Storage Administrator Functionality

To get the ISMF Primary Option Menu for storage administrators (shown in Figure 2), select option 0 (ISMF Profile). Within the ISMF Profile Option Menu, select option 0 (USER MODE) and press ENTER. If you are authorized, you will get to the User Mode Entry panel, where you indicate that you want the storage administrator Primary Option Menu for all future ISMF sessions. To do this, select option 2 on the User Mode Entry panel. After changing the user mode, you must exit ISMF and then return to it to view the Primary Option Menu for Storage Administrators.

Some installations restrict end users from gaining access to the storage administrator panels to prevent unauthorized users from performing storage administrator tasks. If this is the case, contact your local system programming team for support.


If you are authorized, select option C (Data Collection – Process Data Collection Function) option on the ISMF Primary Option Menu for Storage Administrators (see Figure 2).

From here, you’ll need to fill out three DCOLLECT panels indicating what information that you’d like to gather. The first of these three panels is shown in Figure 3. The amount of DCOLLECT output generated will depend on the size of the DASD subsystem at your site and the number of active and inactive data sets.

Whether you use the ISMF panels to build your JCL or you develop your own, the job(s) created will need to run while the DFSMS environment is active.

Canned Reports: Using the ISMF Report Generator

Once you submit the jobs and have some raw DCOLLECT data to use (see Figure 2) on the ISMF Storage Administrator primary panel, you can select option G (Report Generator), which can be used to create canned reports based on the sequential file contents that DCOLLECT produces.

The report generator ships sample report types for DCOLLECT, both DFSMSdfp and DFSMShsm DCOLLECT record types. DCOLLECT provides measurement data in a sequential data set, which can be used as input to the DFSMSrmm Report Generator (see Figure 4) for creating customized reports and to other applications such as billing and report formatting.

One can choose from a number of canned reports (see Figure 5), which is fine if that’s all that you require, however you don’t have much flexibility in modifying the pre-defined formats. Power users most likely will want to develop and manage their own reports more to their preferences. Once we have the raw DCOLLECT data, how do we interpret it?

George Ng is a senior certified I/T managing consultant for IBM Systems and Technology Group Lab Services at IBM Poughkeepsie. His areas of focus include z/OS Parallel Sysplex, High Availability and Performance.

Like what you just read? To receive technical tips and articles directly in your inbox twice per month, sign up for the EXTRA e-newsletter here.



2019 Solutions Edition

A Comprehensive Online Buyer's Guide to Solutions, Services and Education.

What’s Really Driving Peak CPU Usage?

In many cases, batch processing accounts for as much as 40 percent


Leverage DCOLLECT Data With (or Without) REXX

Four-Star Advantage

The Polaris Workshop maps out a custom platform strategy

IBM Systems Magazine Subscribe Box Read Now Link Subscribe Now Link iPad App Google Play Store
Mainframe News Sign Up Today! Past News Letters