I wanted to unterse a file, and use DFDSS to restore the datasets. This pretty trivial task had a few problems, and I learned a few things from it. (Well, to be accurate, I fell over the same problems as last time I did it, but I hadn’t bother writing down the solutions.)
Running out of space
My original JCL to unterse a file was
//S1 EXEC PGM=AMATERSE,PARM=UNPACK //SYSPRINT DD SYSOUT=* //SYSUT2 DD DSN=COLIN.UNTRS,SPACE=(CYL,(100,100)),DISP=(,PASS)
This gave me
IGD17272I VOLUME SELECTION HAS FAILED FOR INSUFFICIENT SPACE FOR
DATA SET COLIN.UNTRS
JOBNAME (COLINMQ3) STEPNAME (S1 )
PROGNAME (AMATERSE) DDNAME (SYSUT2 )
REQUESTED SPACE QUANTITY = 83003 KB
STORCLAS (SCBASE) MGMTCLAS ( ) DATACLAS ( )
STORGRPS (SGBASE SGEXTEAV )
This was annoying as I had plenty of disks space – but not in the SMS storage groups listed.
I fixed this by allocating the dataset outside of SMS. I used
//SYSUT2 DD DSN=COLIN.UNTRS,SPACE=(CYL,(100,100)),DISP=(NEW,CATLG), // VOL=SER=C4PRD3,UNIT=3390,STORCLAS=SCNOSMS
See One Minute SMS for more information.
DFDSS restore challenges
Having unzipped my file I needed to restore it to create the data sets. I used
//S2 EXEC PGM=ADRDSSU,REGION=0M
//SYSPRINT DD SYSOUT=*
//D1 DD DISP=SHR,DSN=.S1.SYSUT2
//DD1 DD DISP=SHR,DSN=COLIN.UNTRS
//SYSIN DD *
RESTORE –
IMPORT –
INDDNAME(DD1) –
CANCELERROR –
DATASET(INCLUDE()) – RENAMEU( – (.SCSQANLC,COLIN.MQ930.SCSQANLC) –
…
) –
SHARE –
NULLMGMTCLAS –
NULLSTORCLAS –
CATALOG/*
It took several goes to get right. Once it was partially working, I got return code 8 because data sets existed.
I tried using REPLACE, but this did not work
REPLACE only applies if the data set is not being renamed. REPLACEUNCONDITIONAL should be used when renaming a data set and a
preallocated target data set should be replaced.
Restoring the datasets had problems.
The job had two steps
- Unterse the dataset into a temporary data set
- Restore from the temporary data set and recreate the libraries
Depending on the SMS setup this may not work.
If the temporary file was allocated to VIO (a Virtual data set using virtual memory), the DFDSS restore job failed with a message INPUT DEVICE TYPE IS INVALID FOR TASK. I guess the code checks to see if the data set is on a 3390 or tape drive ? If not – then it must be an error!
If a real data set was used (non VIO), it worked.
The error messages were
ADR101I (R/I)-RI01 (01), TASKID 001 HAS BEEN ASSIGNED TO COMMAND ‘RESTORE ‘
ADR109I (R/I)-RI01 (01), 2022.145 13:25:30 INITIAL SCAN OF USER CONTROL STATEMENTS COMPLETED
ADR025E (001)-DEVSU(03), INPUT DEVICE TYPE IS INVALID FOR TASK
ADR017E (001)-CLTSK(01), 2022.145 13:25:30 TASK NOT SCHEDULED DUE TO ERROR. TASK RETURN CODE 0008
ADR012I (SCH)-DSSU (01), 2022.145 13:25:30 DFSMSDSS PROCESSING COMPLETE. HIGHEST RETURN CODE IS 0008 FROM: TASK 001
When I used
//SYSUT2 DD DSN=COLIN.UNT,SPACE=(CYL,(200,200)),DISP=(NEW,CATLG),
// VOL=SER=(C4USS2,C4USS1),UNIT=3390,STORCLAS=SCNOSMS
The job worked fine with return code 0.
The name of the storage class is site dependent. Other storage classes may work. My ACS routine has the following.
WHEN (&DSTYPE = 'TEMP' && &SIZE < 2000001KB) DO SET &STORGRP = 'SGVIO','SGBASE','SGEXTEAV' EXIT CODE(0) END
There are different sorts of Storage Groups
- Pool – list of disks which can be used
- VIO – when Virtual IO (paging) it to be used.
You need to pick a storage group associated with a Pool.
DSS always used its own channel programs to read and write up to a cylinder at a time (depending on the setting of the OPT parameter of the DUMP command) and to overlap reading and writing so that the elapsed time was minimised especially in the far-off days when full-volume dumps were de rigueur. I would hazard a guess that the channel commands were, of course, unsuitable for VIO so DSS would fail the operation on detecting VIO.
Your point about space in storage groups is interesting. The idea of enforcing volume pooling via SMS was intended to reduce space shortages by letting an allocation see as much space as possible in a large storage group. It was an uphill struggle to convince people used to owning their own physical volumes to move to an environment with few pools with many volumes in each.
LikeLike