Path: csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Frank Slootweg Newsgroups: alt.comp.os.windows-10 Subject: Re: Windows %TEMP% folder & files Date: 27 Feb 2025 13:29:28 GMT Organization: NOYB Lines: 68 Message-ID: References: X-Trace: individual.net evtmJDjOCL+hJEia/acdGQwwzNLhc3lpjyn7VLuYMEwtyEd6OO X-Orig-Path: not-for-mail Cancel-Lock: sha1:0jN6dRctnnasrv+FQkCkpKN23YM= sha256:vyjrHHFPpvmRGfggAOZhNeyek2AK7vCatQXnIXAhJ00= User-Agent: tin/1.6.2-20030910 ("Pabbay") (UNIX) (CYGWIN_NT-10.0-WOW/2.8.0(0.309/5/3) (i686)) Hamster/2.0.2.2 Xref: csiph.com alt.comp.os.windows-10:182593 VanguardLH wrote: > Frank Slootweg wrote: > > > One thing I noted in my %TEMP% folder [1], is that, while there are > > quite a lot of files and folders which use quite some space (210 Files, > > 105 Folders, Size 312MB), they are not very old! The oldest (both files > > and folders) are of December 17, so a bit over two months old. > > > > So it seems the %TEMP% folder *is* being cleaned by some mechanism. > > > > Anybody having any insight on what is doing that cleaning? > > > > [1[ C:\Users\\AppData\Local\Temp > > Windows has its own cleanup schedule. Look in Task Scheduler under > Microsoft -> Windows for DiskCleanup. That cleans when space is low. I > thought there was another cleanup event, but don't remember it now. Of > course, it's possible cleanmgr.exe was scheduled to run, but you had to > add that. > > In the Start Menu, search on "storage sense". Or, go to Settings -> > System -> Storage. If that is enabled, it cleans up the drive(s). > There is a "Configure Storage Sense or run it now" link there. Click on > it to see, if enabled, at what intervals it runs. > > https://support.microsoft.com/en-us/windows/manage-drive-space-with-storage-sense-654f6ada-7bfc-45e5-966b-e24aded96ad5 Thanks for that! You hit the nail on the head! [BTW, my system is Windows 11, but probably most, if not all, of this also goes for Windows 10.] There's indeed a 'SilentCleanup' task in the DiskCleanup Task Scheduler folder which runs 'cleanmgr.exe /autocleanstoragesense' and it has run today at 09:03. The task is indeed triggered from outside the Task Scheduler, because the 'Next Run Time' field is empty and there are no triggers on the 'Triggers' tab of the task. 'Storage Sense' is Off, but on the Storage Sense page (in Settings), there is this section: "Cleanup of temporary files [V] Keep Windows running smootly by automatically cleaning up temporary system and app files" So 'Disk Clean-up' (cleanmgr.exe) only cleans temporary files, not any of its other possible tasks, and it does this anyway, not just "when disk space is running low" (I have 760GB free), so the 'Description:' of the Task Scheduler task is a bit misleading. The 'Storage Sense' part (in Settings) says it "runs when disk space is low", but, as mentioned, Storage Sense is off on my system and indeed says "We have cleaned up 0 bytes in the past month.". Summary: This setting causes the %TEMP% folder to be cleaned automatically: Settings -> System -> Storage -> Storage Sense -> "Cleanup of temporary files [V] Keep Windows running smootly by automatically cleaning up temporary system and app files" Thanks again, VanguardLH!