HP OpenVMS Systems

ask the wizard
Content starts here

PURGE performance?

» close window

The Question is:

purge command is hanging up ran this command
$ PURGE/KEEP=2 $2$DIA1:[*...]
vax HUNG FOR OVER 22hrs. PLEASE advise.

The Answer is :

    The Wizard suspects that there are very large directories on $2$DIA1:
    As directory size increases, wildcard DELETE performance degrades in a
    rather embarrasingly non-linear manner. For directories over 2000
    blocks in size, elapsed times for DELETE *.*;* measured in DAYS are not
    There are a number of remedies. First, if you want to delete the entire
    contents of a large directory, the DFU utility on the Freeware CD will
    complete the job substantially faster than DELETE. Other than that,
    with a bit of work you can invert the order that files are deleted. In
    your case, generate a directory listing of the most recent version of
    files in the large directory using:
    $ DIRECTORY/NOHEAD/NOTRAIL/OUTPUT=file $2$DIA1:[large-directory]*.*;
    Use SORT to reverse the order of files, then process each line to add
    a PURGE command at the beginning and remove the version number.
    Processing the files in reverse order will greatly reduce the run time.
    For the future, the good news is that performance of large directories
    is substantially better under the new ODS-5 file system.

answer written or last revised on ( 17-JAN-2000 )

» close window