Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

VSAM Space Allocation

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
mrgnndhmk

New User


Joined: 01 Feb 2006
Posts: 47
Location: India

PostPosted: Sat Apr 22, 2017 12:42 am    Post subject: VSAM Space Allocation
Reply with quote

Hi All,
I searched in the forum for my answers but I did not quite get it. Therefore, posting the questions.

1. In LISTCAT, I have the following scenarios
Code:

1. HI-A-RBA = HI-U-RBA  and FREESPC > 0
2. HI-A-RBA <> HI-U-RBA and FREESPC <> (HI-A-RBA - HI-U-RBA)
3. HI-A-RBA <> HI-U-RBA and FREESPC = (HI-A-RBA - HI-U-RBA))


On what basis FREESPC could be different from HI-A-RBA - HI-U-RBA?

Should I take the RBA from Allocation section or the Volume section?

Ultimately I want one single method to compute the Free Space/Used Space for the VSAM Files.


I have given example for each of the above scenario

Scenario 1 (Data) & 3 (Index):

Code:

  LISTCAT ENTRIES(PAD.ADPOUR.KSDS                             ) ALL
0CLUSTER ------- PAD.ADPOUR.KSDS
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
        RELEASE----------------2     EXPIRATION------0000.000
      SMSDATA
        STORAGECLASS -------PROD     MANAGEMENTCLASS-----PROD
        DATACLASS --------(NULL)     LBACKUP ---0000.000.0000
        CA-RECLAIM---------(YES)
        EATTR-------------(NULL)
        BWO STATUS------00000000     BWO TIMESTAMP---00000 00:00:00.0
        BWO---------------(NULL)
      RLSDATA
        LOG ----------------(NULL)   RECOVERY REQUIRED --(NO)     FRLOG ------------(NULL)
        VSAM QUIESCED -------(NO)    RLS IN USE ---------(NO)     LOGREPLICATE-------------(NO)
0       LOGSTREAMID-----------------------------(NULL)
        RECOVERY TIMESTAMP LOCAL-----X'0000000000000000'
        RECOVERY TIMESTAMP GMT-------X'0000000000000000'
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        DATA-----PAD.ADPOUR.DATA
        INDEX----PAD.ADPOUR.INDEX
0   DATA ------- PAD.ADPOUR.DATA
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      4
0       RELEASE----------------2     EXPIRATION------0000.000
        ACCOUNT-INFO-----------------------------------(NULL)
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        CLUSTER--PAD.ADPOUR.KSDS
      ATTRIBUTES
        KEYLEN-----------------6     AVGLRECL--------------30     BUFSPACE-----------40960     CISIZE-------------18432
        RKP--------------------0     MAXLRECL--------------30     EXCPEXIT----------(NULL)     CI/CA-----------------45
        SHROPTNS(2,3)      SPEED     UNIQUE           NOERASE     INDEXED       NOWRITECHK     UNORDERED        NOREUSE
        NONSPANNED
      STATISTICS
        REC-TOTAL----------37331     SPLITS-CI--------------4     EXCPS---------------1370
        REC-DELETED----------187     SPLITS-CA--------------1     EXTENTS----------------3
        REC-INSERTED---------332     FREESPACE-%CI----------1     SYSTEM-TIMESTAMP:
        REC-UPDATED------------0     FREESPACE-%CA----------0          X'C83F9CD5A79A3280'
        REC-RETRIEVED-------3743     FREESPC----------1271808
      ALLOCATION
        SPACE-TYPE------CYLINDER     HI-A-RBA---------2488320
        SPACE-PRI--------------1     HI-U-RBA---------2488320
        SPACE-SEC--------------1
      VOLUME
        VOLSER------------DOF087     PHYREC-SIZE--------18432     HI-A-RBA---------2488320     EXTENT-NUMBER----------3
        DEVTYPE------X'3010200F'     PHYRECS/TRK------------3     HI-U-RBA---------2488320     EXTENT-TYPE--------X'00'
        VOLFLAG------------PRIME     TRACKS/CA-------------15
        EXTENTS:
        LOW-CCHH-----X'003E0000'     LOW-RBA----------------0     TRACKS----------------15
        HIGH-CCHH----X'003E000E'     HIGH-RBA----------829439
        LOW-CCHH-----X'00440000'     LOW-RBA-----------829440     TRACKS----------------15
        HIGH-CCHH----X'0044000E'     HIGH-RBA---------1658879
        LOW-CCHH-----X'00610000'     LOW-RBA----------1658880     TRACKS----------------15
        HIGH-CCHH----X'0061000E'     HIGH-RBA---------2488319
0   INDEX ------ PAD.ADPOUR.INDEX
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
        RELEASE----------------2     EXPIRATION------0000.000
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        CLUSTER--PAD.ADPOUR.KSDS
      ATTRIBUTES
        KEYLEN-----------------6     AVGLRECL---------------0     BUFSPACE---------------0     CISIZE--------------1024
        RKP--------------------0     MAXLRECL------------1017     EXCPEXIT----------(NULL)     CI/CA-----------------33
        SHROPTNS(2,3)   RECOVERY     UNIQUE           NOERASE     NOWRITECHK     UNORDERED     NOREUSE
      STATISTICS
        REC-TOTAL--------------4     SPLITS-CI--------------1     EXCPS----------------432     INDEX:
        REC-DELETED------------0     SPLITS-CA--------------0     EXTENTS----------------1     LEVELS-----------------2
        REC-INSERTED-----------0     FREESPACE-%CI----------0     SYSTEM-TIMESTAMP:            ENTRIES/SECT-----------6
        REC-UPDATED------------6     FREESPACE-%CA----------0          X'C83F9CD5A79A3280' SEQ-SET-RBA----------------0
        REC-RETRIEVED----------0     FREESPC------------29696                              HI-LEVEL-RBA------------2048
      ALLOCATION
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      5
0       SPACE-TYPE---------TRACK     HI-A-RBA-----------33792
        SPACE-PRI--------------1     HI-U-RBA------------4096
        SPACE-SEC--------------1
      VOLUME
        VOLSER------------DOF087     PHYREC-SIZE---------1024     HI-A-RBA-----------33792     EXTENT-NUMBER----------1
        DEVTYPE------X'3010200F'     PHYRECS/TRK-----------33     HI-U-RBA------------4096     EXTENT-TYPE--------X'00'
        VOLFLAG------------PRIME     TRACKS/CA--------------1
        EXTENTS:
        LOW-CCHH-----X'000B0007'     LOW-RBA----------------0     TRACKS-----------------1
        HIGH-CCHH----X'000B0007'     HIGH-RBA-----------33791
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      6
0         THE NUMBER OF ENTRIES PROCESSED WAS:
                    AIX -------------------0
                    ALIAS -----------------0
                    CLUSTER ---------------1
                    DATA ------------------1
                    GDG -------------------0
                    INDEX -----------------1
                    NONVSAM ---------------0
                    PAGESPACE -------------0
                    PATH ------------------0
                    SPACE -----------------0
                    USERCATALOG -----------0
                    TAPELIBRARY -----------0
                    TAPEVOLUME ------------0
                    TOTAL -----------------3
0         THE NUMBER OF PROTECTED ENTRIES SUPPRESSED WAS 0
0IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 0
0


Scenario 2 (Data) & 3 (Index):

Code:

  LISTCAT ENTRIES(PAD.ADRSLT.KSDS                             ) ALL
0CLUSTER ------- PAD.ADRSLT.KSDS
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
        RELEASE----------------2     EXPIRATION------0000.000
      SMSDATA
        STORAGECLASS -------PROD     MANAGEMENTCLASS-----PROD
        DATACLASS --------(NULL)     LBACKUP ---0000.000.0000
        CA-RECLAIM---------(YES)
        EATTR-------------(NULL)
        BWO STATUS------00000000     BWO TIMESTAMP---00000 00:00:00.0
        BWO---------------(NULL)
      RLSDATA
        LOG ----------------(NULL)   RECOVERY REQUIRED --(NO)     FRLOG ------------(NULL)
        VSAM QUIESCED -------(NO)    RLS IN USE ---------(NO)     LOGREPLICATE-------------(NO)
0       LOGSTREAMID-----------------------------(NULL)
        RECOVERY TIMESTAMP LOCAL-----X'0000000000000000'
        RECOVERY TIMESTAMP GMT-------X'0000000000000000'
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        DATA-----PAD.ADRSLT.DATA
        INDEX----PAD.ADRSLT.INDEX
0   DATA ------- PAD.ADRSLT.DATA
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      7
0       RELEASE----------------2     EXPIRATION------0000.000
        ACCOUNT-INFO-----------------------------------(NULL)
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        CLUSTER--PAD.ADRSLT.KSDS
      ATTRIBUTES
        KEYLEN----------------11     AVGLRECL-------------640     BUFSPACE-----------43008     CISIZE--------------7168
        RKP--------------------8     MAXLRECL-------------640     EXCPEXIT----------(NULL)     CI/CA----------------105
        SHROPTNS(2,3)      SPEED     UNIQUE           NOERASE     INDEXED       NOWRITECHK     UNORDERED        NOREUSE
        NONSPANNED
      STATISTICS
        REC-TOTAL---------278105     SPLITS-CI--------------0     EXCPS---------------2152
        REC-DELETED------------0     SPLITS-CA--------------0     EXTENTS----------------1
        REC-INSERTED-----------0     FREESPACE-%CI---------23     SYSTEM-TIMESTAMP:
        REC-UPDATED------------0     FREESPACE-%CA----------8          X'CD5BB12953A60E00'
        REC-RETRIEVED----------0     FREESPC---------40578048
      ALLOCATION
        SPACE-TYPE------CYLINDER     HI-A-RBA-------289766400
        SPACE-PRI------------385     HI-U-RBA-------270197760
        SPACE-SEC-------------43
      VOLUME
        VOLSER------------DOF332     PHYREC-SIZE---------7168     HI-A-RBA-------289766400     EXTENT-NUMBER----------1
        DEVTYPE------X'3010200F'     PHYRECS/TRK------------7     HI-U-RBA-------270197760     EXTENT-TYPE--------X'40'
        VOLFLAG------------PRIME     TRACKS/CA-------------15
        EXTENTS:
        LOW-CCHH-----X'03E10000'     LOW-RBA----------------0     TRACKS--------------5775
        HIGH-CCHH----X'0561000E'     HIGH-RBA-------289766399
0   INDEX ------ PAD.ADRSLT.INDEX
      IN-CAT --- UCAT.ORDER.PROD
      HISTORY
        DATASET-OWNER-----(NULL)     CREATION--------2010.241
        RELEASE----------------2     EXPIRATION------0000.000
      PROTECTION-PSWD-----(NULL)     RACF----------------(NO)
      ASSOCIATIONS
        CLUSTER--PAD.ADRSLT.KSDS
      ATTRIBUTES
        KEYLEN----------------11     AVGLRECL---------------0     BUFSPACE---------------0     CISIZE--------------2048
        RKP--------------------8     MAXLRECL------------2041     EXCPEXIT----------(NULL)     CI/CA-----------------21
        SHROPTNS(2,3)   RECOVERY     UNIQUE           NOERASE     NOWRITECHK     UNORDERED     NOREUSE
      STATISTICS
        REC-TOTAL------------362     SPLITS-CI--------------0     EXCPS---------------1814     INDEX:
        REC-DELETED------------0     SPLITS-CA--------------0     EXTENTS----------------1     LEVELS-----------------3
        REC-INSERTED-----------0     FREESPACE-%CI----------0     SYSTEM-TIMESTAMP:            ENTRIES/SECT----------10
        REC-UPDATED------------0     FREESPACE-%CA----------0          X'CD5BB12953A60E00' SEQ-SET-RBA----------------0
        REC-RETRIEVED----------0     FREESPC-----------118784                              HI-LEVEL-RBA----------415744
      ALLOCATION
        SPACE-TYPE---------TRACK     HI-A-RBA----------860160
        SPACE-PRI-------------20     HI-U-RBA----------741376
        SPACE-SEC--------------3
      VOLUME
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      8
0       VOLSER------------DOF332     PHYREC-SIZE---------2048     HI-A-RBA----------860160     EXTENT-NUMBER----------1
        DEVTYPE------X'3010200F'     PHYRECS/TRK-----------21     HI-U-RBA----------741376     EXTENT-TYPE--------X'00'
        VOLFLAG------------PRIME     TRACKS/CA--------------1
        EXTENTS:
        LOW-CCHH-----X'00300000'     LOW-RBA----------------0     TRACKS----------------20
        HIGH-CCHH----X'00310004'     HIGH-RBA----------860159
1IDCAMS  SYSTEM SERVICES                                           TIME: 14:37:40        04/21/17     PAGE      9
0         THE NUMBER OF ENTRIES PROCESSED WAS:
                    AIX -------------------0
                    ALIAS -----------------0
                    CLUSTER ---------------1
                    DATA ------------------1
                    GDG -------------------0
                    INDEX -----------------1
                    NONVSAM ---------------0
                    PAGESPACE -------------0
                    PATH ------------------0
                    SPACE -----------------0
                    USERCATALOG -----------0
                    TAPELIBRARY -----------0
                    TAPEVOLUME ------------0
                    TOTAL -----------------3
0         THE NUMBER OF PROTECTED ENTRIES SUPPRESSED WAS 0
0IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 0
Back to top
View user's profile Send private message

Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1676
Location: NY,USA

PostPosted: Sat Apr 22, 2017 12:54 am    Post subject:
Reply with quote

Please see if you learn anything from here.
VSAM Demystified
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8028
Location: Bellevue, IA

PostPosted: Sat Apr 22, 2017 7:31 am    Post subject:
Reply with quote

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.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Need help in estimating space of unlo... ashek15 IMS DB/DC 12 Fri Apr 07, 2017 5:11 am
No new posts Need inputs on Space requirement and... ashek15 IMS DB/DC 0 Sat Apr 01, 2017 8:26 am
No new posts Updating a VSAM file with DISP=OLD sheersh JCL & VSAM 8 Tue Mar 14, 2017 6:14 pm
No new posts SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts VSAM RLS=NRI while doing IDCAMS sheersh JCL & VSAM 1 Tue Mar 07, 2017 1:55 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us