deleting c:windows\temp

Mookow

Lifer
Apr 24, 2001
10,162
0
0
My temp folder is currently 2.47GB. My virus scan spends forever looking through there, and since 2.47GB is more than half the size of my last computer's storage space, I have this question: can I just delete all contents of my windows\temp folder?
 

vi edit

Elite Member
Super Moderator
Oct 28, 1999
62,347
8,023
126
<**disclaimer**>
Not responsible for any harm that may come of your PC, the operating system, or end user installed programs
</**disclaimer**>

I have been deleting the \temp folder for years now without any problems. It's usually from poorly coded extraction programs that don't remove the temporary archives as well as a couple other things that *shouldn't* cause any harm.

 
Apr 5, 2000
13,256
1
0
Usually yea - it's just temporary files that installations put in there among other stuff. My cousin who has never emptied his temp dir in the year and a half he's had it had 4 GB in his temp folder and everything worked fine after I emptied it for him.
 

iamwiz82

Lifer
Jan 10, 2001
30,763
9
81
since you have yours under c:\windows, i'll assume win98. In this case, put a line in your autoexec.bat which will delete the temp folder on reboot.

 

Mookow

Lifer
Apr 24, 2001
10,162
0
0
All right, I think I'm going to copy it all over into another folder, empty my temp folder, and if nothing goes wrong, delete the new folder next week.
 

Freeze

Senior member
Oct 15, 1999
681
0
0
check the dates on the files. If they are older than a day or so, I would say nuke it. Anything somewhat new leave as is, but delete everything else...

 

Harvey

Administrator<br>Elite Member
Administrator
Oct 9, 1999
35,052
30
86
My AUTOEXEC.BAT has this lines:

@IF NOT EXIST C:\WINDOWS\TMPDELIS.BAT DELTREE/Y C:\WINDOWS\TEMP\*.*>NUL
@DELTREE/Y C:\WINDOWS\TEMPOR~1\CONTENT.IE5\*.*>NUL
@DELTREE/Y C:\WINDOWS\COOKIES\*.TXT>NUL
@DELTREE/Y C:\WINDOWS\HISTORY\HISTORY.IE5\*.*>NUL


TMPDELIS.BAT is a batch file created by many installation programs that tells the system to delete whatever dross remains from the installation on reboot.

The first nukes the contents of C:\WINDOWS\TEMP only if that file is not present. The rest of these clears up a lot of garbage that builds up in IE. Don't worry about the subdirectories under these directories. Windows rebuilds them on reboot.

The redirect, >NUL, just tells the sytem not to bother telling me about it. :)
 

4824guy

Diamond Member
Oct 9, 1999
3,102
0
0
Some of the PC magazines say it is completely safe to delete anything in there that is over 1 or 2 days old. That is what I do from time to time with no problems.
 

dirtboy

Diamond Member
Oct 9, 1999
6,745
1
81
I have been clearing this folder out for years. Just make sure you save anything that you have downloaded there, otherwise, delete *.*.
 

ASK THE COMMUNITY