I'm doing an exercise that requires building a GDG using JCL on an MVS 3.8 system.
I defined a JOB that creates an entry for the GDG ,and created a job to create GDG file.
When I run the JOB to create the GDG file I get the following error PATTERN DSCB RECORD NOT FOUND IN VTOC
I have the entry defined in the master catalog named rsm50.master
I also defined the DCB and space for the GDG
is there something wrong in my job file?
My job output from the execution
1 //RSM50C JOB ACC#,'KARAM EX9B',CLASS=A,MSGCLASS=Z, JOB 49
// REGION=2M,NOTIFY=HERC01,USER=HERC01,PASSWORD=
2 //STEP1 EXEC PGM=IEBDG
3 //SYSPRINT DD SYSOUT=*
4 //SUSUT2 DD DSN=RSM50.MASTER(+1),DISP=(NEW,CATLG,DELETE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=3120),
// SPACE=(TRK,(5,5,10)),
// UNIT=3390,VOL=SER=MVSCAT
5 //SYSIN DD DSN=RSM50.JCL.CNTL(EXDATA3),DISP=SHR
my job code to create GDG entry
000001 //RSM50B JOB ACC#,'KARAM EX9A',CLASS=A,MSGCLASS=A,
000002 // REGION=2M,NOTIFY=HERC01,USER=HERC01,PASSWORD=CUL8TR
000003 //STEP1 EXEC PGM=IDCAMS
000004 //SYSPRINT DD SYSOUT=*
000005 //SYSIN DD *
000006 DEFINE GDG(NAME(RSM50.MASTER) LIMIT(4) SCRATCH)
000007 /*
Here is a reference to an article that goes into detail on the issue.
The Model DSCB is a reference to a VTOC entry that can be used as a model for a new dataset in a GDG.
Here is a sample from IBM's documentation on creating a GDG.
Once created, you can the use this for the reference going forward. It is essentially used to grab DCB information in the absence of specified information when the new dataset is created.
//DEFGDG1 JOB ...
//STEP1 EXEC PGM=IDCAMS
//GDGMOD DD DSNAME=GDG01,DISP=(,KEEP),
// SPACE=(TRK,(0)),UNIT=DISK,VOL=SER=VSER03,
// DCB=(RECFM=FB,BLKSIZE=2000,LRECL=100)
//SYSPRINT DD SYSOUT=A
//SYSIN DD *
DEFINE GENERATIONDATAGROUP -
(NAME(GDG01) -
EMPTY -
NOSCRATCH -
LIMIT(255) )
/*
//DEFGDG2 JOB ...
//STEP1 EXEC PGM=IEFBR14
//GDGDD1 DD DSN=GDG01(+1),DISP=(NEW,CATLG),
// SPACE=(TRK,(10,5)),
// VOL=SER=VSER03,
// UNIT=DISK
//SYSPRINT DD SYSOUT=A
//SYSIN DD *
/*
To your specific case try the following when creating the GDG.
//RSM50B JOB ACC#,'KARAM EX9A',CLASS=A,MSGCLASS=A,
// REGION=2M,
// NOTIFY=HERC01,
// USER=HERC01,
// PASSWORD=xxxxxxxx
//STEP1 EXEC PGM=IDCAMS
//*
//* Note, the following DD name can be anything, it simply
//* allocates the file named which becomes the Model DSCB
//* for the GDG.
//MYGDG DD DSN=RSM50.MASTER,
// DISP=(,CATLG,DELETE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=3120),
// SPACE=(TRK,0)),
// UNIT=3390
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DEFINE GDG(NAME(RSM50.MASTER) LIMIT(4) SCRATCH)
/*
Also, you reference SUSUT2 as a DDname. I think you mean SYSUT2