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

HOW TO KNOW how many space is used in VSAM DFHTEMP file


IBM Mainframe Forums -> CICS
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
wang_f_y1
Warnings : 1

New User


Joined: 16 May 2008
Posts: 47
Location: shenzhen

PostPosted: Mon Sep 07, 2009 10:27 pm
Reply with quote

hi

I list my dfhtemp file information.but it showed below.

Tracks %Used
------------

4125 ?

HOW TO KNOW how many space is used in this VSAM DFHTEMP file.
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: Mon Sep 07, 2009 10:56 pm
Reply with quote

Isn't the 4125 enough to know? Since temporary storage usage varies as the CICS region is running, why on earth are you wanting to know at a single point in time about TS usage?

Anyway, from the manual:
Quote:
Allocation of temporary storage

Temporary storage requests on a cold-started or initial-started system (that is with no existing auxiliary data) are allocated from the start of DFHTEMP (the temporary storage data set used for storing auxiliary data). They are processed by the CICS temporary storage domain. The first control interval within DFHTEMP is used until a WRITEQ is issued that is too long to fit into the remaining space. Temporary storage processing then switches to use control interval two, and so on. This process continues until all of the control intervals in DFHTEMP have data written to them.

WRITEQ requests after this point are directed back to the start of the data set. Temporary storage processing maintains a bytemap representing the free space available within each control interval in the data set at any time. Temporary storage processing now starts interrogating the bytemap to find a control interval that can accommodate new data at, or near to, the start of DFHTEMP. The reasoning behind this is that by now, queues written earlier could have been deleted. Such deleted data remains in control intervals but is no longer required. If the bytemap shows that a control interval contains enough space, temporary storage processing reads it into a temporary storage buffer, compresses it to move all valid records to the start of the control interval, and uses the remaining contiguous space to store the data from the new request.

In earlier versions of CICS (CICS/ESA® 4.1 and earlier), temporary storage processing reserved a proportion of the control intervals in DFHTEMP to facilitate spanned record processing. Large records, that needed to be spanned across more than one control interval, generated special header records used to reference the spanned data, and these special header records required a whole control interval. To reserve space for the special header records, when 75% of the control intervals in DFHTEMP had data written to them, temporary storage processing left the remaining control intervals empty and began to reuse space from the start of the data set. This was known as the "75% rule". In CICS Transaction Server, special header records are no longer required for such large records, so temporary storage processing writes to all the control intervals in DFHTEMP before it attempts to reuse space. If all the control intervals in DFHTEMP have been used and an empty control interval is required, it can be taken from secondary extent storage defined for the data set.
So unless you can write some code to go into the areas of CICS that IBM specifically does not want you going into, you cannot get a precise answer.
Back to top
View user's profile Send private message
wang_f_y1
Warnings : 1

New User


Joined: 16 May 2008
Posts: 47
Location: shenzhen

PostPosted: Tue Sep 08, 2009 8:38 am
Reply with quote

hi form DFHTEMP defined
DEFINE CLUSTER(NAME(xxxx.DFHTEMP)-
RECORDSIZE(4089,4089)-
CYL(275 5)-
NIXD -
CISZ(4096)-
VOLUME(aaaa) SHR(2 3)) -
DATA(NAME(xxxx.DFHTEMP.DATA)-
UNIQUE)

i think the manual just said CISZ,if we use up the first CISZ,it can use the seond CISZ.but i want to know how many space was used for the whole defined DFHTEMP( notice:CYL(275 5)) ),I don't know how many cylider was used.

it showed

%Used ?
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: Tue Sep 08, 2009 2:53 pm
Reply with quote

Did you not read the manual excerpt I quoted? Temporary storage is circular -- CICS writes until it hits the end of the file, then starts again at the beginning. There is no way to tell exactly where CICS started writing and how far it has written to, so there is no way to tell how much of it is used. Period. All you can say is that the allocated space is 275 cylinders.
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: Tue Sep 08, 2009 4:58 pm
Reply with quote

I also suspect you're a victim of telling us how to get what you want rather than telling us what you're attempting to achieve. If, for example, all you want to do is know the amount of temporary storage space used by CICS, you can (if authorized and if it is set up), run the STAT transaction in the CICS region and part of the STAT output is:
Code:
Temporary Storage
_________________
  Put/Putq main storage requests . . . . . :              0
  Get/Getq main storage requests . . . . . :              0
  Peak storage used for TS Main. . . . . . :              0K
  Current storage used for TS Main . . . . :              0K

  Put/Putq auxiliary storage requests. . . :              2
  Get/Getq auxiliary storage requests. . . :              1

  Times temporary storage queue created. . :              2
  Peak temporary storage queues in use . . :              5
  Current temporary storage queues in use. :              5
  Items in longest queue . . . . . . . . . :              1
  Control interval size. . . . . . . . . . :          4,096
  Control intervals in the DFHTEMP dataset :         15,659
  Peak control intervals used. . . . . . . :             42
  Current control intervals in use . . . . :             42
  Available bytes per control interval . . :          4,032
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 -> CICS

 


Similar Topics
Topic Forum Replies
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
Search our Forums:

Back to Top