Quantcast
Channel: IBM Mainframe Computers Forums
Viewing all articles
Browse latest Browse all 8500

JCL & VSAM :: RE: VSAM Space Allocation

$
0
0
Author: Robert Sample
Posted: Sat Apr 22, 2017 7:31 am (GMT 5.5)

First, remember that there is CI freespace and CA freespace. If you specify CI freespace of 20%, that means 20% of each CI is left without any data. If the CI size is 4096 that means about (the VSAM Demystified manual will give you the exact calculation) 820 bytes of each CI is free; if the HI-A-RBA and HI-U-RBA are the same, there is STILL 20% freespace in each CI (unless of course splits occurred).

Second, freespace may be used for records as inserts are done, so freespace may be less than HI-A-RBA minus HI-U-RBA.

Third, freespace in the CI may cause the freespace to be more than HI-A-RBA minus HI-U-RBA.

Quote:
Should I take the RBA from Allocation section or the Volume section?
If you use the Volume section, you will need to find the highest single RBA value (there are a low and high RBA for EACH extent on the volume - if there are more than one volume, you will need to find the highest RBA on ALL volumes). If you compare the Allocation and Volume sections for the LISTCAT output you posted, you will see the HI-A-RBA matches the largest Volume RBA (as long as you add 1 to the Volume RBA). So it doesn't matter which you take as long as you pick the largest Volume RBA.
Quote:
Ultimately I want one single method to compute the Free Space/Used Space for the VSAM Files.
Subtract free space from HI-A-RBA to give Used space (ignore HI-U-RBA). Divide free space by used space. Two simple calculations, one method. Now the question is, what are you going to do with this number? It has little, if any, practical value. Free space needs to be driven by the application; some applications don't need free space while other applications should have substantial CI free space but little CA free space or vice versa and other applications need substantial CI and CA free space.
_________________
TANSTAAFL

The first rule of code reuse is that the code needs to be worth re-using.

"We should forget about small efficiencies, say about 97% of the time: premature optimization is the root of all evil." -- Donald Knuth


Viewing all articles
Browse latest Browse all 8500

Trending Articles