Sie sind auf Seite 1von 36

Level II

Knowledge of Dataset Structure

Physical Sequential (PS) It contains records that are stored in physical order. Its just like a file in other file system. New records can be appended to the existing data. Partitioned Data set (PDS) It contains a group of sequentially organized member. Each member indicates an individual data set, contains data. Partitioned Data set Extended (PDSE) It is similar to that of a PDS The main advantage of a PDSE is that it automatically reuses space within the data set. Virtual Storage Access Method (VSAM) VSAM is an access method service used to organize data and maintain information about the data in a catalog. It arranges records by an index key, relative record or relative byte address. It is used for direct or sequential processing of fixed-length and variable length records on DASD. The two major parts of VSAM are, Catalog Management it contains information about the dataset Record Management - it can be used to organize records into four types of data sets, they are, KSDS Key sequenced Data set ESDS Entry sequenced Data set LDS Linear Data set RRDS Relative Record Data set KSDS A KSDS VSAM data set contains records in order by a key field and can be accessed by the key or by a relative byte address. The key contains a unique value, such as an employee number or part number. ESDS An ESDS VSAM data set contains records in the order in which they were entered and can only be accessed by relative byte address. An ESDS is similar to a sequential data set. LDS An LDS VSAM data set contains data that can be accessed as byte-addressable strings in virtual storage. A linear data set does not have imbedded control information that other VSAM data sets hold.

Level II RRDS

Knowledge of Dataset Structure

An RRDS VSAM data set contains records in order by relative-record number and can only be accessed by this number. Relative records can be fixed-length or variablelength. VSAM Data set components A component is an individual part of a VSAM data set. Each component has a name, and an entry in catalog and VTOC. The two components includes, Data component Index component Data component All VSAM data set has a data component. It is a part of VSAM data set which contains the data records. Index component It is a collection of records containing data keys and pointers (relative byte address). With the help of index, a vsam is able to retrieve logical records from a data component. VSAM Physical Record and Logical Record Physical Record: A Physical record is device independent When a data set is defined, VSAM calculates the physical record size. All physical record contains the same length. Physical record can also be called as physical block. It can also contain control information along with logical record in a physical record. Logical Record: It is a unit of information used to store data in VSAM data set. It is designed by, an application programmer. A logical record can be of a fixed size or variable size. VSAM Control Interval CI A control interval is usually formed by one or more physical record. CI is a contiguous area of direct access storage that VSAM uses to store data records and control information that describes the records. It is a unit of information that VSAM transfers between storage device and the processor during one I/O operation. Whenever a record is retrieved from direct access storage, the entire CI containing the record is read into a VSAM I/O buffer in virtual storage. VSAM Control Area CA A CA is formed by two or more CIs put together into fixed-length contiguous areas of direct access storage. A VSAM data set can be composed of one or more control areas. The minimum size of a CA is one track. The CA size is implicitly defined when you specify the size of a data set at data set definition.

Level II Generation Data Group

Knowledge of Dataset Structure

Generation of related data set or successive updates can be cataloged in to a single GDG. Each data set in a gdg is referred to a generation data set (GDS). Generation data sets can be sequential, PDS, direct, or indexed sequential. Each GDG is represented by a GDG base entry. The GDG base is a construct that exists only in a user catalog; it does not exist as a data set on any volume. The GDG base is used to maintain the generation data sets. The main advantage of using GDG is, All of the data sets in the group can be referred to by a common name The operating system is able to keep the generations in chronological order (arranged in some ordering means). Outdated or obsolete generations can be automatically deleted by the operating system.

Indexed Sequential Access Method (ISAM) ISAM refers to two access methods: Basic indexed sequential access method (BISAM) Queued indexed sequential access method (QISAM). Data sets that ISAM processes are called indexed sequential data sets. ISAM arranges records in sequence by key fields, and retrieves records by key. The structure of multilevel indexes in ISAM is similar to the structure of indexes in VSAM. Object Access Method (OAM) OAM processes very large named byte streams (objects) that have no record boundary or other internal orientation. These objects can be recorded in a DB2 data base or on an optical storage volume.

Level II Types of DASD


Types of DASD and tapes

Traditional DASD 3380 Models J, E, K 3390 Models 1, 2, 3, 9 DASD based on RAID technology RAMAC Array RAMAC Virtual Array (RVA) Enterprise Storage Server (ESS)

DASD capacity
Physical characteristics 3380-J 3380-E 3380-K 3390-1 3390-2 3390-3 3390-9

Data Cyl/Device Track/Cyl Bytes/Trk Bytes/Cylinder MB/Device

855 15 47476 712140 630

1770 15 47476 712140 1260

2655 15 47476 712140 1890

113 15 56664 849960 946

2226 15 56664 849960 1892

3339 15 56664 849960 2838

10017 15 56664 849960 8514

Large volume support


A "large volume" is larger than a 3390-9 The largest possible volume has 32760 (3390) cylinders That would be a "3390-27" if it had its own device type Almost 28 GB

Level II

Types of DASD and tapes

TAPE CAPACITY The capacity of a tape depends on the device type that is recording it. 3480 and 3490 tapes are physically the same cartridges. The IBM 3590 and 3592 high performance cartridge tape is not compatible with the 3480, 3490, or 3490E drives. 3490 units can read 3480 cartridges, but cannot record as a 3480, and 3480 units cannot read or write as a 3490. Product IBM 3480 IBM 3490 IBM 3490E IBM 3490E IBM 3590 Magstar IBM 3590E Magstar IBM 3590E Magstar XL Cartridge IBM 3592 TotalStorage Enterprise Tape Drive Capacity (Mb) 200 200 400 800 10,000 (uncompacted) 20,000 (uncompacted) 20,000/40,000 (dependent on Model B or E) 300,000 (for high capacity requirements) or 60,000 (for fast data access requirements) Transfer Rate (KB/S) 3,000 4,500 9,000 9,000 9,000 (uncompacted) 14,000 14,000 40,000

Level II Skills

Basic JCL Coding

JCL is a Job Control Language It is a means of communication between a program (COBOL, Assembler) and the MVS operating system. With out JCL your program will not run on IBM mainframe. Components of JCL Statements: The components includes, // Name Field Operation Field Operand Description Job Identification Program Identification INPUT/OUTPUT File Identification // // // // // NAME JOB1 STEP01 INPUT01 PRINT01 Operation JOB EXEC DD DD Operand Parameter PGM= DSN= DISP=(--,--,--) SYSOUT=A

The above described table contains the general structure for a JCL. JOB STATEMENT All JCL must contain a JOB statement. A general Job statement for a JCL look like this, // JOB Job Name Positional Parameter Keyword Parameter

Positional Parameter Positional Parameter includes Job Accounting Information Parameter Programmer Name Parameter Job Accounting Information Parameter It identifies the account number which will be billed for the CPU time utilized on the mainframe. e.g. //JOB1 JOB (A123, DEPT1) Programmer Name Parameter It identifies the name of a person or the information related to the job being submitted. e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx Keyword Parameter The keyword parameter must follow the positional parameter. Keyword Parameter includes, CLASS PRTY

MSGCLASS MSGLEVEL TYPRUN Level II Skills Basic JCL Coding

CLASS Parameter It identifies the nature of the job that is to be submitted. The job class is used to identify the characteristics (long-running job, short running job, utilizes heavy resources) to the operating system. Syntax: CLASS=job class Where, job class is any character between A-z and 0-9. e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A PRTY Parameter A job with higher number will take precedence over a job with lower priority. If both jobs contain same job class and priority then it will be executed in the order the job has been submitted. Syntax: PRTY=9 e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6 MSGCLASS Parameter It determines the output device to which system messages and JCL messages are written. Syntax: MSGCLASS = output class name. Where, output class-name is any character between A-z and 0-9. e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6, MSGCLASS = A MSGLEVEL Parameter It specifies the JCL and allocation messages that will be recorded on the output device As a JCL is submitted, all kinds of messages are generated by the system. Log message indicating job name, user name etc. are routed to output device. JCL statement comprising that job is output. Messages related to the execution of the job will be output The output of the program being executed is output Syntax: MSGLEVEL = (statement, messages) Where statements can be 0, 1 or 2 and messages can be 0 or 1 Statement 0 Indicates the messages related to the job statement. Statement 1 Indicates all JCL in the job being submitted. Statement 2 Indicates only the input JCL statements being printed. Message 0 indicates only allocation/termination message if the job terminates abnormally. Message 1 Indicates only allocation/termination message if the job terminates abnormally. e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6, MSGCLASS = A, MSGLELEL (0, 0) TYPRUN Parameter It is used to specify the type of job processing such as, Whether a job is to be held until it is released Whether its execution is to be suppressed altogether

Syntax: TYPRUN = HOLD or SCAN HOLD Results in the job bring held until further notice. It is helpful when a job utilizes a lot of resources SCAN The JCL is being scanned for syntax errors and reports them to the output media e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6, MSGCLASS = A, MSGLELEL (0, 0), TYPRUN=SCAN Level II Basic JCL Coding Skills EXEC STATEMENT The EXEC statement is the first statement of each job step. Job step A job step is a unit of work that is submitted to the operating system in the form of a collection of JCL statements. A job can have many EXEC statements Syntax: // Step-name Step-name EXEC PGM = program-name, Keyword Parameter

It is the name assigned to the job step It is optional field, since system messages reference step-names it is recommended to mention a unique meaningful name for each step. Syntax: // STEP01 EXEC PGM= program-name Step name is mandatory when a reference is made to a step that has been previously executed. It is the execute statement It is the name of the program that is to be executed, It is a positional parameter Syntax: // STEP01 EXEC PGM= program-name

EXEC Program name

Keyword parameter The keyword parameter includes, ACCT PARM ADDRSPC DPRTY PERFORM RD ACCT Parameter It is used to supply accounting information for the job step e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS) PARM Parameter It is used to supply information to a program as it executes. Syntax: PARM = value (value ranges from 0-100) e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS), PARM=PRINT ADDRSPC Parameter It is used to indicate to the system that the job step is to use either virtual or real storage. Syntax: ADDRSPC = VIRT or REAL

e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS), PARM=PRINT, ADDRSPC = REAL DPRTY Parameter It is used to assign a dispatching priority to the job step. It is used by the system to determine the order in which tasks are to be executed. Syntax: DPRTY = (value1, value2) Value1 and Value2 range 0-15 Level II Basic JCL Coding Skills DPRTY can be computed as, DPRTY = (value1)*16 + value2 e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS), PARM=PRINT, ADDRSPC = REAL, DPRTY= (10, 2) In the above e.g. DPRTY = 162 PERFORM Parameter It is used to specify the performance group for the job step. It determines the rate at which the job steps in a program have access to system resources. Syntax: PERFORM = n where n is the number from 1 to 999 e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS), PARM=PRINT, ADDRSPC = REAL, DPRTY= (10, 2), PERFORM = 10 RD (Restart Definition) Parameter It is used to specify automatic restart of a job if it abends. Syntax: RD=R Restart RD=NR No automatic restart RD=NC No checkpoint RD=RNC Restart with No checkpoint Checkpoint It is taken by the system to record the status of a program as it executes. The advantage of checkpoint is that, if a job abends, it can be restarted from the last successful checkpoint, rather than beginning from the first. e.g. // Step-name EXEC PGM = PROGRAM2, ACCT = (123, SS), PARM=PRINT, ADDRSPC = REAL, DPRTY= (10, 2), RD=R Parameter Applies to both JOB and EXEC Statement The parameters that can be coded both in JOB and EXEC statement are COND REGION TIME COND Parameter Each step within a job sends a return code to the system upon completion. This is called condition code. Condition code 00 implies successful completion of a job step. Condition code other than 00 implies unsuccessful execution of a job step Syntax: COND=(comparison-code, condition) Where comparison code is a numeric value (0-4095) Condition is GT, GE, LT, LE, EQ, NE GT Greater Than

GE LT LE EQ NE

Greater Than or equal to Less than Less than or equal to Equal to Not equal to

Condition Parameter specified in JOB statement implies to the entire job step. e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6, MSGCLASS = A, COND=(4,LT) Level II Basic JCL Coding Skills //STEP1 EXEC PGM=Program1 // STEP2 EXEC PGM=Program2 // STEP3 EXEC PGM=Program3 In the above e.g. Assume that step1 executes successfully. The return code is 0. Then it will check for the condition code (Is the number 4 less than 0 NO), then step2 will be executed. Incase step 2 returns 4 then once again it checks for the condition code (now 4 is equal to 4) so next step will be executed. Condition Parameter specified in EXEC statement implies only to particular job step e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, CLASS = A, PRTY= 6, MSGCLASS = A, // STEP1 EXEC PGM=Program1 // STEP2 EXEC PGM=Program2, // COND = (8, EQ, STEP1) In this e.g. The COND parameter specifies that STEP2 should be bypassed if 8 is equal to the return code issued by STEP1. REGION Parameter At the time that a job is run, a default amount of work space is assigned to it. In order to override this REGION parameter is used. Syntax: REGION = value1K (multiples of 1024 bytes) REGION = value2M (multiples of one million bytes) IF REGION = 0k or 0M then all available storage is assigned to job or job step. Region Parameter for Job statement e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx, REGION=96k // STEP1 EXEC PGM=Program1 Region Parameter for EXEC statement e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k TIME Parameter It is used to specify the amount of CPU time that a job or job step is permitted to utilize before it is terminated. Syntax: Time = (minutes, seconds) Minutes is the number from 1 to 1439 Seconds is from 1 to 59 DD (Data Definition) Statement

The DD statement is used to identify the source of input and the placement of output information Syntax: // DDName DD Keyword Parameter

Level II Skills Keyword Parameter It includes, DSN DISP UNIT SPACE DCB VOLUME DSN (Data set Name) Parameter Syntax: DSN = dsn-name

Basic JCL Coding

DISP (Dispositional) Parameter Syntax: DISP = (status, normal-disposition, abnormal-disposition) Status field indicates the current status of the data set Normal-Disposition specifies how the data set is to be disposed upon normal execution of the job. Abnormal-Disposition specifies how the data set is to be disposed upon abnormal termination of the job. Status New Old Mod Shr Normal-disposition Delete Keep Catlg Uncatlg pass Abnormal-disposition Delete Keep Uncatlg Catlg

New indicates that a new dataset is to be created Old indicates that a dataset already exists Mod used to modify sequential data sets Shr allows multiple jobs to read the same data set e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k // DD DSN=USER1.SAMPLE.TEST // DISP=(NEW,CATLG,DELETE) UNIT Parameter It is coded on the DD statement to specify an input or output device that is to be accessed.

Syntax: UNIT = device address (e.g. s26) UNIT = device type (e.g. 3390) UNIT = device group name (e.g. sysda) e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k // DD DSN=USER1.SAMPLE.TEST // DISP=(NEW,CATLG,DELETE) // UNIT=3390 Level II Skills Basic JCL Coding

VOL Parameter It is coded on the DD statement to identify specific disk or tape volumes. Syntax: VOL=SER= serial-number (e.g. VOL=SER=ee469) VOL=REF=*.referback (e.g. VOL = REF= *.STEP1.DD1) Refers to the previous DD statement for the volser VOL=PRIVATE (exclusive use of volume for the data set specified in the job step) VOL=RETAIN (the volume remains mounted until the completion of the job) e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k // DD DSN=USER1.SAMPLE.TEST // DISP=(NEW,CATLG,DELETE) // UNIT=3390, VOL=SER=EE469 SPACE Parameter It is coded on the DD statement used to allocate storage for new data set on DASD. Space can be in tracks, cylinders, blocks. Syntax: SPACE = (CYL, (primary, secondary, directory), RLSE, CONTIG, MXIG, ROUND) SPACE = (TRK, (primary, secondary, directory), RLSE, CONTIG, MXIG, ROUND) SPACE = (BLK, (primary, secondary, directory), RLSE, CONTIG, MXIG, ROUND) RLSE CONTIG ROUND Releases the allocated space when a data set is closed Specifies only contiguous space should be allocated to the ds. Applies only to primary space allocation Decreases data set access time Drawback the job will be terminated if the contiguous space is not found. It is used to specify that space requested should be allocated to the largest contiguous area of space available on the volume. Applies only to primary space allocation The system computes the amount of storage required, rounds it off to the nearest cylinder, and allocates that number of cylinders to the request.

MXIG

e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k // DD DSN=USER1.SAMPLE.TEST // DISP=(NEW,CATLG,DELETE)

// //

UNIT=3390, VOL=SER=EE469 SPACE = (CYL, (10, 5), RLSE)

DCB (Data Control Block) Parameter It is used to supply information to the system that allows it to manage the data sets that are created as jobs are submitted. Syntax: DCB = (RECFM=format, LRECL=record-length, BLKSIZE=block-size) RECFM used to specify to the operating system the record format of the data set being created. RECFM = F or FB or V or VB or U Level II Skills Basic JCL Coding

Where, f-fixed, fb-fixed-block, v-variable, vb-variable-block ,u-undefined length LRECL specify the length of the record, in bytes. LRECL = number BLKSIZE specifies the block size of a data set in bytes. BLKSIZE = number e.g. //JOB1 JOB (A123, DEPT1), xxxxxxxx // STEP1 EXEC PGM=Program1, REGION=96k //DD1 DD DSN=USER1.SAMPLE.TEST, // DISP=(NEW,CATLG,DELETE), // UNIT=3390, VOL=SER=EE469, // SPACE = (CYL, (10, 5), RLSE), // DCB = (RECFM=F, LRECL=80, BLKSIZE = 800) //SYSPRINT DD SYSOUT=* // Creating a GDG //JOB1 JOB (A123, DEPT1), xxxxxxxx //STEP1 EXEC PGM=IDCAMS //GDGMOD DD DSNAME=USER1.GDG01.TEST, 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 (25)) /* EMPTY NOEMPTY It specifies that all existing generations of the GDG are to be uncataloged. It specifies that only the oldest generation of the GDG is to be uncataloged if the limit is reached.

SCRATCH NOSCRATCH LIMIT

It specifies that if the entry of a data set in a GDG is removed from the index, then its entry should be physically deleted from the volume that it resides on. Indicates that the entry of the data set should only be uncataloged, not physically deleted from the volume. It specifies the total number of generations that the GDG may contain.

Level II Skills Adding a new version to GDG //JOB1 JOB (A123, DEPT1), xxxxxxxx //STEP1 EXEC PGM=IDCAMS //GDGMOD DD DSNAME=USER1.GDG01.TEST (+1), // DISP = (NEW, CATLG, DELETE) //SYSPRINT DD SYSOUT=A /* Modifying features of a GDG This can be achieved through ALTER command. //JOB1 JOB (A123, DEPT1), xxxxxxxx //STEP1 EXEC PGM=IDCAMS //SYSPRINT DD SYSOUT=A //SYSIN DD * ALTER USER1.GDG01.TEST LIMIT (10) /* Deleting a GDG //JOB1 //STEP1 //SYSIN /* Deleting a GDG Version //JOB1 JOB (A123, DEPT1), xxxxxxxx //STEP1 EXEC PGM=IDCAMS //DEL1 DD DSN = USER1.GDG01.TEST (+1), DISP = (OLD, DELETE, DELETE) /* JOB (A123, DEPT1), xxxxxxxx EXEC PGM=IDCAMS DD DELETE (USER1.GDG01.TEST) GDG

Basic JCL Coding

/*MANDATORY*/

Level II IBM Utilities IEBCOMPR: Compare records in sequential or partitioned data sets, or PDSEs. Two sequential data sets are considered equal (that is, are considered to be identical) if:

The data sets contain the same number of records Corresponding records and keys are identical

Two partitioned data sets or two PDSEs are considered equal if:

Corresponding members contain the same number of records Note lists are in the same position within corresponding members Corresponding records and keys are identical Corresponding directory user data fields are identical

If all these conditions are not met for a specific type of data set, those data sets are considered unequal. If records are unequal, the record and block numbers, the names of the DD statements that define the data sets, and the unequal records are listed in a message data set. Ten successive unequal comparisons stop the job step, unless you provide a routine for handling error conditions. You can run this sample JCL to compare two cataloged, partitioned organized (PO) data sets: IEBCOMPR SAMPLE //DISKDISK JOB ... // EXEC PGM=IEBCOMPR //SYSPRINT DD SYSOUT=A //SYSUT1 DD DSN=PDSE1,DISP=SHR //SYSUT2 DD DSN=PDSE2,DISP=SHR //SYSIN DD * COMPARE TYPORG=PO /* IEBCOPY : Copy, compress, or merge partitioned data sets or PDSEs; add RLD count information to load modules; select or exclude specified members in a copy operation; rename or replace selected members of partitioned data sets or PDSEs.

Make a copy of a PDS or PDSE Merge partitioned data sets (except when unloading) Create a sequential form of a PDS or PDSE for a backup or transport Reload one or more members from a PDSU into a PDS or PDSE

Select specific members of a PDS or PDSE to be copied, loaded, or unloaded Replace members of a PDS or PDSE Rename selected members of a PDS or PDSE

IEBCOPY utility example //COPY JOB ... //JOBSTEP EXEC PGM=IEBCOPY //SYSPRINT DD SYSOUT=A //OUT1 DD DSNAME=DATASET1,UNIT=disk,VOL=SER=111112, // DISP=(OLD,KEEP) //IN6 DD DSNAME=DATASET6,UNIT=disk,VOL=SER=111115, // DISP=OLD Level II IBM Utilities //IN5 DD DSNAME=DATASET5,UNIT=disk,VOL=SER=111116, // DISP=(OLD,KEEP) //SYSUT3 DD UNIT=SYSDA,SPACE=(TRK,(1)) //SYSUT4 DD UNIT=SYSDA,SPACE=(TRK,(1)) //SYSIN DD * COPY OUTDD=OUT1 INDD=IN5,IN6 SELECT MEMBER=((B,,R),A) /* IEBCOPY with copy and compress //COPY JOB ... //JOBSTEP EXEC PGM=IEBCOPY //SYSPRINT DD SYSOUT=A //INOUT1 DD DSNAME=DATA.SET1,UNIT=disk,VOL=SER=111112,DISP=(OLD,KEEP) //IN5 DD DSNAME=DATA.SET5,UNIT=disk,VOL=SER=111114,DISP=OLD //IN6 DD DSNAME=DATA.SET6,UNIT=disk,VOL=SER=111115, // DISP=(OLD,KEEP) //SYSUT3 DD UNIT=SYSDA,SPACE=(TRK,(1)) //SYSUT4 DD UNIT=SYSDA,SPACE=(TRK,(1)) //SYSIN DD * COPY OUTDD=INOUT1,INDD=(IN5,(IN6,R),INOUT1) /* IEBEDIT : Selectively copy job steps and their associated JOB statements. //IEBEDITJ JOB ACCT,'',CLASS=P,MSGCLASS=T,MSGLEVEL=(1,1),NOTIFY=&SYSUID //STEP0001 EXEC PGM=IEBEDIT //SYSPRINT DD SYSOUT=* //SYSUT1 DD DSN=xxxxx.yyyyy.zzzzz,DISP=SHR //SYSUT2 DD SYSOUT=(*,INTRDR) //SYSIN DD * EDIT TYPE=INCLUDE,STEPNAME=(STEP10,STEP5,STEP15) /*

IEBGENER : Copy records from a sequential data set, or convert a data set from sequential organization to partitioned organization. //IEBGENER JOB ACCT,'DATA COPY',MSGCLASS=J,CLASS=A //STEP010 EXEC PGM=IEBGENER //SYSUT1 DD DSN=xxxxx.yyyyy.zzzzz,DISP=SHR //SYSUT2 DD DSN=aaaaa.bbbbb.ccccc,DISP=(,CATLG), // DCB=(RECFM=FB,LRECL=1440),SPACE=(TRK,(5,5),RLSE), // UNIT=SYSDA //SYSPRINT DD SYSOUT=* //SYSIN DD DUMMY

Level II IBM Utilities IEBPTPCH : Print or punch records in a sequential or partitioned data set. //IEBPTPCH JOB // EXEC PGM=IEBPTPCH //SYSIN DD * PRINT MAXFLDS=2 TITLE ITEM=('Name',22), ITEM=('GPA',50) TITLE ITEM=(' ',1) RECORD FIELD=(25,1,,22), FIELD=(4,51,,50) /* //SYSPRINT DD SYSOUT=* //SYSUT1 DD * Person 1 307 C Meshel Hall 3.89 Second person 123 Williamson Hall 2.48 3rd person 321 Maag Library 1.52 /* //SYSUT2 DD SYSOUT=* // IEBUPDTE : Incorporate changes to sequential or partitioned data sets, or PDSEs. //stepname EXEC PGM=IEUPDTE,PARM=parm //SYSPRINT DD SYSOUT=class //SYSUT1 DD ... //SYSUT2 DD ... //SYSIN DD ... IEHINITT : IEHINITT is a system utility used to place standard volume label sets onto any number of magnetic tapes mounted on one or more tape units. //LABEL JOB ... //STEP1 EXEC PGM=IEHINITT //SYSPRINT DD SYSOUT=A

//LABEL1 DD DCB=DEN=2,UNIT=(tape,1,DEFER) //LABEL2 DD DCB=DEN=3,UNIT=(tape,1,DEFER) //SYSIN DD * LABEL1 INITT SER=TAPE1 LABEL2 INITT SER=001234,NUMBTAPE=2 /* IEHLIST : IEHLIST is a system utility used to list entries in the directory of one or more partitioned data sets or PDSEs, or entries in an indexed or non-indexed volume table of contents. Any number of listings can be requested in a single execution of the program. //VTOCLIST JOB ... //STEP1 EXEC PGM=IEHLIST //SYSPRINT DD SYSOUT=A //DD2 DD UNIT=3390,VOLUME=SER=TOTTSB,DISP=SHR Level II IBM Utilities //SYSIN DD * LISTVTOC VOL=3390=TOTTSB,INDEXDSN=SYS1.VTOCIX.TOTTSB /* IEHMOVE : Move or copy collections of data. //stepname EXEC PGM=IEHMOVE,PARM='LINECNT=xx,POWER=n' //SYSPRINT DD SYSOUT=class //SYSUT1 DD UNIT=aaaa,VOL=SER=bbbbbb,DISP=OLD //anyname1 DD UNIT=cccc,VOL=SER=dddddd,DISP=OLD //anyname2 DD UNIT=eeee,VOL=SER=ffffff,DISP=OLD //SYSIN DD ... ADRDSSU : It is used for backup, restore and dump Backup Job //JOB Statement //STEP2 EXEC PGM=ADRDSSU //SYSPRINT DD SYSOUT=* //DSN2 DD UNIT=3490,DISP=SHR,EXPDT=99000, // DSNAME=XXX.XXX.XXX.XXX //TAPE2 DD DSN=XXX.XXX.XXX.XXX.BKUP,UNIT=3590-1, // DISP=(NEW,CATLG,DELETE), // VOL=(,RETAIN,,20,REF=*.STEP1.TAPE1), // LABEL=(02,SL,RETPD=10) //SYSIN DD * DUMP INDD(DSN2) OUTDD(TAPE2) /* Restore Job //STEP3 EXEC PGM=ADRDSSU //SYSPRINT DD SYSOUT=* //DSN3 DD UNIT=3490,DISP=(NEW,CATLG,DELETE),

// DSNAME=XXX.XXX.XXX.XXX,EXPDT=99000 //TAPE3 DD DSN=XXX.XXX.XXX.XXX.BKUP,UNIT=3590-1, // DISP=OLD,VOL=SER=EB0231,LABEL=(3,SL) //SYSIN DD * DUMP INDD(TAPE3) OUTDD(DSN3) /* Physical Move //JOB //EXEC PGM=ADRDSSU //SYSPRINT DD SYSOUT=* //FROM DD VOL=SER=XXX,DISP=SHR,UNIT,=SYSALLDA //TO DD VOL=SER=YYY,DISP=SHR,UNIT,=SYSALLDA

Level II IBM Utilities //SYSIN DD * COPY INDD(FROM1) OUTDD(T01) FULL ALLDATA(*) ALL EXPTOL(IOERROR) COPYVOLID //* Logical Move //JOB //EXEC PGM=ADRDSSU //SYSPRINT DD SYSOUT=* //FROM DD VOL=SER=XXX,DISP=SHR,UNIT,=SYSALLDA //TO DD VOL=SER=YYY,DISP=SHR,UNIT,=SYSALLDA //SYSIN DD * COPY LOGINDD (FROM1) OUTDD (T01) TOL(IOERROR)ALL DATA (*) ALL EXCP ADMIN PURGEDELETE ALL MULTI WAIT (0,0)DS (INCL (* *), EXCL(SYS1.VTOIX.*,SYS1.VVDS.*)) /* Reclaiming DASD Space DASD space can be reclaimed by releasing unused space in dataset Example: //EXEC PGM=ADRDSSU //SYSIN DD * RELEASEDYNAM(SMS007)INCLUDE (XXX.**) /* Compression

It removes unused space between members in a pds. This recovered space is then available for reuse at the end of the dataset. Example: //JOB, REGION=OM //SYSIN DD * COMPRESSDYNAM((SMS011),(SMS006),(SMS001).) INCLUDE (XXX.**) /* Consolidating Free Space On Volumes By using DEFRAG we can consolidate the free space on volumes. This is done to prevent from out-of-space abens on new allocations. Example: //STEP1 DD UNIT=3390,VOL=SER=SMS001,DISP=SHR //SYSIN DD * DEFRAG Level II IBM Utilities DDNAME (STEP1) /* Conversion Of SMS To Non-SMS Management Dataset can be converted from sms managed to non-sms. Example: //DEFRAG EXEC PGM=ADRDSSU //SYSPRINT //SYSIN DD * CONVERV DYNAM (SMS002) NONSMS /*

Level II DFSMS

SMS and ACS Routine Functionality

The Primary means of managing space in Z/OS is through the DFSMS component of the operating system. DFSMS automatically manages data from creation to expiration. The heart of DFSMS is Storage Management Subsystem (SMS) Using SMS, a storage administrator defines policies that describes, Data Allocation Characteristics Performance and Availability Goals Backup and Retention requirements Storage requirements for the system. NOTE: SMS governs these policies for the system and ISMF provides the user interface for defining and maintaining the policies. DFSMS Components It is a set of product associated with Z/OS that is responsible for data management. DFSMS has five functional components. They are, DFSMSdfp Data Facility Product DFSMSdss Data Set Services DFSMShsm Hierarchical Storage Manager DFSMSrmm Removable Media Manager DFSMStvs Transactional VSAM Services DFSMSdfp It is the base element of Z/OS It is the heart of storage management subsystem It provides the logical and physical input and output for z/OS storage It keeps track of all data and programs managed within z/OS DFSMSdss It works on DASD volumes only in the MVS environment.

It is an optional feature of Z/OS DFSMSdss helps to do, Copy and move data sets between volumes of like and unlike device types Dump and restore data sets, entire volumes, or specific tracks Convert data sets and volumes to and from SMS management Compress partitioned data sets Release unused space in data sets Reduce or eliminate DASD free-space fragmentation by consolidating free space on a volume

DFSMShsm It is a tool designed to support Availability management and Space management. Availability management is a process that helps maintain a backup copy of data set that can be easily recovered incase of damage in the original copy or incase of accidental deletion of data set. Space management is a process that monitors usage to maintain enough space on user volumes for new and active data. DFSMShsm uses three level storage device hierarchies for space management. Level 0 contains data directly accessible to the end user or program. Level 1 is disk containing data sets that DFSMShsm has moved from level 0 volumes. Level II SMS and ACS Routine Functionality

Level 2 is tape containing data sets that DFSMShsm has moved from level 1 or level 0 volumes. DFSMShsm can automatically delete data sets that have passed their expiration dates.
DFSMShsm can manage backed up, dumped, and migrated volumes and data sets.

DFSMSrmm It manages all the tape volumes and datasets. It manages the movement of tape volumes between libraries and vaults over the life of the tape data sets. It also handles scratch and expired data sets. DFSMStvs It is an optional z/OS feature that enables batch jobs and CICS online transactions to update shared VSAM data sets concurrently. Multiple batch jobs and online transactions can be run against the same VSAM data sets, and DFSMStvs helps ensure data integrity for concurrent batch updates while CICS ensures it for online updates. SMS

The Dataset allocated through SMS are called System-managed DS or SMS-managed DS. One of the mechanisms DFSMS/MVS provides to help automate storage management is the SMS constructs. They are defined using ISMF When we allocate a Dataset to use SMS, we specify the dataset requirement through SMS constructs. The SMS Constructs includes, Data Class Management Class Storage Class

Storage Group NOTE: The users do not need to specify these classes because the storage administrator has set up ACS (Automatic Class Selection) routines to determine which classes are used for a given data set. SMS CONSTRUCTS DATA CLASS A data class contains the allocation and the space attribute for a dataset. Data class applies to both SMS and non-SMS managed data sets. They do not apply to objects. STORAGE CLASS Storage classes are used to define performance and availability goals. It is used to select a device that meets those goals. ACS routine can override the storage class assignment. It applies only the SMS-managed data sets and its objects. MANAGEMENT CLASS It applies only to SMS-managed DASD datasets and objects. It is used to define backup and retention requirements. Level II ACS routine can override the management class assignment. Some of the attributes that are defined in management class are:

SMS and ACS Routine Functionality

Expiration Date Migration Criteria GDG management Backup of dataset Aggregate Backup

HINT: Management class allows us to define the management requirement for an individual dataset than for the entire volume. STORAGE GROUP It is a collection of logical volumes managed as a single unit. Collection includes, DASD volumes Tape Volumes System paging volumes Optical volumes DASD, Tape, Optical volume treated a single unit. All SMS-managed dataset must contain a storage group SMS Configuration SMS configuration composes:

Set of data class, storage class, and management class and storage group. ACS routines to assign classes and groups Tape Library definition

Aggregate group definition Optical Library and drive definitions.

SMS configurations are stored in SMS control dataset, which is a VSAM Linear data set. Control data set must be defined before activating SMS. Different types of control data set are:

Source Control Data set (SCDS) Active Control Data set (ACDS) Communication Control Data set (COMMDS)

Source Control Data set It contains SMS classes, groups and translated ACS routines that define storage management policies. A SMS configuration may contain more than one SCDS but only one can be activated at a time. SCDS is never used to manage storage allocations. Active Control Data set It is the systems active copy of the current SCDS When SMS configuration is activated, SMS copies the existing SCDS into ACDS.

Level II

SMS and ACS Routine Functionality

Communication Control Data set It enables communication between SMS in a multi-system environment. It contains: SMS status Space statistics MVS status for each system-managed volumes

ACS ROUTINE The role of the ACS routines is to assign specific policies to the data set that is providing centralized administrator control over data set allocation. Once a DFSMS configuration has been created, it can be used as the set of policies that automate storage management across a z/OS sysplex.

Fig. Working principle of ACS Routine. Level II SMS and ACS Routine Functionality

The ACS routines are invoked whenever data sets are created, either at initial allocation or as a result of operations that cause them to be reallocated or moved.

Level II Management Facility

Interactive Storage

The Interactive Storage Management Facility (ISMF) helps to analyze and manage data and storage interactively. ISMF is an Interactive System Productivity Facility (ISPF) application. ISMF provides interactive access to the space management, backup, and recovery services of the DFSMShsm and DFSMSdss.

A storage administrator uses ISMF to define the installation's policy for managing storage by defining and managing SMS classes, groups, and ACS routines. ISMF then places the configuration in an SCDS. Then SCDS activate an through ISMF or an operator command. ISMF is a panel-driven interface. ISMF can be used to:

Display lists with information about specific data sets, DASD volumes, mountable optical volumes, and mountable tape volumes Generate lists of data, storage, and management classes to find out how data sets are being managed Display and manage lists saved from various ISMF applications

ISMF generates a data list based on selection criteria. Once the list is built, we can use ISMF entry panels to perform space management or backup and recovery tasks against the entries in the list. As a user performing data management tasks against individual data sets or against lists of data sets or volumes, ISMF can use to:

Edit, browse, and sort data set records Delete data sets and backup copies Protect data sets by limiting their access Recover unused space from data sets and consolidate free space on DASD volumes Copy data sets or DASD volumes to the same device or another device Migrate data sets to another migration level Recall data sets that have been migrated so that they can be used Back up data sets and copy entire volumes for availability purposes Recover data sets and restore DASD volumes, mountable optical volumes, or mountable tape volumes.

ISMF: Profile option

User Mode Entry Panel Level II Interactive Storage Management Facility In the ISMF Profile Option Menu panel, Option 0 from the ISMF Primary Menu Change the user mode from end user to storage administrator, or from Storage Administrator to End user.

Option 1 - End User can perform very limited no of task Option 2 - Storage administrator mode we can perform all storage administration Task. ISMF Panel

Generating Lists We can construct a list of information about specific data sets, volumes, or SMS Classes. ISMF: Data set option Data Set Selection Entry panel Select the option 1 (Data Set) from the ISMF Primary Option Menu and specify filter criteria to get a list of data sets, as follows: To generate a new list from criteria below Data Set Name . . . 'MHLRES2.**' Here the data set list generated for the generic data set name MHLRES2.** The process of selecting data sets and volumes using partial names is called Partial Qualification. Level II Management Facility Dataset Selection Panel Interactive Storage

Partially Qualifying Data Set Names To qualify data set names, use asterisks and percent signs as global file-name characters within a qualifier: Example 1. Use a percent sign as a global file-name character for a single position: DATA SET NAME ===> TEST% ISMF selects data sets whose name is exactly five characters and starts with the letters TEST. This example could include TEST1 to TEST9 or TESTA to TESTZ, or both. 2. Use an asterisk as a global file-name character for zero or more characters. For example, when specify a data set name of DATA SET NAME ===> TEST* ISMF selects data sets whose name consists of only one qualifier and begins with the letters TEST. This could include: TEST, TESTX, and TEST1 through TEST1000. 3. When specifying a data set name, use a double asterisk as a global file-name character for any number of qualifiers. A qualifier is one of the parts connected by periods that constitute a data set name. A data set name consists of one or more qualifiers. For example, when specify a partial data set name of DATA SET NAME ===> 'SYS1.***' Level II Management Facility Interactive Storage

ISMF selects data sets with any number of qualifiers. The first qualifier must be

SYS1. ISMF could select the following data sets: SYS1.TEST.TEST SYS1.LIST.XMP SYS1.MEMO.EMP.A Volume Option Partially Qualifying DASD Volume Names Use an asterisk sign as a global file-name character for zero or more characters. For example, when specify a partial volume serial number of VOLUME SERIAL NUMBER = SYS* ISMF lists all volume names whose first 3 characters are SYS. The list might include SYS1, SYSA, SYS, or SYSLIB.

To generate a list of DASD volumes, select option 1 to displays the first of three pages of the Volume Selection Entry Panel.

Level II Management Facility

Interactive Storage

Volume serial number Enter a full or partial serial number of the volume or volumes to include in the list. Use this optional field to restrict the list to volumes with a specific volume serial number or range of volume serial numbers. To include a single volume, enter a fully qualified volume serial number of one to six characters: Example VOLUME SERIAL NUMBER ===> SYS001 To include a range of volumes, enter a partially qualified volume serial number by using a single asterisk as a global file-name character: VOLUME SERIAL NUMBER ===> SYS * Use six asterisks to specify the system residence volume (SYSRES): VOLUME SERIAL NUMBER ===> ***** Use a single asterisk to specify all mounted volumes that fit other selection criteria: VOLUME SERIAL NUMBER ===> * ISMF: Management Class option By using the management class for a given data set, DFSMShsm can decide how data sets should be backed up, when they should be migrated, and when backup copies should be deleted. Management class option is use to display, modify, and define options for the SMS management classes A management class defines the following attributes: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. Partial Release Expiration Attributes Expire After Date/Days Expire After Days Non-Usage Retention Limit Migration Attributes Command or Auto Migrate Level 1 Days Non-Usage Primary Days Non-Usage Generation Data Group Management Attributes Number of GDG Elements on Primary Rolled-off GDS Action Backup Attributes Administrator or User Command Backup Versions

Level II Management Facility 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. 29. 30. 31. Auto Backup Backup Copy Technique Backup Frequency Number of Backups (Data Set Deleted) Number of Backups (Data Set Exists) Retain Days Extra Backups Retain Days Only Backup Versions Class Transition Attributes Object Class Transition Criteria Aggregate Backup Abackup Copy Technique Copy Serialization Number of Versions Retain Extra Versions Retain Extra Versions Unit Retain Only Version Retain Only Version Unit

Interactive Storage

Data Class option A data class defines the way data sets are allocated Data class attributes are assigned to a data set when the data set is created. It can applicable to both SMS-managed and non-SMS-managed data sets A data class defines the following attributes: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. Compaction Data Set Organization Record Format Record Size Key Length/Offset Space Average Record Average Value Primary Secondary Directory Data Set Name Type Media Type Recording Technology Retention Period or Expiration Date Volume Count Additional Volume Amount Imbed Replicate Control Interval Size Percent Free Space Share Options

Level II Management Facility

Interactive Storage

Storage Class The Storage Class lets the storage administrator specify performance objectives and availability attributes to a collection of data sets. A storage class defines the following attributes: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. Storage Class Name Description Performance Objectives Direct Bias Direct Millisecond Response Initial Response Seconds Sequential Bias Sequential Millisecond Response Sustained Data Rate Availability Objectives Accessibility Availability Guaranteed Space

Storage group Storage Group (SG) . A collection of storage volumes and attributes, The collections can be a group of DASD volumes or tape volumes, or a group of DASD volumes and optical volumes. Storage Group should be one to eight character, it should be alphabetic or national character. Automatic Class Selection 1. 2. 3. 4. 5. 6. Edit Translate Validate Test Display Delete - Edit ACS Routine source code - Translate ACS Routines to ACS Object Form - Validate ACS Routines Against Storage Constructs - Define/Alter Test Cases and Test ACS Routines - Display ACS Object Information - Delete an ACS Object from a Source Control Data Set

Automatic class selection (ACS ) routines to assign classes (Data, storage, and management) and storage group definitions to data sets, Database data and objects. ACS language, which is a high-level programming language. Once written, ACS translator to translate the routines to object form so they can be stored in the SMS configuration. The ACS language contains a number of read-only variables, which can use to analyze new data allocations.

Level II Management Facility SMS configuration An SMS configuration is composed of: 1. 2. 3. 4. 5. 6.

Interactive Storage

A set of data class, management class, storage class, and storage group ACS routines to assign the classes and groups Optical library and drive definitions Tape library definitions Aggregate group definitions SMS base configuration, that contains information such as: I. Default management class II.Default device geometry III.The systems in the installation for which the subsystem manages storage.

The SMS configuration is stored in SMS control data sets, which are VSAM linear data sets. Define the control data sets before activating SMS. SMS uses the following types of control data sets: SMS control data sets SMS stores its class and group definitions, translated ACS routines, and system information in three control data sets. Source Control Data Set (SCDS) The SCDS contains SMS classes, groups, and translated ACS routines that define a single storage management policy, called an SMS configuration. Even though system has several SCDSs, but only one can be used to activate the SMS configuration. SCDS should have gone through test , before activating a configuration, retain at least one prior configuration needed to avoid problem . The SCDS is never used to manage allocations. Active Control Data Set (ACDS) The ACDS is the system's active copy of the current SCDS. When activate a configuration, SMS copies the existing configuration from the specified SCDS into the ACDS. By using copies of the SMS classes, groups, volumes, optical libraries, optical drives, tape libraries, and ACS routines rather than the originals, The changes should be done in the current storage management policy without disrupting the original For example, while SMS uses the ACDS, The following action can be done: 1.Create a copy of the ACDS 2.Create a backup copy of an SCDS 3Modify an SCDS 4.Define a new SCDS

Level II Management Facility

Interactive Storage

Communications Data Set (COMMDS ) The COMMDS data set contains the name of the ACDS and storage group volume statistics. It enables communication between SMS systems in a multisystem environment. 1. Source Control Data Set (SCDS) 2. Active Control Data Set (ACDS) 3. Communications Data Set (COMMDS) CDS Panel CDS Name . . ACTIVE (1 to 44 Character Data Set Name or 'Active') Select one of the following Options: 1. 2. 3. 4. 5. 6. 7. Edit Through this panel ACS source code can be modified or change based on our requirement. Translate The translation process checks the routines for syntax errors and converts the code into an ACS object. If the code translates without any syntax errors, then the ACS object is stored in the SCDS. Validate When validate the SCDS, verify all classes and groups assigned by ACS routines are defined in the SCDS. To validate the SCDS:

Display - Display the Base Configuration Define - Define the Base Configuration Alter - Alter the Base Configuration Validate - Validate the SCDS Activate - Activate the CDS Cache Display - Display CF Cache Structure Names for all CF Cache Sets Cache Update - Define/Alter/Delete CF Cache Sets

From the ISMF Primary Option Menu panel, select Control Data Set and press Enter Enter SCDS data set name and select 4 Validate .

Activate Activating a new SMS configuration means to copy the configuration from SCDS to ACDS. To activating an SMS configuration from ISMF :

From the ISMF Primary Option Menu panel, select Control Data Set. In the CDS Application Selection panel, enter SCDS data set name and select 5 Activate.

Test From this panel we can test ACS routine, whether the given class works fine or not.

Level II Management Facility

Interactive Storage

Aggregate group Aggregate group is a collection of related data sets and control information that has been pooled to meet a defined backup or recovery strategy. If a disaster occurs, use these backups at a remote or local site to recover critical applications. The aggregate group application allows to: 1. 2. 3. 4. 5. 6. 7. 8. Generate a list of aggregate groups. Display the attributes of a single aggregate group. Delete aggregate groups. Edit and browse the selection data sets associated with an aggregate group. Edit and browse the instruction data sets associated with an aggregate group. Backup the selected aggregate group. Recover an aggregate group that has been backed up. Specify the number of local copies of aggregate backup (ABACKUP) output files that is to be created. (15 maximum) 9. Assign aggregate backup attributes to an aggregate group by giving it a 10. management class name Removable Media Manager 1 Optical Library 2 Optical Drive 3 Tape Library - Optical Library Configuration - Optical Drive Configuration - Tape Library Configuration

We can list out Optical library, Optical Drive and Tape library information from Removable media manager option. Level II Review of Storage Pools to Determine Space Issues

Go to ISMF panel and select storage group option A list of storage group names will be shown Check for the %freespace for the entire storage group Document the %freespace details against every storage group Examine the minimum %freespace If the %freespace falls down the threshold value (i.e. minimum freespace), take measures accordingly. Some of the possible measures Adding a new volume to the existing storage group which has less %freespace Deleting the expired data sets of the volume

Das könnte Ihnen auch gefallen