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

Writing multiple volume sequence data set


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

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Wed Aug 13, 2008 9:32 am
Reply with quote

I have writing to a QSAM data set that allocated with three volumes(DASDs). However, the data set seems cannot be extented on the first 2 volumes even there is enough space. icon_question.gif

The JCL is simplifed as follow :

Code:

//REPRO1  EXEC PGM=IDCAMS                             
//SYSPRINT DD  SYSOUT=*                               
//IN1      DD  DSN=TEST.INFILE,DISP=SHR               
//OUT1     DD  DSN=TEST.OUT,DISP=(,CATLG),             
//        UNIT=(3390,3),VOL=SER=(DISK01,DISK02,DISK03),
//        SPACE=(TRK,(300,300)),                       
//        DCB=(RECFM=VB,LRECL=8189,BLKSIZE=27998)     
//SYSIN    DD  *                                       
    REPRO   INFILE(IN1) OUTFILE(OUT1) COUNT(100)       
//REPRO2  EXEC PGM=IDCAMS                             
//SYSPRINT DD  SYSOUT=*                               
//IN1      DD  DSN=TEST.INFILE,DISP=SHR               
//OUT1     DD  DSN=TEST.OUT,DISP=OLD                   
//SYSIN    DD  *                                       
    REPRO   INFILE(IN1) OUTFILE(OUT1) COUNT(3000)     
//REPRO3  EXEC PGM=IDCAMS                             
//SYSPRINT DD  SYSOUT=*                               
//IN1      DD  DSN=TEST.INFILE,DISP=SHR               
//OUT1     DD  DSN=TEST.OUT,DISP=OLD                   
//SYSIN    DD  *                                       
    REPRO   INFILE(IN1) OUTFILE(OUT1) COUNT(4000)     
//REPRO4  EXEC PGM=IDCAMS                             
//SYSPRINT DD  SYSOUT=*                               
//IN1      DD  DSN=TEST.INFILE,DISP=SHR               
//OUT1     DD  DSN=TEST.OUT,DISP=OLD               
//SYSIN    DD  *                                   
    REPRO   INFILE(IN1) OUTFILE(OUT1) COUNT(8000) 


From ISPF the data set allocation is as follow:
DSNAME VOL Tracks %Used XT Device
TEST.OUT DISK01 300 100 1 3390
TEST.OUT DISK02 300 100 1 3390
TEST.OUT DISK03 900 81 3 3390

Any ideas ?

Thanks!

P.S. The output data set is non-system-managed.
[/img]
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Wed Aug 13, 2008 10:29 am
Reply with quote

Hi,
Mainopr wrote:
the data set seems cannot be extented on the first 2 volumes even there is enough space. icon_question.gif
How do You conclude this..? Were there some error messages ?
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Wed Aug 13, 2008 10:58 am
Reply with quote

Hi Anuj D.,

Thank you for your message.

As I know a QSAM data set should be able to extent on same DASD for 16 times before it try another volume.

However, when I use ISPF(Dslist) to see the data set, it shows that the data set have used 3 volumes with the first 2 volumes using only 1 extent and 3 extents at last volume.

DSNAME VOL Tracks %Used EXT Device
TEST.OUT DISK01 300 100 1 3390
TEST.OUT DISK02 300 100 1 3390
TEST.OUT DISK03 900 81 3 3390

And there is no error message.

Thanks.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Wed Aug 13, 2008 2:55 pm
Reply with quote

Quote:
As I know a QSAM data set should be able to extent on same DASD for 16 times before it try another volume.
As long as there is space on the volume for an extent. If the pack is pretty much full, you may only get ONE extent before the dataset goes to another volume.
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Wed Aug 13, 2008 3:04 pm
Reply with quote

Hi Robert Sample,

I had checked those DASDs have enough space for the file to further extent.

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

Global Moderator


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

PostPosted: Wed Aug 13, 2008 3:12 pm
Reply with quote

How is the fragmentation - just because enough space exists on a volume it does not mean that it can be used.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Wed Aug 13, 2008 3:17 pm
Reply with quote

Hi,
expat wrote:
How is the fragmentation - just because enough space exists on a volume it does not mean that it can be used.
Do we "frangment" DASDs as well..?
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Wed Aug 13, 2008 3:20 pm
Reply with quote

Hi all,

In fact, those are empty DASDs. And they have large enough CONTIG space for further extent.

Thanks all.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Wed Aug 13, 2008 5:54 pm
Reply with quote

It looks to me like the system is doing exactly what you told it to do. You told the system to allocate the dataset on 3 disk packs. It did so. Once the dataset has been allocated on 3 disk packs, whether or not the first and second disk packs use one extent or not is irrelevant -- datasets only extend at the end. From your comments, it appears that you want to allocate the dataset on DISK01, fill 16 extents, allocate on DISK02, fill 16 extents, then allocate on DISK03. This is not going to happen the way you've defined the dataset.

You're better off using SMS-managed disks for what you want to accomplish. If you cannot, you could try allocating on DISK01 as a single-volume dataset and when adding records override the VOL=SER parameter.
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Thu Aug 14, 2008 7:51 am
Reply with quote

Hi Robert Sample,

Thanks a lot for your message. icon_smile.gif

I am intent to ensure that there is total 14400 tracks for the dataset. If the data set cannot be extented on the first two volumes, it will only have a max. of 5400 tracks to store data, which may casue B37 in my case.

For some reasons, I have to define the dataset with TRK,(300,300) instead of TRK,(4800,0) at once with multi-volumes.

Quote:
This is not going to happen the way you've defined the dataset.


Is there any tricks to define the dataset in order to make it extent on same volume for 16 times before go on another ? As the dataset is going to used in production environment, it is impossible for me to wait for the dataset nearly full and override the VOL=SER parameter.


P.S. For my shop SMS is not implemented yet icon_cry.gif .

[/code]
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Thu Aug 14, 2008 8:08 am
Reply with quote

While I understand what you're saying, it's not making a whole lot of sense. Even though extents aren't as costly as they used to be, they're still not free -- it'll take longer to go through the extents than reading a contiguous file. And you're only needing 960 cylinders, which is less than one-third of a 3390-3; not a huge file by any means these days.

I am not familiar enough with allocation processing to be able to fully answer your question, but under the restrictions you've listed (which I would first try very hard to get modified by your storage administrators), I would allocate to DISK01 only. Then use IDCAMS ADDVOL command to add DISK02 and DISK03; I don't know that extents would still come at the end of the dataset in this case.

If I really absolutely had to do it the way you describe, I'd allocate to DISK01, run a SAS job to write enough records to fill 16 extents, then the next step would use IDCAMS ADDVOL to add DISK02 to the dataset, then run a SAS job to write enough records to fill the 16 extents on DISK02, then repeat the ADDVOL and SAS job with DISK03. This six-step job is the only way I know for sure to accomplish what you're wanting under the restrictions you've given.
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Thu Aug 14, 2008 8:47 am
Reply with quote

Hi Robert Sample,

Many thanks to you. Maybe my example has misleading you. icon_redface.gif

The (production) dataset that I going to deal with has size varying from day to day but not more than 13,000 cyls. Due to the limitation that each volume can held up to 65535 tracks.Thus, I have define it on three 3390-9 DASDs at once initially.

P.S. Sadly our shop is not familiar with large dataset DSNTYPE=LARGE, hence I am not allowed to use it icon_cry.gif.
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: Thu Aug 14, 2008 8:56 am
Reply with quote

Hello,

Once built, how will this "file" be used?

What has established the requirement that it be built in only this way?
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Thu Aug 14, 2008 11:03 am
Reply with quote

Hi dick scherrer,

This file is used to store daily transaction on a monthly base for history enquiry. The data will be migirated to tape before it is cleaned up every month. It is estimated that the max size will be 13,000 Cyls.

In my shop, we mainly use 3390-9 DASDs. Besides, it is suggested that not to set the primary size too large to avoid fragmentation since those volumes maybe shared with other datasets. Thus, the dataset is defined on multi-volumes with a secondary size > 0.

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

Global Moderator


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

PostPosted: Thu Aug 14, 2008 11:42 am
Reply with quote

Given the situation, I would talk to the storage people and suggest that you allocate 5,000 cylinders on each volumes.

If SMS is not installed then the release of free space and unused extents should not be a problem.

As long as you explain your problem to the storage people they will be aware of the dataset and will not take action against it, and will also be aware of how to treat it when SMS is installed. Once it is, I would suggest SDS (Sequential Data Striping) which allows you to allocate the file over a number of volumes in one hit i.e. SPACE=(CYL,(15000))
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Aug 14, 2008 12:38 pm
Reply with quote

Hi,

I'm curious to know what the file looks like after running REPRO1 step only
ie. how many volumes does the dataset span across.

Also 300,300 tracks does not guarantee a total of 4800 tracks

see http://ibmmainframes.com/viewtopic.php?t=26006&highlight=gerry+extents


Gerry
Back to top
View user's profile Send private message
Mainopr

New User


Joined: 05 Feb 2007
Posts: 11
Location: HK

PostPosted: Thu Aug 14, 2008 1:03 pm
Reply with quote

Hi gcicchet,

After each step the usage information will be look like that :

Code:

COUNT(100)
VOLSER      Tracks %Used XT  Device
---------------------------------------------
DISK01       300            5   1    3390 

COUNT(3000) 
VOLSER      Tracks %Used XT  Device
---------------------------------------------
DISK01       300          100  1    3390 
DISK02       300            66  1    3390 


COUNT(4000)     
VOLSER      Tracks %Used XT  Device
---------------------------------------------
DISK01       300          100  1    3390 
DISK02       300          100  1    3390 
DISK03       300            22  1    3390 


COUNT(8000) 
VOLSER      Tracks %Used XT  Device
---------------------------------------------
DISK01       300          100  1    3390 
DISK02       300          100  1    3390 
DISK03       900            81  3    3390 



And yes you are right, due to fragmentation, the total size may not be guaranteed as calculated. Thus, our storage admin. won't suggest us to use large value on both primary & secondary space.

Thanks !
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Aug 14, 2008 4:37 pm
Reply with quote

Hi,

can you try changing from 300,300 to 300,299 , again I'm interested to know if the space allocated on the 2nd and 3rd volumes is the secondary space or the primary.

Also can you do a LISTC next to the dataset after REPRO1 step.

What happens if you just specify UNIT=(SYSDA,3) and no VOL parameter ?


Gerry
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Aug 14, 2008 4:47 pm
Reply with quote

I think that your results would be different if you tried to repro only the COUNT(8000) in the first step.

The first step allocates your dataset, 300 tracks on 3 volumes. And then writes to the dataset.

The subsequent steps overwrite the existing data but are adding more data with each test step. When the first extent on the first volume is used up the system knows that a second extent exists on another volume, so will use that without extending on the first volume.

The same holds true for the second volume, an extent of free space exists within the pre allocated file so gets used. Now we are on the last volume of the sequence, and any extra extents will be allocated on that volume and that volume alone.

So if you ask me, not the very best way to go about performing space allocation.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Aug 14, 2008 5:18 pm
Reply with quote

Hi,

I just managed to test this unusual space set up, the first step allocates 300 tracks on the first volume only, the catalog lists all 3 volumes.

The dataset does not exist on vol 2 and 3.

Next step extends the dataset to 2nd volume but using the secondary space value.

Next step extends the dataset to 3rd volume again using the secondary space value.

The 4th step continues using the 3rd volume until in runs out of extents.

Now if DISP=MOD was used it continues writing to VOL 1 until it reaches 16 extents and then it continues with VOL2 until it reaches 16 extents and then onto VOL3.

The primary space is only ever used on the first volume.


Gerry
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Aug 14, 2008 5:21 pm
Reply with quote

Gerry,

Are you using NON SMS managed DASD, or SMS managed ?
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Aug 14, 2008 5:24 pm
Reply with quote

Hi Expat,

I made sure I used non sms managed volumes. when I tested against SMS managed volumes the catalog only showed 1 volume.


Gerry
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Aug 14, 2008 5:31 pm
Reply with quote

OK OK, only asking icon_biggrin.gif

The problem is with the way that the file has been set up, and/or used. It is pre allocated for the second and subsequent steps, and as stated in my post above, will not extend on the first and second volumes.

Methinks that your use of DISP=MOD would be the best solution, except that I'm never happy using DISP=MOD. Probably stems from my early years when hardware and media were not so damned reliable.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Aug 14, 2008 5:55 pm
Reply with quote

Hi Expat,

I agree with you with DISP=MOD, the minute it runs out of space the file is useless, some of the data has already been appended. icon_smile.gif icon_smile.gif icon_smile.gif

A pain in the SAS


Gerry
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Aug 14, 2008 6:10 pm
Reply with quote

Quote:
A pain in the SAS

Yeah, and a couple other places too icon_wink.gif

Maybe this is a job for GDG man !!!! Probably the best way forward, using RLSE with the space so no over allocations and no need for MOD.
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 Goto page 1, 2  Next

 


Similar Topics
Topic Forum Replies
No new posts INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts SCOPE PENDING option -check data DB2 2
No new posts Multiple table unload using INZUTILB DB2 2
Search our Forums:

Back to Top