Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Am using DELL Inspiron with Windows 7.

As far as I know emptying the windows temp folder would be good. But I faced a strange behaviour around 8 months back, when I clear my windows temp folder. The next day onwards, my laptop starting displaying daily one or other errors and one day OS got crashed. Till now I am not sure whether OS got crashed due to clearing the windows temp folder or something else is problem.

Here Windows temp folder mean "C:\Windows\Temp"

This is the behind the story.

Today, this temp folder "C:\Windows\Temp" contains 102 GB.

Most of the space occupied by the files starts with etilqs_*.*. I came to know that these files are generated due to WD SmartWare.

Now my problem is:-

Actually I want clean up this folder, since it occupies lot of space.

If I clean up "C:\Windows\Temp" folder, will my laptop face the same kind of problem which I faced earlier OR Any new problems will occur?

Please suggest me a good solution.

share|improve this question

3 Answers 3

up vote 10 down vote accepted

As the name implies, the location is intended for files that are only supposed to be stored temporarily.

So, if you write an application and you want to store something for later retrieval, this is the wrong place for you. The Temp location is only to be used for data that, if gone, wouldn't matter anyway.

Sadly, not every programmer understands that concept.

If someone decided to place a critical file in that location, deleting that file might cause a problem to an application.

So, in my personal opinion, deleting the contents of the Temp folder shouldn't cause any problems. But due to the fact of how it is used, it can not be guaranteed to be a safe operation.

Please also keep in mind, emptying the folder while the system in operational could cause a running application to lose a file it placed there. Emptying the folder is something best done during boot.

share|improve this answer
    
Only a very badly written program will close a temp file that contains data it still needs. And if the file is still open, it can't be deleted. So there's simply no chance of losed data that's still needed by doing a blanket delete. The delete simply fails for those files are still in use. –  Isaac Rabinovitch Sep 30 '12 at 3:25
    
@IsaacRabinovitch: So what if I'm running very badly written software? I still might be sad if it crashes :) An application might also place a file there that it needs in the future. Consider application installers that might extract their whole payload to a temporary location before copying the data to the designated location. –  Oliver Salzburg Sep 30 '12 at 12:55
    
So what programs that you know of do this? –  Isaac Rabinovitch Sep 30 '12 at 18:09

Emptying temp folders seems to be obvious. With most Linux distributions this is done on each boot.
But not with Windows. Why ?
Because some softwares use temp as a reliable storage accross reboot. Yes this is stupid.
Most of those softwares are doing that only after install if they need a reboot. Once done, the files can be wiped out.
Such software are now very rare. I didn't saw any since maybe 2 or 3 years.

So: use a scheduled task run on boot, which delete the content of temp folders, but only for files older than, say, 7 days.
This will do the job safely.

How to delete old files:
http://stackoverflow.com/questions/51054/batch-file-to-delete-files-older-than-n-days

share|improve this answer
2  
Can you cite any programs that use temp files for long-term storage? I find it very hard to believe that any developer could be that stupid. –  Isaac Rabinovitch Sep 30 '12 at 3:28
    
A good point made that if you are going to delete temp files then you should only delete those over a number of days old and, in between that period, you should have rebooted. This ensures you don't accidentally delete any temp files in use or waiting to be used at the next reboot. –  Richard Dec 26 '12 at 15:09

Deleting of temp files won't create a problem, but instead of deleting the files from the Temp directory, you can use the diskcleanup tool which was provided by Microsoft.

share|improve this answer
    
Disk Cleanup does not touch the Windows Temp folder on my machine (Windows Vista), no matter what the settings. –  kreemoweet Jun 28 at 17:32

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.