View previous topic :: View next topic
|
Author |
Message |
autobox
New User
Joined: 19 Aug 2005 Posts: 51
|
|
|
|
Dear all:
I want to backup files on tape using GDG, but how can i create a GDG on tape?
I mean that, if we create a GDG, the two parts (the GDG and it's entry(namely MODEL)) of it must reside on the same volume so that the catalog can find the entry of the GDG, as for a tape, how can i define the GDG and it's MODEL in the catalog of the tape?
Thanks a lot! |
|
Back to top |
|
|
Hanfur
Active User
Joined: 21 Jun 2006 Posts: 104
|
|
|
|
Auto,
Use IDCAMS for this as given below..
//STEP01 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//MODEL DD DSNAME=XXXPROD.GDGMODEL,
// DISP=(NEW,KEEP),
// SPACE=(TRK,0),
// DCB=(DSORG=PS,RECFM=U)
//SYSIN DD *
DEFINE GDG ( NAME (AETPROD.TAPE.BJCVVSB) -
LIMIT(7) -
NOEMPTY -
SCRATCH )
/*
Use utlitlites like ADRDSSU as given below for back up.The following JCl would put all my VSAM files in to a single version of GDG in Tape.
//STEP02 EXEC PGM=ADRDSSU
//COPYOUT DD DSN=XXX&ENV..TAPE.PRODMM(+1),
// UNIT=AUTO1,VOL=(,,,99),
// DISP=(,CATLG,DELETE),LIKE=AET&ENV..GDGMODEL,RECFM=U,
//SYSIN DD DSN=AET&ENV..DY722.CONTROL(ACVPRDB),
// DISP=SHR
----+----1----+----2----+----3----+----4----+----5----+----6----+--
DUMP DS(INCLUDE( -
XXXPROD.ACV.ACNT.FILE -
XXXPROD.ACV.ACCT.SUM.FILE -
XXXPROD.ACV.AUX.HIST.FILE -
XXXPROD.ACV.B
/*
you may have to tailor it accoding to your need...
-Han. |
|
Back to top |
|
|
autobox
New User
Joined: 19 Aug 2005 Posts: 51
|
|
|
|
Hi,
I tried to create a new generation of GDG on tape, but got the following error message: "IEF217I IBMUSERA SETP1 SYSUT2 - VOLUME CONTAINING PATTERN DSCB NOT MOUNTED".
I used the "DCB=(MODEL_NAME)" to specify the model data set, but it seems like that the system can not find the mode data set.
How to find the model data set?
Thanks a lot! |
|
Back to top |
|
|
sasman
New User
Joined: 18 Jul 2006 Posts: 5
|
|
|
|
If you define the gdg using something like this example then the modelgdg will be found automatically:
//STEP1 EXEC PGM=IDCAMS,TIME=5
//SYSPRINT DD SYSOUT=*
//DSCB1 DD DSN=xxxxxxxx,DISP=SHR <= xxxxxxxx is first node
//DD1 DD DSN=xxxxxxxx.rest.of.name,DISP=(,KEEP),
// UNIT=3390,VOL=REF=*.DSCB1,
// SPACE=(TRK,0)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
DEFINE GDG (NAME(xxxxxxxx.rest.of.name) -
LIMIT(2) SCRATCH NOEMPTY)
This example puts the modelgdg on the DASD volume where the catalog that the gdg is being defined to is located. It is nothing more than a dscb entry on the DASD volume. Then you don't need to use a DSCB=MODELGDG statement in the JCL that you use to create the tape output. Maybe something like this:
//TAPE0 DD DISP=(,CATLG,DELETE),
// UNIT=TAPE,LABEL=(1,SL),
// DCB=(LRECL=xx,RECFM=yy,BLKSIZE=0),
// DSN=xxxxxxxx.rest.of.name(+1)
Just make sure you have the VTOC on the DASD volume large enough for the DSCB entries for all of the GDGs defined. |
|
Back to top |
|
|
Hanfur
Active User
Joined: 21 Jun 2006 Posts: 104
|
|
|
|
Auto,
If your shop have a model use that while creating a GDG versions on Tape.Otherwsie create a model as mentioned by sasman and refer it in while creating GDG versions on Tape.
-Han. |
|
Back to top |
|
|
autobox
New User
Joined: 19 Aug 2005 Posts: 51
|
|
|
|
Thank you all for your great help!
But I still wonder:
1. A GDG must has it's MODEL?
2. If the answer of question 2 is yes, a GDG new generation and it's MODEL must reside on the same volume or catalog?
3. What on earth is the difference between GDG on DASD and GDG on TAPE to define the GDG and it's MODEL?
Thanks! |
|
Back to top |
|
|
autobox
New User
Joined: 19 Aug 2005 Posts: 51
|
|
|
|
[quote="autobox"]
2. If the answer of question 2 is yes, a GDG new generation and it's MODEL must reside on the same volume or catalog?
quote]
2. If the answer of question 1 is yes, a GDG new generation and it's MODEL must reside on the same volume or catalog? |
|
Back to top |
|
|
sasman
New User
Joined: 18 Jul 2006 Posts: 5
|
|
|
|
A gdg must have a model. The model does not have to reside on the same volume as the Catalog, but it must have a model. If the model does not reside on the same volume as the catalog where the GDG is defined, you MUST specify in your JCL something like this
DCB=(gdgmodel,other dcb info) where gdgmodel points to a catalogued dataset used for a gdg model.
The GDG dataset (not the same thing as the GDG definition in the catalog or the model dscb) can reside anywhere you decide to put it such as on DASD or TAPE and you specify that in your UNIT=xxxxx parameter. |
|
Back to top |
|
|
sasman
New User
Joined: 18 Jul 2006 Posts: 5
|
|
|
|
One thing that may be causing some problem in your understanding is that the generation of the GDG that you are creating is nothing more than a regular dataset that is defined to the catalog in such a way that you can group the datasets (all the different generations) together for management purposes. The GDG definition is just that, a definition of a way to group datasets using generations. |
|
Back to top |
|
|
|