Is there any way to get on Dcollect only volumes on disnew status for a storage group?
I need to get datasets that are on volumes on Disnew.
What I am doing now, is getting an ISMF report, manually removing all volume on a different status as Disnew and then with that list of volume I run the dcollect + naviquest to format sysout.
I am trying to find out a shorter way to get that list of dataset residing on Disnew volumes.
Joined: 15 Aug 2015 Posts: 607 Location: Bamberg, Germany
It should be possible to get the information from IDCAMS DCOLLECT w/ STOG and SMSDATA parameters. You would need the D and VL Records first. Do a SORT as post-processor using JOINKEYS when then condition is met in a VL record (for the Volume DISNEW) and the Volume from the D record.
If you have only one System in DFSMS defined, I would go w/ this approach.
Check for the Naviquest job SYS1.SACBCNTL(ACBJBAI4) on your system. This job runs ISMF in Batch to list volume information, which can be by volser mask or storgrp name. In the job you need to include the CFVOLST parameter to get the volume status. Then use that volume list formatted as input to list the datasets on the volumes identified.
//DASDLST EXEC ACBJBAOB,
//SYSTSIN DD *
PROFILE PREFIX(userhlq) MSGID
ISPSTART CMD(ACBQBAI4 +
SAVE SGVOL QSAVE(VOLSTAT) +
SPCDATA(Y) PHYDATA(Y) +
STORGRP(sgname) CFVOLST ) +
NEWAPPL(DGT) BATSCRW(132) BATSCRD(27) BREDIMAX(3) BDISPMAX(99999999)
You may also be able to get the DSN list using another Naviquest step as per SYS1.SACBCNTL(ACBJBAI2) but I haven't tried that to see if you can specify multiple volsers.
Thanks boths for spend time to answer my question.
Joerg, your job works excelent, I got what I was looking for.
If you sometime come to Argentina (Buenos Aires), a beer is waiting for you. . Thanks again!