Windows 8 and 8.1 Forums


WinSxS Folder (Component Store) - Clean Up in Windows 8.1

  1. #1
    WinSxS Folder (Component Store) - Clean Up in Windows 8.1

    WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    How to Clean Up the WinSxS Folder (Component Store) in Windows 8.1
    Published by Brink is online now
    11 Apr 2014
    Default WinSxS Folder (Component Store) - Clean Up in Windows 8.1

    Published by


    Brink's Avatar
    Administrator

    Join Date: Jul 2009
    Posts: 22,575

    How to Clean Up the WinSxS Folder (Component Store) in Windows 8.1


    information   Information
    The WinSxS folder is located in the Windows folder, for example C:\Windows\WinSxS. Itís the location for Windows Component Store files. The Windows Component Store is used to support the functions needed for the customization and updating of Windows. Here are some examples of how the Windows Component Store files are used:

    • Using Windows Update to install new component versions. This keeps systems secure and up-to-date.
    • Enabling or disabling Windows features.
    • Adding roles or features using Server Manager.
    • Moving systems between different Windows Editions.
    • System recovery from corruption or boot failures.
    • Uninstalling problematic updates.
    • Running programs using side-by-side assemblies.


    One commonly asked question is can I delete the WinSxS folder to regain some disk space? The short answer is no. (see warning box below) However, there are ways to reduce the size of the WinSxS folder.

    Windows 8.1 and Windows Server 2012 R2 automatically reduces the size of the WinSxS by using methods similar to the ones described in this tutorial, however these methods also include internal processes, such as uninstalling and deleting packages with components that have been replaced by other components with newer versions. Previous versions of some components are kept on the system for a period of time, allowing you to rollback if necessary. After a period of time, these components are removed from the installation.

    For more information about the component store, see:



    This tutorial will show you a number of ways to start the cleanup of the component store (WinSxS folder) to free up a large amount of disk space in Windows 8.1 and Windows Server 2012 R2.

    warning   Warning
    Manually deleting files from the WinSxS folder or deleting the entire WinSxS folder may severely damage your system so that your PC might not boot and make it impossible to update.

    Use one of the recommended options you would like to do in this tutorial below instead.






    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 In Preparation WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    Do this Tip First before doing an Option below

    Tip   Tip
    If you have not already, use the tutorial at the link below to determine if component store cleanup is recommended or not first. This way you can also see how much space will be recovered.

    How to Determine Size and if you should Clean Up Component Store (WinSxS folder) in Windows 8.1

    There's no need to do any of the options below if component store cleanup is not recommended at the link above.


    CONTENTS:

    • Option One: To Clean Up WinSxS Folder using StartComponentCleanup Task
    • Option Two: To Clean Up WinSxS Folder using /StartComponentCleanup with Dism
    • Option Three: Clean Up WinSxS Folder using /StartComponentCleanup and /ResetBase with Dism
    • Option Four: To Clean Up WinSxS Folder using /SPSuperseded with Dism
    • Option Five:To Clean Up WinSxS Folder using Windows Update Cleanup in Disk Cleanup






    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 OPTION ONE WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    To Clean Up WinSxS Folder using StartComponentCleanup Task


    Note   Note
    The StartComponentCleanup task was created in Windows 8 to regularly clean up components automatically when the system is not in use. This task is set to run automatically when triggered by the operating system. When run automatically, the task will wait at least 30 days after an updated component has been installed before uninstalling the previous versions of the component.

    If you choose to run this task, the task will have a 1 hour timeout and may not completely clean up all files.

    1. Press the + R keys to open the Run Dialog, type Taskschd.msc, and press Enter.

    2. If prompted by UAC, then click/tap on Yes.

    3. In the left pane of Task Scheduler, expand the console tree, and navigate to and open Servicing at location below. (see screenshot below)

    Task Scheduler Library\Microsoft\Windows\Servicing


    Click image for larger version

    4. In the middle pane of Servicing, select the StartComponentCleanup task, and click/tap on Run under Selected Item in the right pane. (see screenshot above)

    5. You'll now notice that the StartComponentCleanup task is now running. This will take a while to finish running. (see screenshot below).

    Name:  Task_Running.jpg
Views: 141549
Size:  7.6 KB

    6. If you like, you can close Task Scheduler since it's not required to remain open. It's recommended to let the computer stay running or sit idle until the task has finished running.





    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 OPTION TWO WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    To Clean Up WinSxS Folder using /StartComponentCleanup with Dism


    Note   Note
    Using the /StartComponentCleanup parameter of Dism.exe on a running version of Windows 8.1 gives you similar results to running the StartComponentCleanup task in OPTION ONE above, except previous versions of updated components will be immediately deleted (without a 30 day grace period) and you will not have a 1-hour timeout limitation.

    1. Open an elevated command prompt.

    2. In the elevated command prompt, copy and paste the command below, and press Enter. (see screenshot below)

    Dism.exe /online /Cleanup-Image /StartComponentCleanup


    Click image for larger version

    3. When successfully finished, you can close the elevated command prompt if you like. This could take a while to finish depending on how much there was to clean up.






    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 OPTION THREE WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    To Clean Up WinSxS Folder using /StartComponentCleanup and /ResetBase with Dism


    Note   Note
    Using the /ResetBase switch with the /StartComponentCleanup parameter of DISM.exe on a running version of Windows 8.1 removes all superseded (outdated) versions of every component in the component store.


    All existing service packs and updates cannot be uninstalled after this command is completed. This option will not block the uninstallation of future service packs or updates installed.

    1. Open an elevated command prompt.

    2. In the elevated command prompt, copy and paste the command below, and press Enter. (see screenshot below)

    Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase


    Click image for larger version

    3. When successfully finished, you can close the elevated command prompt if you like. This could take a while to finish depending on how much there was to clean up.





    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 OPTION FOUR WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    To Clean Up WinSxS Folder using /SPSuperseded with Dism


    Note   Note
    To reduce the amount of space used by a Service Pack, use the /SPSuperseded parameter of Dism.exe on a running version of Windows 8.1 to remove any backup components needed for uninstallation of the service pack. A service pack is a collection of cumulative updates for a particular release of Windows.


    The service pack cannot be uninstalled after this command is completed.

    1. Open an elevated command prompt.

    2. In the elevated command prompt, copy and paste the command below, and press Enter. (see screenshot below)

    Dism.exe /online /Cleanup-Image /SPSuperseded


    (If no service pack backup files found)

    Click image for larger version

    3. When successfully finished, you can close the elevated command prompt if you like. This could take a while to finish depending on how much there was to clean up.





    WinSxS Folder (Component Store) - Clean Up in Windows 8.1 OPTION FIVE WinSxS Folder (Component Store) - Clean Up in Windows 8.1
    To Clean Up WinSxS Folder using Windows Update Cleanup in Disk Cleanup


    Note   Note
    This option is to use the Windows Update Cleanup option in Disk Cleanup to delete outdated Windows updates from the WinSxS folder (component store) to free up hard drive space.




    That's it,
    Shawn


  2. #1


    What about Windows 8? my winsxs folder is 11GB, and I have 1.31GB in windows update clean up That won't delete in disk clean up system files, and i'm noticing that MS thinks everyone has updated from Windows 8! No info for Windows 8!

      My System SpecsSystem Spec

  3. #2


    Posts : 22,575
    64-bit Windows 10


    Hello Nolacs,

    If you like, you could update to Windows 8.1 for free via the Store.

    Windows 8.1 - Update to from Windows 8
      My System SpecsSystem Spec

  4. #3


    No way, I want Windows 8 to work properly first, 8.1 is just another can of worms. I have had a appcrash with msfeedssync.exe, after I had a forced refresh a week ago, Ran sfc/scannow NO integrity violations. Then ran DISM.exe scanhealth (win 8) No problem with component store. Then I ran app diagnostics and it said it's fixed (Image)Click image for larger version still appcrash not fixed.
      My System SpecsSystem Spec

  5. #4


    Hi,
    I am experiencing problem with using Disk Cleanup. I tried to clean up the "Windows Update Cleanup" - 196MB but couldn't!


    I press OK, the Disk Cleanup would process the "Windows Update Cleanup" part really fast (by looking at the progress bar) as if it skipped the entire part. Then when I ran Disk Cleanup again, the "Windows Update Cleanup" would show 196MB again!


    Name:  Untitled.png
Views: 120917
Size:  19.8 KB


    This is driving me crazy! I tried:


    1. Dism.exe /online /Cleanup-Image /StartComponentCleanup
    2. Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase


    I am looking for a solution here pls.


    Thanks!
      My System SpecsSystem Spec

  6. #5


    Posts : 22,575
    64-bit Windows 10


    Hello Nathan, and welcome to Eight Forums.

    If you haven't already, restart the computer, and try Option Three again to see if it may help.
      My System SpecsSystem Spec

  7. #6


    Quote Originally Posted by Brink View Post
    Hello Nathan, and welcome to Eight Forums.

    If you haven't already, restart the computer, and try Option Three again to see if it may help.
    Hello,

    Yea, I did as you asked the 196 MB is still there
      My System SpecsSystem Spec

  8. #7


    Posts : 22,575
    64-bit Windows 10


    Odd. Did you run the command in an elevated command prompt?
      My System SpecsSystem Spec

  9. #8


    Quote Originally Posted by Brink View Post
    Odd. Did you run the command in an elevated command prompt?
    yes i did

    I also posted my problem over at answers.microsoft and one of the forumer is suggesting that Windows Update Cleanup has some sort of dating system, preventing disk cleanup from clearing the recent files or some sort...

    Disk Cleanup - unable to clean Windows Update Cleanup - Microsoft Community

    if you could give me your insight on this..
      My System SpecsSystem Spec

  10. #9


    Posts : 22,575
    64-bit Windows 10


    Usually it only deletes anything that's 30-days and older, but that command should have overridden that.
      My System SpecsSystem Spec

Page 1 of 2 12 LastLast
WinSxS Folder (Component Store) - Clean Up in Windows 8.1
Related Threads
How to Use DISM to Fix Component Store Corruption in Windows 8 and Windows Server 2012 One of the most used tools when fixing corruption for Vista, Windows 7, Windows Server 2008 and Windows Server 2008 R2 was the System Update and Readiness Tool (KB947821), commonly called CheckSUR. The...
How to Determine Size and if you should Clean Up Component Store (WinSxS folder) in Windows 8.1 The WinSxS folder is located in the Windows folder, for example c:\Windows\WinSxS. Itís the location for Windows Component Store files. The Windows Component Store is used to support the functions...
Solved DISM says "component store is repairable" in Performance & Maintenance
Hi guys, I recently did a routine maintenance of my computer and after running Dism /Online /Cleanup-Image /CheckHealth command, it reported that the component store is repairable. Then, I immediately followed it up with sfc /scannow and it reported no integrity violations. I was just wondering...
I am getting repeated Component store corruptions after any security updates. No metro apps will open yet an icon appears on the Taskbar. I have been able to repair it with DISM every time but that is beside the point. I want to know why!
Component store in General Support
I would like all the info i can get on the winSXS folder in windows. What it is used for, windows update old and new .dll's, component store etc. Also I read where the DISM program has been changed for Windows 8.1?
Hi. I've been having problems with my laptop recently. I actually care less when it comes to updates since it's automatic, but I noticed that it refuses to install any drivers (which means I cannot access any USB drives or install programs that requites drivers) or updates, after searching for...
First of all Hi to all me just joined this forum :) from last few months I was having prob with my long ago installed windows 8 64 bit first RTM release I think I was not using it as primary OS so I did not tried to repair it early so yesterday I bot that os up the main prob is it...
Eight Forums Android App Eight Forums IOS App Follow us on Facebook