View previous topic :: View next topic
|
Author |
Message |
shanbalasay
New User
Joined: 22 May 2007 Posts: 19 Location: Belfast, UK
|
|
|
|
Is there a utility in JCL or a REXX code that would check the below
1. Amount of Free Space (ie CYLS or TRK, etc) available
2. % Utilization
Basically, I'd like to automate such a process so that I could know well ahead of 100% utilisation. I could then allocate more space and in turn prevent my production jobs from abending. |
|
Back to top |
|
|
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1193 Location: Dublin, Ireland
|
|
|
|
Could you not just use PDSe rather than PDS?
Garry. |
|
Back to top |
|
|
shanbalasay
New User
Joined: 22 May 2007 Posts: 19 Location: Belfast, UK
|
|
|
|
Hi Garry,
I'm actually looking for a method or approach (JCL Utility or a REXX code) that would fetch me the required information either from a PDSE or a PDS.
I'd be very grateful if I get information to handle both PDSE and PDS as well.
Thanks
Bala |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Questions that come to mind:
1) Why not use PDSe (as Garry suggested)?
2) Why would a production job be sending output to a PDS member?
3) Why not put a space parameter on the production job so if it does go into extents it can get whatever you deem necessary?
4) Why bother, anyway? No matter what you do sooner or later a bigger production file will be processed and force a space abend for the PDS.
5) Why not get the site using STOP X37 or something similar? |
|
Back to top |
|
|
shanbalasay
New User
Joined: 22 May 2007 Posts: 19 Location: Belfast, UK
|
|
|
|
Hi Robert,
Answers to your Questions:
1) Why not use PDSe (as Garry suggested)?
There are 1000s of PDSs or PDSe's already in production at the moment. They are being used on a regular basis
2) Why would a production job be sending output to a PDS member?
100s of members are being copied to production libraries (PDS or PDSe) which we support
3) Why not put a space parameter on the production job so if it does go
into extents it can get whatever you deem necessary?
I might agree to this suggestion. But it'd mean enhancement on part of the software product that we support.
4) Why bother, anyway? No matter what you do sooner or later a bigger production file will be processed and force a space abend for the PDS.
I have to be proactive in finding if a production library is nearing 100% utilization I'd have to place a request to Mainframe Admin to increase the space so that the product I support is not blamed for it. Secondly, the users of the product wouldnt face the problem during the critical time of production implementation
5) Why not get the site using STOP X37 or something similar?
This is something which I'm not aware of.
Well, all that I'm looking for is any simple JCL utility or a REXX/CLIST code or any other simple method with which I can use to retrieve the dataset information (Only the space parameters) and check for the available space. If its around 85% to 90% utilised, I could then take a precautionary step to increase the space by 20% so that if there are any production implementation going on, it'd not affect them.
If there'd be a possibility of doing this, I'd then think of automating the process weekly or monthly and receive a report through email from the mainframes.
Your valuable suggestions would be very much welcome. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
You could write one in REXX using LISTDSI. |
|
Back to top |
|
|
shanbalasay
New User
Joined: 22 May 2007 Posts: 19 Location: Belfast, UK
|
|
|
|
Hi Douglas,
Thanks for clue. I could get the below information with the LISTDSI and its related variables; SYSDSORG, SYSRECFM, SYSUNITS, SYSALLOC, SYSUSED, SYSPRIMARY, SYSSECONDS
Dataset Organisation : PO
Record Format : U
Space Units : CYLINDER
Allocation (Space units) : 6
Allocation used (Space units): N/A
Primary Alloc. (Space units) : 5
Sec. Alloc. (Space units) : 20
However, I couldnt find the variable that'd return % Utilisation. I'll continue to search for it.
Thanks for your help.
Thanks to Garry & Robert too. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
Think about it a little. Assuming the dataset does not span multiple packs.
If I remember right total space = primary + (16 * secondary)
% Used = used space / total space * 100
I think you have all of the number you need.
For a PDS you might want to check the percent of directory space used also. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Douglas: there is one complicating factor: a primary allocation may be spread across as many as 5 extents, which only leaves 11 extents for secondary allocations. This normally only happens for highly fragmented packs but I have seen it happen. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
Yes, that is right.
What about Total space = Used + ((17 - sysextents) * secondary) |
|
Back to top |
|
|
|