Board index » delphi » Avoiding "Directory Busy" after crash

Avoiding "Directory Busy" after crash

If I prematurely abort (with Crtl-F2, or a crash) a D5 program using the
BDE, frequently I have to reboot because I get an exception "Directory is
busy" the next time I try to run the program.

Is there a file (or quick program) I can run that can mark the directory as
"unbusy" so I don't have to reboot?

Tom

 

Re:Avoiding "Directory Busy" after crash


Are you using Paradox tables?  If so, try deleting every *.lck files.

Re:Avoiding "Directory Busy" after crash


If you are using Paradox tables you may be able to solve the problem by
deleting the .LCK files in the data and private directories. If that does
not work you will have to shutdown and restart Delphi.

--
Bill

Re:Avoiding "Directory Busy" after crash


ChimneySweep? addresses this problem, for 16-bit programs, by unloading
the BDE modules that may remain in-memory after a crash.  This does not
apply for 32-bit (e.g. D5) programs.

The other step is to remove .LCK and .NET files.  This succeeds only if
the files are not in-use; therefore it is safe.  These files contain the
lock-table entries that can leave a directory "busy."  

Usually the directory that is "busy" is the application's private
directory, which by definition can be used by only one application at a
time.

Quote
>Tom wrote:

> If I prematurely abort (with Crtl-F2, or a crash) a D5 program using the
> BDE, frequently I have to reboot because I get an exception "Directory is
> busy" the next time I try to run the program.

> Is there a file (or quick program) I can run that can mark the directory as
> "unbusy" so I don't have to reboot?

------------------------------------------------------------------
Sundial Services :: Scottsdale, AZ (USA) :: (480) 946-8259
mailto:i...@sundialservices.com  (PGP public key available.)
Quote
> Fast(!), automatic table-repair with two clicks of the mouse!
> ChimneySweep(R):  "Click click, it's fixed!" {tm}
> http://www.sundialservices.com/products/chimneysweep

Other Threads