Windows still doesn’t clean up its temp files
If you believe Microsoft, something as modern as Vista should be a shining model of efficiency.
Well, I recently found an example of inefficiency that seems to go back to the days of windows 95 (or maybe even earlier).
Yep, I’m talking about the temp folder(s).
As Microsoft has waded through the various versions of Windows, the location of the temp folder (or folders) has changed, but the lack of housecleaning hasn’t.
With Vista, I recently got a slow laptop from a customer, and I decided to take a look at:
c:users{username}appdatalocaltemp
And what did I find?
over 4,000 temp files… some over 2 years old.
Sure, you can install something to cleanup the temp files, but average computer users don’t know about computer maintenance… they just assume it get done automatically.
Its amazing how a company will put so much effort (and money) into advanced new features… yet some simple maintenance like cleaning the temp folder at startup time, is totally ignored.
Out of curiosity, I took a look at the latest Windows 7 beta… and it also has the same issue…
It makes me wonder if anyone at Microsoft actually cares about the long-term usability of their windows products.
The temp file thing doesn’t really bother me. With HD space and plentiful and cheap as it is, I don’t think cluttering the directory has an impact on performance.
I would like it if each of those files had a property identifying which application created it, and if each process in Task Manager, or start up item in MSCONFIG also had a property that identified exactly where is came from and what application owns it.
I think this responsibility should fall on the developer of each application. Back in the days of MS-Dos, temporary files left over were the sign of a program written poorly, behaving poorly or crashing.
I have seen excessive numbers of temp files slow down even server-grade computers. It takes processor time for applications to sift through the %TEMP% to see if a file name already exists. Especially when the count approaches 10,000 files
One of favorite quick-n-dirty ways to clean this up is a ‘rmdir /s/q %temp%’ from a command prompt. Files in use will not be removed, but it’s still safer to exit open applications beforehand.
Cromley — Indeed, I agree with you. It would be great if there was some kind of extended attribute assigned to files (application CLSID or something) so I could see what created them. Of course this probably would mean a rewrite of the NTFS structure.
Well, I’ve noticed that performance starts to be affected starting from about 1,000 files… more files means a greater performance hit.
I once saw a temp folder with 50,000 files in it… the PC was almost unuseable.
So, its not about how much space the files take up, its probably more about how windows copes with needing to often access a folder with over 1,000 entries.
Even with caching, you quickly run out of cache. And you really want to be caching “proper” files and programs, not temp files.
Having a unix background, I’ve seen a similar problem with unix/linux. And the only solution is to erase the temp folder at startup and/or on a regular basis. unix/linux often has services that will do this cleanup.
Its easy to say that poorly written programs are to blame, but this also happens if a program crashes (or is terminated) before it gets a chance to clean-up its temp files.
At the end of the day, the best solution, if not very elegant, involves windows doing a cleanup at boot time, or even having a simple service that deletes temp files older than, say, 1 week.
After all, windows provides the facility to use %TEMP%, so it should maintain it.
If %TEMP% wasn’t available, I can see most programs creating a folder like: c:Program FilesMyApptemp … and then using that for temp files.
Thank you for being my Top Dropper!
Take care!
I give Windows a good cleaning every six months – it is called “reformat and reinstall” Windows has so much bloat to it that it will eventually start eating itself.
MS is too busy trying to get into the online market to worry about trivial things like this! 😉
My Vista laptop runs veery slowly. I will try this to see if it helps! Thanks!
I’ve used Windows and Macs side-by-side since the mid-80s. This has never been a problem on the Macs and has always been a problem on PCs.
With everything else Microsoft has copied from them, you would think they would get the message and do this, too. But noooooooo. I do believe it is because MS simply does not care about the consumer at all.