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

JCL to Backup Files to TAPE


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

New User


Joined: 01 Jun 2007
Posts: 16
Location: Chennai

PostPosted: Wed Oct 24, 2007 11:23 am
Reply with quote

hi,

I need a JCL to take the backup of thousand of Datasets to a tape.
All the dataset names starting with 'DEV.REG'.

Any kind of file will be there such as PS,VSAM,GDG files.

It would be fine to have a single step for backup, instead of taking each file one by one.

Thanks in advance,
Chinna.
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Wed Oct 24, 2007 12:22 pm
Reply with quote

chinna,

Quote:
I need a JCL to take the backup of thousand of Datasets to a tape.


You can use IEBGENER to copy datasets to TAPE.

Quote:
All the dataset names starting with 'DEV.REG'.


How are you going to get the names of all the datasets starting with those 2 qualifiers? I guess it would be better to create the JCL dynamically using REXX. It would be a cumbersome task to create the JCL manually.

Quote:
It would be fine to have a single step for backup, instead of taking each file one by one.


I don't think it can be copied in a single step. This is what i can think of

1)Have an instream PROC with a symbolic parameter for the DSN name.
2)Have different steps calling that PROC with a diff DSN name.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Wed Oct 24, 2007 12:59 pm
Reply with quote

What about dfsdss

something like..

Code:

//DUMP  EXEC  PGM=ADRDSSU,REGION=choose_a_region_size(4M)
//*                                                                         
//SYSPRINT  DD  SYSOUT=*                           
//SYSIN    DD    *                                 
 DUMP DATASET(INCLUDE(Your_high_level_qualifier.**)) -
     TOL(ENQF) ADMIN -                             
     OUTDD(SYSUT2)                                 
/*                                                 
//SYSUT2 DD UNIT=TAPE............
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Wed Oct 24, 2007 2:37 pm
Reply with quote

enrico,

As per your last post, all the datasets with that qualifier will be copied to a tape dataset specified in SYSUT2.

Is there any way to create one copy for every dataset with that qualifier?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Wed Oct 24, 2007 5:49 pm
Reply with quote

Quote:
Is there any way to create one copy for every dataset with that qualifier?


Why would You do that?
To have an output dataset for each input would mean :
1) a step for eachdataset
2) a command for each dataset

the performance would be terrible
the tape utilization horrible
the Jcl would need to dynamically prepared each time

GO FOR DFDSS !! :-)

If Your doubt is about the restore phase.. no problem there,
the include operand does not need to be a generic,
can also be a fully qualified ( specific ) dataset name

Code:

 RESTORE DATASET(INCLUDE(specific_dataset_name)) -
     TOL(ENQF) ADMIN -                             
     INDD(SYSUT1) -
    RENAMEU(New_high_level_qualifier)                                 


not sure about the syntax of the RENAMEU operand, please check the manual
or wait until my mvs is up
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Wed Oct 24, 2007 6:00 pm
Reply with quote

Quote:
Why would You do that?
To have an output dataset for each input would mean :
1) a step for eachdataset
2) a command for each dataset


In our shop, we take the backups of few datasets in TAPE. We have a seperate step for each dataset as mentioned. We are taking the backup as the retention period of the original dataset is only 5 days.

e.g if all 5 datasets are backed up in TAPE and if i want to access the first dataset alone then how should i go about it? . Please throw some light on this.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Wed Oct 24, 2007 6:06 pm
Reply with quote

Quote:
Please throw some light on this.


/smiley on
the answer my friend is blowing into the wind
/smiley off

the answer is in the smartness of DFDSS and its INCLUDE operand
look at my previous append code sample
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Wed Oct 24, 2007 6:10 pm
Reply with quote

e.s,

Thanks for the details.
Back to top
View user's profile Send private message
chinnarajr

New User


Joined: 01 Jun 2007
Posts: 16
Location: Chennai

PostPosted: Wed Oct 24, 2007 7:37 pm
Reply with quote

Hi All,
Thanks for all of your replies.
i will try each thing one by one.

Regards,
Chinna.
Back to top
View user's profile Send private message
chinnarajr

New User


Joined: 01 Jun 2007
Posts: 16
Location: Chennai

PostPosted: Thu Oct 25, 2007 4:59 pm
Reply with quote

hi,

i need the ADRDSSU input options to delete the number of datasets starting with 'DEV.REG'

thanks in advance

Regards
chinna
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Thu Oct 25, 2007 5:59 pm
Reply with quote

I do not want to sound rude, but ,
what about looking at the manual Yourself,

It is not that difficult..

to facilitate Your task here is a link to the manual

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/DGT1R210/CCONTENTS?SHELF=DGT1BK2A&DN=SC26-4929-04&DT=19990116094839
Back to top
View user's profile Send private message
chinnarajr

New User


Joined: 01 Jun 2007
Posts: 16
Location: Chennai

PostPosted: Fri Oct 26, 2007 4:58 pm
Reply with quote

hi,

The dataset backup jcl using ADRDSSU is working fine.
But i faced a little problem,when it comes to Migrated datasets.

i went through the manual but i could not find any info related to migrated datasets.

i need part of JCL which is used to dump all the datasets irrespective of migrated or normal file.

Thanks in advance.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Fri Oct 26, 2007 5:13 pm
Reply with quote

Quote:
But i faced a little problem,when it comes to Migrated datasets.


HSM recalls them uh??

You cheated :-)
You didn' t tell You had HSM ...

What is wrong in letting HSM take care of backups ???
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Sat Oct 27, 2007 5:05 pm
Reply with quote

Quote:
What is wrong in letting HSM take care of backups ???

Indeed, that is exactly what DFhsm was designed for. If you just want some short term backups let HSM do it.

Ask your storage group to setup the specific MGMTCLAS(s) and just sit back and let HSM do it all for you.
Back to top
View user's profile Send private message
chinnarajr

New User


Joined: 01 Jun 2007
Posts: 16
Location: Chennai

PostPosted: Mon Oct 29, 2007 2:45 pm
Reply with quote

hi all,

The HSM itself takes care of backups.
But my requirement is to take the backup of files in a single tape file and permanently delete the files online.

Anyway, i have got require JCL from your above replies. icon_smile.gif

Thanks,
Chinna.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Nov 01, 2007 10:42 pm
Reply with quote

What is a HSM backup file if not a single tape file ?

This sounds as if it may be an ongoing task, which is why I suggested the SMS solution.
Back to top
View user's profile Send private message
chinnaraj

New User


Joined: 01 Nov 2007
Posts: 17
Location: Chennai

PostPosted: Fri Nov 02, 2007 9:32 am
Reply with quote

hi,

The purpose is to remove the existing files from region and keep the backup in a single tape file instead of several tape file.
This is easy for maintanence.

Thanks,
Chinna.
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 3 files concatenated to 1 DFSORT/ICETOOL 2
No new posts JCL sort to compare dates in two file... DFSORT/ICETOOL 2
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts Compare 2 files and write Matched/Unm... JCL & VSAM 8
No new posts Write line by line from two files DFSORT/ICETOOL 7
Search our Forums:

Back to Top