Disk Space Maintenence

hooichia82

New Member
Hi,

I'm facing insufficient disk space for my current server. So, I'm doing housekeeping for my current ERP System which is MFG/Pro. However, after I deleting quite a lot of data from my database the free space still remain the same (when i issue command "df" to check my disk free space). So, my questions are:

1) Where did all these empty spaces (after delete a database record) goes to?
2) Will the PROGRESS uses this empty space again if I add in new records in the future?
3) How can I estimate the free space that I still have since it doesn't release the free space to my OS level?

Below are some details of my system:
Progress version: 9.1D
OS: AIX 4.3.3
ERP: MFG/PRO


Thank you.
 
A normal way to gain diskspace would be to buy more disks or cleanup the filesystem :)

If you delete data from the database then the empty blocks will be moved to the free chain. These blocks will be reused by the database engine.

You can look with promon (option 7) to see how much space you have left for storage in your database structure. Look at HWM, total database blocks and free blocks below HWM.

or you could use this:
Code:
DEFINE VARIABLE iUsed AS DECIMAL   FORMAT 'ZZZ,ZZZ,ZZZ,ZZ9' NO-UNDO.
DEFINE VARIABLE iAvail AS DECIMAL  FORMAT 'ZZZ,ZZZ,ZZZ,ZZ9'  NO-UNDO.
OUTPUT TO dbsize.txt.
FOR EACH _Area NO-LOCK: 
    DISPLAY _Area-name LABEL 'Area Name' WITH 2 COLUMNS. 
 
    FIND _Areastatus WHERE _Areastatus-Areanum = _Area._Area-number NO-LOCK. 
    ASSIGN iUsed = (_AreaStatus-Hiwater - _AreaStatus-Freenum)
           iUsed = iUsed * _Area-blocksize
           iAvail = (_AreaStatus-Totblocks - _AreaStatus-Hiwater - _AreaStatus-Extents +
                     _AreaStatus-Freenum)
           iAvail = iAvail * _Area-blocksize.
 
    DISPLAY _AreaStatus-Totblocks LABEL 'Total Blocks' FORMAT '>,>>>,>>9' 
            _AreaStatus-Extents LABEL 'Extent Blocks' 
            _AreaStatus-Totblocks - _AreaStatus-Hiwater - _AreaStatus-Extents LABEL 'Empty Blocks' 
            _AreaStatus-Freenum LABEL 'Free Blocks' 
            _AreaStatus-Hiwater - _AreaStatus-Freenum LABEL 'Active Blocks' 
            _Area-blocksize LABEL 'Block Size' 
            iUsed LABEL 'Used space' 
            iAvail LABEL 'Avail space' WITH 3 COLUMNS. 
/*    FOR EACH _AreaExtent OF _Area NO-LOCK:  */
/*        DISPLAY _Extent-path FORMAT 'x(60)'.  */
/*    END.  */
 
END. 
 
OUTPUT CLOSE.

For a more detailed explanation on storage and use of database blocks search the PEG archives, PSDN and progresstalk. There have been many threads on this subject and it is pretty well documented.

Furthermore Gus wrote a clear article on how the database engine uses space. It is an old document and things have changed but it should give you a good idea on how the database engine handles storage of data:
http://www.peg.com/techpapers/monographs/space/space.html


HTH,

Casper.
 
BTW, did I already mention that you use a retired Progress version which really wants to be upgraded by you? Same applies for your OS.

(sorry, had to say that :awink:).

Casper.
 
While all that Casper says is useful information, the short answer is that deleting information from the database does not shrink the database, it merely moves records from used to a free chain. To actually shrink the database, you have to do a dump and load into a smaller structure.

But, with the price of disks these days, I don't know why you would bother.
 
yes, I knew that. However, I'm not the one who can make decision to do system upgrade :(. So, I need to perform some database maintenance to make sure that my database is healthy. But, I'm new in Progress Administration :confused:

Can anyone tell me that what should I do/check to make sure that my database is always healthy? Do Progress database has any limitation (database file size, index size...)?
 
Back
Top