IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

ADRDSSU and copy from one GDG Base to Other.


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Thu May 12, 2011 8:00 pm
Reply with quote

Hi,

I need to copy one GDG-Base (GDG-Base-1) to another GDG-Base. No need to copy the generations from GDG-Base-1 to new Base.

Looked at these threads:

ibmmainframes.com/about32454.html
ibmmainframes.com/about32454.html
www.ibmmainframes.com/post-267682.html
www.ibmmainframes.com/viewtopic.php?t=54012&sid=4f6b4665ae3a762c2741a5d22bbcebe0
ibmmainframes.com/viewtopic.php?t=50364

And tried this Job:
Code:
//COPY111 EXEC PGM=ADRDSSU                     
//SYSPRINT DD SYSOUT=*                         
//SYSOUT   DD SYSOUT=*                         
//SYSIN DD *                                   
  COPY DATASET(INCLUDE(HLQ.SOME.GDG))  -       
     REPLACEUNCONDITIONAL (HLQ1.SOME.GDG) -   
     CATALOG TGTGDS(ACTIVE)                 - 
      ALLDATA(*) ALLEXCP                       
/*                                             
however got an error, shown below:
Code:
PAGE 0001     5695-DF175  DFSMSDSS V1R11.0 DATA SET SERVICES     2011.132 08:38
  COPY DATASET(INCLUDE(HLQ.SOME.GDG))  -                                   
     REPLACEUNCONDITIONAL (HLQ1.SOME.GDG) -                                   
     CATALOG TGTGDS(ACTIVE)                 -                                   
      ALLDATA(*) ALLEXCP                                                       
ADR101I (R/I)-RI01 (01), TASKID 001 HAS BEEN ASSIGNED TO COMMAND 'COPY '       
ADR109I (R/I)-RI01 (01), 2011.132 08:38:56 INITIAL SCAN OF USER CONTROL STATEMEN
ADR124E (001)-RI01 (02), DELIMITER '(' IS NOT PROPERLY PRECEDED BY A CONSTANT OR
ADR131E (001)-RI03 (01), ABOVE TEXT BYPASSED UNTIL NEXT COMMAND                 
ADR017E (001)-CLTSK(01), 2011.132 08:38:56 TASK NOT SCHEDULED DUE TO ERROR. TASK
ADR012I (SCH)-DSSU (01), 2011.132 08:38:56 DFSMSDSS PROCESSING COMPLETE. HIGHEST
                         SYNTAX                                                 
                         TASK    001                                           


Also used:

Code:
COPY DATASET(INCLUDE(HLQ.SOME.GDG))                     - 
    RENAMEUNCONDITIONAL((HLQ1.SOME.GDG)) -                     
    REPLACEUNCONDITIONAL CATALOG TGTGDS(ACTIVE)              - 
    ALLDATA(*) ALLEXCP                                         
But it also ends in error:

Code:
ADR101I (R/I)-RI01 (01), TASKID 001 HAS BEEN ASSIGNED TO COMMAND 'COPY '       
ADR109I (R/I)-RI01 (01), 2011.132 08:03:14 INITIAL SCAN OF USER CONTROL STATEMEN
ADR141E (001)-RI03 (03), ERROR IN DATA SET NAME BCST.FIRST.GDG                 
ADR017E (001)-CLTSK(01), 2011.132 08:03:14 TASK NOT SCHEDULED DUE TO ERROR. TASK
ADR012I (SCH)-DSSU (01), 2011.132 08:03:14 DFSMSDSS PROCESSING COMPLETE. HIGHEST
                         SYNTAX                                                 
                         TASK    001                                           


Looked in to the manuals for ADRDSSU, but was not exactly sure - what to look for...

Can someone please assist me in this.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu May 12, 2011 8:04 pm
Reply with quote

Can't do it with Dfdss (ADRDSSU).
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Thu May 12, 2011 8:08 pm
Reply with quote

I see - so I picked up a wrong tool...so is there some other way round for this?
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Thu May 12, 2011 8:48 pm
Reply with quote

A GDG base entry has so little information in it that it's difficult to imagine what you are trying to accomplish. In copying one base to another, what information do you expect to be copied?
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Thu May 12, 2011 9:29 pm
Reply with quote

Nothing. They are creating a new LPAR for this they need to copy some GDGs from existing LPAR to another.

For now, I used an IDCAMS job with around 100 steps, each defining a new GDG - but the short coming is, you have to run the LISTCAT for the existign GDGs to see teh attibutes for new GDGs. I know there is more work of this nature coming my way, so was thinking if I can eliminate manual stuff of checking the the attibutes.
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Thu May 12, 2011 10:13 pm
Reply with quote

icon_rolleyes.gif So, do you have (and are authorized to use) Rexx in the source environment? Do you have Open Software's REXXTOOLS package? Are the source and target LPARs JES2 or JES3?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Thu May 12, 2011 11:56 pm
Reply with quote

look at
connelley.org/Coding_Examples/vclone.html

should not be a problem to modify it to CLONE all the entities for which the catalog contains the required info
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Fri May 13, 2011 12:45 pm
Reply with quote

Akatsukami wrote:
So, do you have (and are authorized to use) Rexx in the source environment? Do you have Open Software's REXXTOOLS package?
REXX I can use, in the source environment though, have not tried the open source REXX ever at this shop.
Quote:
Are the source and target LPARs JES2 or JES3?
They are JES2.

Well, I'm an End-user, an appliction Developer - so do not have too much rights to choose the tools. And, at times, I wonder -- are the ones in charge, really have the mindset they need for such tasks! Well, to start with - when I asked my lead - do you want me to create the Model DSCB as well for these newly created GDGs, though I know - the new LPAR is going to be SMS managed, however, I know they are going to use , possibly, some non-SMSed managed volumes as well..so tell me please.

She: DCB is not needed.
Me: I said, DSCB Model for GDG not DCB.
She: A long pose...

Today: She is still not talking to me.
Back to top
View user's profile Send private message
nevilh

Active User


Joined: 01 Sep 2006
Posts: 262

PostPosted: Fri May 13, 2011 2:48 pm
Reply with quote

GDG base is not a datset as such it is just a catalog entry and as such cannot be copied. There is a good chance that lying around your system somewhere there is an IBM supplied program called MCNVTCAT this can take the output from a LISTC command and rebuild the DEFINE statements . In the past sysprogs used this program to rebuild a Master Catalog. The program will create
members in a PDS one of which will be called GDG, this will contain all the statements you require. Be aware that if this program runs on a a version of z/OS later than 1.7 the output should be carefully checked as LISTC changed with 1.8
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Fri May 13, 2011 3:32 pm
Reply with quote

RE: MCNVTCAT

publib.boulder.ibm.com/tividd/td/ITACMzOS/SC23-7973-00/en_US/HTML/ckm_ug87.htm
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Fri May 13, 2011 5:06 pm
Reply with quote

Click HERE and look at some code that will get the attributes of any given GDG bases.

You can then tailor the output to produce the GDG define statements to be processed on the other LPAR.
Back to top
View user's profile Send private message
Pete Wilson

Active Member


Joined: 31 Dec 2009
Posts: 580
Location: London

PostPosted: Tue May 17, 2011 2:27 pm
Reply with quote

Check if they have FDR, the FDREPORT program can generate define GDG cards based on your existing GDG's attributes:
e.g.
//GDGPUNCH EXEC PGM=FDREPORT
//SYSOUT DD SYSOUT=0
//SYSUDUMP DD SYSOUT=0
//SYSPRINT DD SYSOUT=0
//SYSPUNCH DD DSN=YOUR.PUNCH.FILE,DISP=(,CATLG),
// SPACE=(TRK,(5,5),RLSE)
//ABRMAP DD DSN=&&LIST,DISP=(,PASS),
// SPACE=(TRK,(15,15),RLSE)
//ABRSUM DD SYSOUT=0
//SORTLIB DD DSN=SYS1.SORTLIB,DISP=SHR
//SYSUT3 DD DSN=&&TEMP1,UNIT=SYSDA,
// DISP=(,PASS),SPACE=(CYL,(25,25))
//SYSIN DD *
REPORT FIELD=(GDGBASE,GDGLIMIT,GDGFLAGS)
XS XDSN=HLQ1.**
XS XDSN=HLQ2.**
SORT FIELD=(GDGBASE)
PUNCH FDRLIB=MASK
PRINT DATATYPE=CATALOG,RPTYPE=SELPCH,
ENABLE=(FASTPATH,GDGBASEONLY,ALLFILTER)
//MASK DD *
DEF GDG(NAME(<GDGBASE>) LIM(<GDGLIMIT>) <GDGFLAGS>
//*
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Tue May 17, 2011 8:48 pm
Reply with quote

Quote:
Today: She is still not talking to me.

Wish this worked several of the places i've been.

Many of these darlin's with delusions of adequacy yammer on and on and on. . . icon_wink.gif

d
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Tue May 17, 2011 9:24 pm
Reply with quote

nevilh wrote:
GDG base is not a datset as such it is just a catalog entry and as such cannot be copied. There is a good chance that lying around your system somewhere there is an IBM supplied program called MCNVTCAT this can take the output from a LISTC command and rebuild the DEFINE statements . In the past sysprogs used this program to rebuild a Master Catalog. The program will create
members in a PDS one of which will be called GDG, this will contain all the statements you require. Be aware that if this program runs on a a version of z/OS later than 1.7 the output should be carefully checked as LISTC changed with 1.8
Thanks nevilh.

Thanks for coining out the word "MCNVTCAT", I had been reading about this since the day you put your message here. However, not having much time on my hands to do lot of reading but I won't leave it. Looks like, it'll give me what I'm looking for.

Thanks 'gain and have a good one, icon_smile.gif
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Tue May 17, 2011 9:25 pm
Reply with quote

dbzTHEdinosauer wrote:
RE: MCNVTCAT

publib.boulder.ibm.com/tividd/td/ITACMzOS/SC23-7973-00/en_US/HTML/ckm_ug87.htm
Thank You Dick, trying my hands on creating a Job which will do what i need. If I get successful, will post back. Thanks for the link.

Take care,
Back to top
View user's profile Send private message
DB2 Guy

New User


Joined: 28 Oct 2008
Posts: 98
Location: Cubicle

PostPosted: Tue May 17, 2011 9:30 pm
Reply with quote

expat wrote:
Click HERE and look at some code that will get the attributes of any given GDG bases.

You can then tailor the output to produce the GDG define statements to be processed on the other LPAR.
Thanks expat. I'm not good with REXX but has kept your code for reference. To do the same thing, actually, used a combination of LISTCAT and Sort, shown below:

Code:
//S1 EXEC PGM=IKJEFT01                                   
//SYSTSPRT DD DSN=&&L,                                   
// DISP=(,PASS),                                         
// SPACE=(CYL,(1,1),RLSE),                               
// DCB=(LRECL=80,RECFM=FB,BLKSIZE=0)                     
//SYSTSIN DD *                                           
  LISTCAT ENT('HLQ.MLQ.LLQ.GDG') ALL             
  LISTCAT ENT('HLQ1.MLQ1.LLQ1.GDG1') ALL       
//*                                                     
//S2 EXEC PGM=ICEMAN                                     
//SYSOUT DD SYSOUT=*                                     
//SORTIN DD DSN=&&L,DISP=(OLD,PASS)                     
//SORTOUT DD SYSOUT=*                                   
//SYSIN DD *                                             
  OPTION COPY                                           
  INCLUDE COND=(1,8,CH,EQ,C'GDG BASE',OR,               
  8,5,CH,EQ,C'LIMIT')                                   
  INREC IFTHEN=(WHEN=GROUP,BEGIN=(1,8,CH,EQ,C'GDG BASE'),
  PUSH=(65:17,36),RECORDS=2)                             
  OUTFIL INCLUDE=(8,5,CH,EQ,C'LIMIT'),                     
  BUILD=(65,36,C' HAS A LIMIT OF: ',                       
  17,15,ZD,M11,LENGTH=3,60:37,22)                         
/*                                                         
//*                                                       

SORTOUT:

Code:
IQQ000.BONE.EP4.DUFLOG               HAS A LIMIT OF: 015   NOSCRATCH        NOEMP
IQQ000.BONE.EP4.REPOSIT.TABLE        HAS A LIMIT OF: 005   NOSCRATCH        NOEMP
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts VB to VB copy - Full length reached SYNCSORT 8
No new posts Need COBOL COPY Help in MVS Environment COBOL Programming 4
No new posts Issue after ISPF copy to Linklist Lib... TSO/ISPF 1
No new posts DB2 Table - Image copy unload IBM Tools 2
No new posts How to copy the -1 version of a membe... TSO/ISPF 4
Search our Forums:

Back to Top