Jump to content

How to block the automatic cleaning of Windows 10's Thumbnail Cache


Karlston

Recommended Posts

Microsoft's Windows operating system uses a thumbnail cache for thumbnail icons used in Explorer to speed up the display of icons when a user opens a folder with cached items.

 

Microsoft changed how the thumbnail cache works in the Fall Creators Update for Windows 10. Starting with that release, Windows 10 clears the thumbnail cache automatically using a feature called Automatic Maintenance.

Automatic Maintenance

Automatic Maintenance performs a large number of tasks, from synchronizing the time and maintaining Windows Defender to defragmentation of drives and clean-up operations.

 

Tip: Open PowerShell and run the command Get-ScheduledTask | ? {$_.Settings.MaintenanceSettings} | Out-GridView to display all Automatic Maintenance tasks and the status of each in a listing.

 

One such task is called SilentCleanup. The task launches the built-in Disk Cleanup tool using the parameter /autoclean which makes the tool read Registry values to determine what to clean.

 

Cleaning the cache may free up storage on the device but it comes at the cost of having to renew the cache when File Explorer is used.  Windows 10 users who keep lots of photos in a single folder may experience issues when those folders are opened in File Explorer as it may increase the CPU load for the time it takes to generate and cache the thumbnails.

 

You can visit the hidden folder %userprofile%\AppData\Local\Microsoft\Windows\Explorer in Explorer to display the cache.

Option 1: Making changes to the Registry

thumbnail cache autorun delete

 

SilentCleanup checks the data of each Autorun Dword value under HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\ and HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\ to determine whether it should include that cache in the cleanup operation.

 

A value of 0 blocks the maintenance task from deleting the cache, a value of 1 allows it to to so.

 

Here is how you configure Windows 10 to block or allow the clearing of the cache:

  1. Open Start, e.g. by clicking on the icon or tapping on the Windows-key on the keyboard.
  2. Type regedit.exe.
  3. Confirm the UAC prompt that Windows displays.
  4. Go to HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\Thumbnail Cache
  5. Double-click on the Autorun Dword value.
  6. Set it to 0 to prevent Windows from clearing the cache, or to 1 to allow it to do so.
  7. Go to HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\Thumbnail Cache
  8. Double-click on the Autorun Dword value.
  9. Set it to 0 or 1 accordingly.
  10. Optional: repeat the steps for any other cache listed under VolumeCaches.
  11. Restart the PC.

Windows won't delete the cache anymore as part of Automatic Maintenance if you set both entries to 0.

Option 2: The Task Scheduler

silentcleanup.png

 

You may disable the entire SilentCleanup task or even Automatic Maintenance in the Task Scheduler. Disabling SilentCleanup may be an option if you don't want Windows to clear the cache automatically.

 

You may still run Disk Cleanup or any third-party tool that supports the cleaning of Windows caches to do so. Note that used disk space my increase if you don't as Windows won't run the cleanup task anymore.

  1. Open Start.
  2. Type Task Scheduler and load the result. You may also search for taskschd.msc directly if Windows Search acts up and does not reveal the right result in the search results.
  3. Use the navigation in the sidebar to go to Task Scheduler Library > Microsoft > Windows > DiskCleanup
  4. Right-click on the SilentCleanup task on the right and select Disable from the context menu; this turns the task off so that it is not run automatically anymore.

Tip: You can turn the task back on at any time by following the steps described above and selecting Enable from the context menu.

 

Source: How to block the automatic cleaning of Windows 10's Thumbnail Cache (gHacks - Martin Brinkmann)

Link to comment
Share on other sites


  • Views 822
  • Created
  • Last Reply

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...