Too Many Files

  • Thread starter Thread starter Johnny
  • Start date Start date
J

Johnny

Why is it when you open a folder with 53,000 files in it Explorer freaks
out and hangs. If I drop to a command promt and try to delete the files
from there is takes over an hour. Am I doing something wrong?
 
Why is it when you open a folder with 53,000 files in it Explorer freaks
out and hangs. If I drop to a command promt and try to delete the files
from there is takes over an hour. Am I doing something wrong?
I might add that it is my Exchange Badmail folder that is producing so
many messages.
 
I'm not sure about Exchange, but I had a similar situation once where I had 20K files or something somewhat similar in one directory. The system did apparently hang, but when I let it run and run (I think overnight) it did come back and I was able to delete the necessary files. I'd suggest A) Clear the recycle bin B) run defrag against the drive C) reboot and retry D) try removing a few items at one time and also clearing out the recycle bin
My experience was on a 500Mhz Win2K server that had 192MB of memory at that time (512MB at most, I can't remember when we upgraded the memory)
Good luck,
 
Best to post Exchange questions in an Exchange group - such as
m.p.exchange.admin

In a command prompt:

del <full path to badmail>\*.* /q

And yes, with that many files it's gonna take a while. Let it run til it's
done. If you're using the default badmail path, enclose the path in quotes
as there's a space in it.

Set up a batch file containing that command and schedule it to run
daily/nightly in task scheduler. That way this won't happen again. You
can't stop badmail from getting files in it, but you can keep it manageable.
I also recommend changing the path in ESM to something like d:\badmail to
make it easier to find.
 
The reason for the apparent hang is that Explorer iterates the entire
directory when you open it. If you watch taskman, you will see Explorer.exe
go to 100% CPU for the duration of the activity.

A cmd prompt, on the other hand, does not do that. It just opens the
directory. If you do a dir from there, you will get more or less the same
behavior (except it will be cmd.exe that causes the 100% CPU), but you can
hit ctrl-c to break in.


Pat
 
Back
Top