WinSxS

Reclaiming Space: How to Clean Up WinSxS on Windows Server 2008 R2

Posted on Updated on

The C:\Windows\WinSxS directory is notorious for growing over time as it stores multiple versions of DLLs and backup files for Windows Updates. On a long-running Server 2008 R2 instance, this folder can easily consume 10GB–20GB of precious SSD or SAN storage.

pic1[1]

Step 1: Install Disk Cleanup (Without a Reboot)

In Server 2008 R2, the Disk Cleanup utility is technically part of the “Desktop Experience” feature. Usually, installing this requires a reboot—something most admins want to avoid.

Instead, you can install the standalone update package (KB2852386) that specifically adds Disk Cleanup functionality:

pic2[1]

Step 2: Launching the Cleanup Wizard

Once the update is installed, you won’t find it in the Start Menu immediately. You can launch it via the command line:

pic8[1]
  1. Open Run (Win + R).
  2. Type cleanmgr and hit Enter.
  3. Select your C: Drive.
pic9[1]
pic10[1]

Step 3: Cleaning System Files (The “WinSxS” Secret)

To actually shrink the WinSxS folder, you must target the Windows Update files.

3348.diskcleanup3[1]
pic11[1]
  1. When the wizard opens, click the Clean up system files button (this requires Administrator privileges).
  2. The tool will scan again. Look for the new option: Windows Update Cleanup.
  3. Check this box along with any other items you want to remove (Service Pack Backup files, etc.).
  4. Click OK.

Step 4: Finalizing the Shrink

Unlike standard file deletion, the WinSxS cleanup happens during the next reboot.

  • When you restart the server, you will see a message: “Configuring Windows updates, X% complete. Do not turn off your computer.” * Do not interrupt this process. This is the system physically removing the redundant files from the WinSxS directory.
pic12[1]

The Result: After the reboot, you should see a significant drop in the size of your Windows directory—often saving several gigabytes of space.

#WindowsServer #WinSxS #SysAdmin #StorageCleanup #ITPro #DataCenter #WindowsUpdate #TechTips #LazyAdmin #ServerMaintenance

The “No-Install” Hack: Enable Disk Cleanup on Server 2008 R2

Posted on Updated on

Need to free up space right now but can’t afford a reboot or a feature installation? Windows Server 2008 and 2008 R2 actually have the Disk Cleanup files hidden inside the System Component Store (WinSxS). You just have to move them to the right place.

The Manual “Copy-Paste” Method

By manually placing these two files into your System32 directory, you enable the cleanmgr command immediately.

1. Locate the Files

Search your C:\Windows\WinSxS directory for the following two files. Note: The long folder names may vary slightly based on your service pack level, so use the search bar if needed.

For Windows Server 2008 R2 (64-bit):

  • The Executable: amd64_microsoft-windows-cleanmgr_..._cleanmgr.exe
  • The Language Resource: amd64_microsoft-windows-cleanmgr.resources_..._en-us_...\cleanmgr.exe.mui

2. Move to System32

Copy (don’t move, just in case) the files to these specific destinations:

  1. cleanmgr.exe%systemroot%\System32
  2. cleanmgr.exe.mui%systemroot%\System32\en-US

3. Run the Tool

You don’t need to register anything. Simply open a Command Prompt or the Run dialog (Win+R) and type: cleanmgr.exe

Why do it this way?

  • Zero Downtime: No reboots, no “Configuring Windows” screens.
  • Lightweight: You don’t pull in the rest of the “Desktop Experience” (like Media Player or desktop themes) that just adds more bloat to a server.
  • Reliable: You are using the exact binaries Microsoft built for that specific OS version.

#WindowsServer #SysAdmin #ITPro #TechHacks #ServerMaintenance #DiskCleanup #LazyAdmin #Troubleshooting #WindowsAdmin #ZeroDowntime