View previous topic :: View next topic
|
Author |
Message |
ignich7
New User
Joined: 02 Nov 2005 Posts: 66
|
|
|
|
Hi,
Good day to you..
I have a dataset in tape. I want to copy this dataset to DASD into different DSN. I want the target dataset to have the exact DCB and space parameters of the source dataset which is in tape. Please let me know how to do that?
Also, Once a dataset has been moved to tape, how to identify whether it is PDS or PS? If a PDS or PS dataset has been moved tape, i believe it would always be copied as PS in tape. Then how would we determine whether it is a PS or PDS when we want to copy this back to DASD?
If you have sample jcl, please share.
Thanks in advance. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Suggest you find the jcl that originally copied the dataset(s) to tape.
Use the same jcl with the input and output reversed and make any needed changes to the control statememts (if there are any). . . |
|
Back to top |
|
|
ignich7
New User
Joined: 02 Nov 2005 Posts: 66
|
|
|
|
Thanks for the quick reply Dick. But unfortunately i could not locate the original JCL which was used to copy and thats why i asked for alternatives. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
In order to copy from tape to disk, you must know how the tape was created. If the tape was created using DF/DSS (ADRDSSU), then you must use ADRDSSU to restore the data set from tape to disk. A PDS copied to tape will be in IEBCOPY unload format (which is a sequential file, usually in variable blocked spanned format). If the tape file is fixed block, then IEBGENER or SORT was used to create a copy of a disk data set. However, there's a lot of ways to build a tape and you cannot always tell from inspection how the tape was built and how to restore the tape to disk.
If your site uses a tape management tool such as CA-1, query the volume in the tape management system and you should be able to find out what program was used to create the tape. A tape map program such as on the CBT tape can help identify the tape data format. Otherwise, you may have to dump the first block or two of data from the tape to see if there's enough helpful information to figure it out. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
And I would not use the same DCB as used for tape as the blocksize may be opimum for tape, but definitely not optimum for DASD |
|
Back to top |
|
|
kalhor
New User
Joined: 20 May 2007 Posts: 31 Location: iran
|
|
|
|
Hi,
this is one way which you can do it :
************************************
//UNLOADCA JOB CLASS=A
//STEP1 EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=A
//SOURCE DD DSN=TEST.TEST222,DISP=(OLD,KEEP),
// UNIT=CART,VOL=SER=DP0079
//DESTIN DD DSN=TEST.TEST444..&TI,DISP=(NEW,KEEP),
// UNIT=3390,VOL=SER=WORK01,SPACE=(CYL,(10,2)),
// DCB=BLKSIZE=80
//SYSIN DD *
COPY OUTDD=DESTIN,INDD=SOURCE |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
kalhor wrote: |
Hi,
this is one way which you can do it :
|
And if the tape was created by FDR/DSF ???
Did you bother to read the good response from Robert ??? |
|
Back to top |
|
|
|