Operating System - OpenVMS
1753947 Members
7429 Online
108811 Solutions
New Discussion юеВ

HP DFO for OpenVMS ad open files

 
SOLVED
Go to solution
Douglass Anderson
Regular Advisor

HP DFO for OpenVMS ad open files

What happens when DFO (disk file optimizer) finds an open file? can it be told to try N times or always skip it. or wait until a timeout period?
5 REPLIES 5
David B Sneddon
Honored Contributor
Solution

Re: HP DFO for OpenVMS ad open files

Douglass,

I understand that DFO will *not* attempt to process
a file that is open. Also, if a process tries to access
a file that DFO is currently working on, it will cease
further activity on that file.
This behaviour is not configurable.

Dave
John Gillings
Honored Contributor

Re: HP DFO for OpenVMS ad open files

Douglass,

DFO doesn't "test" files, it just tries to move candidate files using the XQP MOVEFILE primitive. If the file is open, the operation fails with SS$_ACCONFLICT.

Depending on the requested defrag level, DEFRAG operates in several phases. Depending on the level of fragmentation of a file, it may be a candidate in any or all of the phases, so there may be multiple attempts on an open file. However, DEFRAG has no mechanism for specifying a retry count, or a timeout period.

If you specify DEFRAG VOL/LOG=file/FULL you can see exactly what happens to each file at each phase.

Remember you can "DEFRAG FILE filespec" to do individual files so you can implement your own retry.
A crucible of informative mistakes
comarow
Trusted Contributor

Re: HP DFO for OpenVMS ad open files

DFO does not touch open files. If you know a file is closed you can always tell it to defrag that file, or even copy/cont.

However, better to prevent fragmentation by preallocating file space, using fdl to create files, larger extents, or whatever means to prevent the fragmentation in the first place. Try never to let a third generation language extend a file bit by bit.

Bob
comarow
Trusted Contributor

Re: HP DFO for OpenVMS ad open files

A couple of extra thoughts.

If it's the system disk, boot minimum, and more files will be closed.

Or shut down the application, and it will hit the application.

You will have to manually start and direct DFO. I've done that as well with Diskeeper to hit constantly open files.

Certain files extend in tiny chunks, like accountng.dat, operator.log, so even if you boot min, turn off acounting, set account/new, create new error logs.

Of course a min boot would not open these files.
Douglass Anderson
Regular Advisor

Re: HP DFO for OpenVMS ad open files

solved