Volume 7, Number 19 -- May 16, 2007

Another Way to Retrieve i5 System Storage Space

Published: May 16, 2007

Hey, Joe:

You should adjust your focus in your article on retrieving system storage space. The first step in dealing with critical storage errors is not to clear up past problems. The first step is to understand where the space is being used now. The Retrieve Disk Information command and the Print Disk Information command are valuable in finding storage hogs, particularly in the Integrated File System (IFS). Maybe you should explore this possibility, too.


Not being familiar with the Retrieve Disk Information (RTVDSKINF) and Print Disk Information (PRTDSKINF) commands, I decided to run these commands on my system and see what they bring to the table in identifying disk storage hogs.

The first step in analyzing disk storage Rob's way is to run the RTVDSKINF command. RTVDSKINF collects information about your disk drive usage and stores it in a database file in the QUSRSYS library. Once the information is captured, it can be parsed and analyzed by using the PRTDSKINF command. You could also try to write your own query to look at the information any way you want, but you will probably want to try using PRTDSKINF first to see if you can get the information you want without too much effort.

RTVDSKINF is fairly easy to run, but it cannot be run interactively. It must be run as a batch job. For my situation, I submitted RTVDSKINF to batch by using the following Submit Job command (SBMJOB).


In this default configuration, RTVDSKINF retrieves disk storage information for your system ASP, as well as for all other secondary ASPs on your system. The System ASP is numbered as ASP 1, while the other ASPs are numbered from 2 through 32. There is also a configuration for running RTVDSKINF for independent named ASP devices.

RTVDSKINF information is generally kept in a file called QAEZDISK in the QUSRSYS library, if you're collecting information for the system and basic ASPs. If you're collecting information for an independent named ASP device, the resulting file will also reside in QUSRSYS and it will be named QAEZnnnn, where nnnn = the ASP number of the independent ASP that you are analyzing (Independent ASPs have ASP numbers greater than 32). Every time you run RTVDSKINF, it overwrites any QAEZDISK information that may have been previously saved.

But be careful with RTVDSKINF if you're short on disk space. Because it contains entries for most objects on your system, the resulting QAEZDISK file can consume a lot of disk space all by itself. When I ran RTVDSKINF on my system, my QAEZDISK file recorded 825,000 records and the database file itself was over 170 Mb. While this may not seem like that big an issue, it may make a difference if you're trying to reduce system storage after your system exceeds 90 percent disk drive usage.

Once the batch job running RTVDSKINF ends, you can start looking at your system storage by using the Print Disk Information command (PRTDSKINF). Depending on how you run PRTDSKINF, you can create five different reports that tell you which objects, users, libraries, or folders are taking up the most storage space on your system. The first three pages of each PRTDSKINF report contain a summary of how your system as a whole uses disk storage. This summary report includes how much space is allocated to user libraries, user directories, folders and documents, and other system objects. By looking at the summary first, you can determine what types of objects are consuming the most disk space. Knowing this, you can then go into the detailed reports and retrieve which individual objects, libraries, folders, or users are using the most space. You can then enter the following PRTDSKINF commands to produce each type of report.

1.    To run a report detailing the amount of storage your i5/OS libraries are using, run this command:


This report will show you disk drive usage for each library on your system, so that you can identify which libraries are using the most storage. You can also parse this information further by entering values for which libraries you want to view in the report (the Libraries parameter, LIB), which objects or object types to include (the Objects, OBJ, and Object Types, OBJTYPE parameters), the minimum size of object you want to include in the report (the Smallest Size parameter, MINSIZE), or how you want the report sorted (Sort by, SORT). While there aren't a zillion different options for viewing your disk space usage, there are enough so that you can identify which libraries are taking up the most storage and look further for the problem areas.

In my case, I found that one particular user library was taking up 11 percent of my system storage and that my spool file library (QSPL) was taking up another 8 percent of the system. So in order to clear up some disk space, I might examine which files I could reorganize to get rid of deleted records or whether I can even get rid of any unused files in that library. For spooled files, I could set up an automated routine to delete old spooled files in the system or I could use iSeries Navigator or the green screen to manually review my spooled file usage and to delete any files that are no longer needed. Once I know which areas are using the most disk space, I can concentrate on those areas to reclaim the most storage.

2.    To run a report detailing which documents or folders are using the most disk space, run PRTDSKINF this way:


In my case, QDLS documents and AS/400 Integrated File System objects didn't account for that much disk storage but it may be different for your system depending on what products you have installed. If you're using your system as a Lotus Domino Server, for example, you may have a number of database folders that are consuming a lot of disk. WebSphere files can also consume a lot of folder space. Like the libraries report, you can also parse this information according to specific folders or generic folder names (the Folder parameter, FLR), specific documents (Documents parameter, DOC), or to show only those objects that are larger than a minimum size.

3.    To create a report showing how much i5 storage a particular user or users are using, run PRTDSKINF this way:


This will show you a report listing how much storage each particular system user owns. Using this report, you can track down which users are consuming the most disk space. There are options on this report to list out usage by individual user or a generic user name (the Owners parameter, OWN), or by specific objects and object types (again, the OBJ and OBJTYPE parameters).

4.    To create a report showing your largest objects on the system, run PRTDSKINF this way:


This command creates a very large detailed report displaying all the objects on your system, sorted by size from largest to smallest. In my case, my largest object was a journal receiver that was recording changes for a heavily user file (3.5 percent of storage), so I could conceivably reduce disk usage by rethinking my journaling strategy. You can also subset this report to make it smaller by designating that it only display certain object names or generic objects (the Objects parameter, OBJ) or certain types of objects, such as files (the Object Type parameter, OBJTYPE).

5.    To create a report showing only system objects, run PRTDSKINF this way:


This is the least valuable option when trying to retrieve disk space because system objects are more or less a fixed cost on your system that you probably can't cut down on.

Overall, I was pretty impressed with these simple commands and the way they can help me identify storage hogs. I will definitely use them more in the future and I encourage all my readers to experiment with them for disk storage control.



5 Things to Do Before Adding iSeries Disk Capacity

Dealing with Critical Storage Errors, Part 2

Selectively Deleting Spooled Files

Tips for Dealing with Deleted Records in AS/400 Files

To Each Its Own in Spooled File Management

                     Post this story to del.icio.us
               Post this story to Digg
    Post this story to Slashdot

Sponsored By

Top Titles Available at IT Jungle Bookstore

Our most popular titles are available for immediate order
now at the IT Jungle Bookstore.

Browse through our top book picks including
the iSeries Pocket and WebSphere series, and
other books by Brian Kelly.

Visit the IT Jungle bookstore today!

Senior Technical Editor: Ted Holt
Technical Editors: Howard Arner, Joe Hertvik, Shannon O'Donnell, Kevin Vandever
Contributing Technical Editors: Joel Cochran, Wayne O. Evans, Raymond Everhart,
Bruce Guetzkow, Brian Kelly, Marc Logemann, David Morris
Publisher and Advertising Director: Jenny Thomas
Advertising Sales Representative: Kim Reed
Contact the Editors: To contact anyone on the IT Jungle Team
Go to our contacts page and send us a message.

Sponsored Links

Bsafe:  Enterprise security for System i and Linux systems
WorksRight Software:  ZIP code, area codes, Canadian postal codes, CASS certification, and more
COMMON:  Join us at the Annual 2008 conference, March 30 - April 3, in Nashville, Tennessee

IT Jungle Store Top Book Picks

The System i Pocket RPG & RPG IV Guide: List Price, $69.95
The iSeries Pocket Database Guide: List Price, $59.00
The iSeries Pocket Developers' Guide: List Price, $59.00
The iSeries Pocket SQL Guide: List Price, $59.00
The iSeries Pocket Query Guide: List Price, $49.00
The iSeries Pocket WebFacing Primer: List Price, $39.00
Migrating to WebSphere Express for iSeries: List Price, $49.00
iSeries Express Web Implementer's Guide: List Price, $59.00
Getting Started with WebSphere Development Studio for iSeries: List Price, $79.95
Getting Started With WebSphere Development Studio Client for iSeries: List Price, $89.00
Getting Started with WebSphere Express for iSeries: List Price, $49.00
WebFacing Application Design and Development Guide: List Price, $55.00
Can the AS/400 Survive IBM?: List Price, $49.00
The All-Everything Machine: List Price, $29.95
Chip Wars: List Price, $29.95


The Four Hundred
Aldon Acquired by Marlin Equity Partners

Some Thoughts on i5 Spending Patterns

IBM Sees Green in Going Green in Data Centers

Children's Foundation Blossoms from Sirius Computer

The Linux Beacon
Red Hat to Push Desktop Linux with Intel Partnership

RHEL 5: How's It Going?

IBM Sees Green in Going Green in Data Centers

As I See It: Education--the Other Dysfunction

Four Hundred Stuff
Look, Ma, 5250 App Access from Outlook, Google

LANSA Upgrades Modernization Tool

RJS Unveils New Forms, PDF Solutions for System i

NGS Makes DB2/400 Data Accessible from MS Office

Big Iron
Unisys Ports OS 2200 Mainframe Operating System to Xeons

Top Mainframe Stories From Around the Web

Chats, Webinars, Seminars, Shows, and Other Happenings

System i PTF Guide
May 12, 2007: Volume 9, Number 19

May 5, 2007: Volume 9, Number 18

April 28, 2007: Volume 9, Number 17

April 21, 2007: Volume 9, Number 16

April 14, 2007: Volume 9, Number 15

April 7, 2007: Volume 9, Number 14

March 31, 2007: Volume 9, Number 13

The Windows Observer
Patch Tuesday Yields Seven Critical Patches for 19 Flaws

Microsoft Moves Forefront as Security Market Changes

Q&A with HP's Paul Miller: The X64 Server Biz

Microsoft Taps Packeteer for Branch Office Server

The Unix Guardian
IBM Lengthens and Broadens AIX Support on Power Iron

Sun Backs QuickTransit for Sparc to X64 Migration

IBM Sees Green in Going Green in Data Centers

As I See It: Education--the Other Dysfunction

Four Hundred Monitor
Four Hundred Monitor's
Full iSeries Events Calendar


Patrick Townsend & Associates
Guild Companies

Groovy: A Powerful Scripting Language for Java Developers on System i

Old Programs Can Learn to Behave Themselves

Another Way to Retrieve i5 System Storage Space

Four Hundred Guru


From the IT Jungle Forums

How to calculate the last day of the month

iSeries Career training ideas

Authority to IFS

User profile for webserver instances

Subscription Information:
You can unsubscribe, change your email address, or sign up for any of IT Jungle's free e-newsletters through our Web site at http://www.itjungle.com/sub/subscribe.html.

Copyright © 1996-2008 Guild Companies, Inc. All Rights Reserved.
Guild Companies, Inc., 50 Park Terrace East, Suite 8F, New York, NY 10034

Privacy Statement