Safe to run a .bat file to clean Temp Internet Files at startup?

SledgeProne

Posts: 91   +0
After defragging my HD today, I noticed on the completed defrag log, numerous fragmented files remained, including many from within my Content.IE5 folder.
Rather than weed out each fragmented file, in a folder that itself is not easy to access,
I found a .bat file that apparently cleans out this folder upon bootup, if placed in the startup folder.
I'm just not certain if it was meant, and/or if its safe to use with my old Win XP.

Code:
[USER=154672]Echo[/USER] off
cls
cleanmgr /sageset:99
del /F /S /Q "%systemroot%\temp\*.*"
del /F /S /Q "%systemroot%\Prefetch\*.*"
del /F /S /Q "C:\Documents and Settings\Default User\Local Settings\Temporary Internet Files\Content.IE5\*.*"
del /F /S /Q "C:\Documents and Settings\Default User\Local Settings\Temp\*.*"
del /F /S /Q "C:\Documents and Settings\Default User\Local Settings\History\*.*"
 
del /F /S /Q "C:\Documents and Settings\%UserName%\Local Settings\Temporary Internet Files\Content.IE5\*.*"
del /F /S /Q "C:\Documents and Settings\%UserName%\Local Settings\Temp\*.*"
del /F /S /Q "C:\Documents and Settings\%UserName%\Local Settings\History\*.*"
 
del /F /S /Q "C:\Documents and Settings\%UserName%\Local Settings\Application Data\Temp\*.*"
del /F /S /Q "C:\Documents and Settings\%UserName%\Local Settings\Application Data\Temporary Internet Files\Content.IE5
\*.*"
 
del /F /S /Q "C:\AppData\Local\Microsoft\Windows\History\*. *"
del /F /S /Q "C:\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.IE5\*.*"
del /F /S /Q "C:\AppData\Local\Microsoft\Windows\Temporary Internet Files\Low\Content.IE5\*.*"
del /F /S /Q "C:\AppData\Local\Microsoft\Windows\Temporary Internet Files\Temporary Internet Files\Content.IE5\*.*"
del /F /S /Q "C:\AppData\Local\Microsoft\Windows\Temporary Internet Files\Temporary Internet Files\Low\Content.IE5\*.*"
 
del /F /S /Q "C:\Users\%UserName%\AppData\Local\Temp\*.*"
del /F /S /Q "C:\Temp\*.*"
del /F /S /Q "C:\Users\%UserName%\AppData\Local\Microsoft\W indo ws\Temporary Internet Files\Low\Content.IE5\*.*
del /F /S /Q "C:\Users\%UserName%\AppData\Local\Microsoft\W indo ws\History\*.*
 
 
::Rem: No need to duplicate the following section for each registered User
del /F /S /Q "%homepath%\Cookies\*.*"
del /F /S /Q "%homepath%\recent\*.*"
del /F /S /Q "%homepath%\Local Settings\cookies\*.*"
 
del /F /S /Q "%homepath%\Local Settings\History\*.*"
del /F /S /Q "%homepath%\Local Settings\Temp\*.*"
del /F /S /Q "%homepath%\Local Settings\Temporary Internet Files\Content.IE5\*.*"
 
cleanmgr /sagerun:99
 
Those listings are all safe to delete, regardless of whether it is done at bootup.

However I do not know what this line is for.
cleanmgr /sageset:99
cleanmgr /sagerun:99
 
Thanks guys!
I remember reading an addendum from the poster, stating something about removing the sageset, after the first cleanup, after the preferences were set, that it was no longer necessary, but that it was also ok to leave as is.

When I posted this last night, I had already placed the .bat file in the startup folder, and was awaiting a reply, before rebooting. Well I got sleepy, and inadvertantly turned off my machine. Upon startup, it cleaned up everything, and all does appear well, however it keeps prompting for preferences before scanning each time. Not sure exactly how to remove the sageset, but since it likely deleted the fragmented files, I suppose I can remove it altogether anyway.
 
Back