I have a c:\ on a server that is filling up, most likely due to the accumulation of patches over the years.

I'm told by Microsoft PSS Support that it is unwise to simply delete the compressed uninstall directories within the \Windows directories. Considering that we have 100's of windows servers, this scattering of patches is consuming at significant amount of space on our SAN (these windows servers are in VMWare).

Can you tell me what I can do, besides the list below, to clean up space on the C:\ drive? I'm hoping that you may have more insight than the recommendation I received.

  1. Don’t set your Virtual Memory pagefile.sys on C drive.(System Properties\Performance settings\Advanced\change Virtual memory)

  2. Clear temp files (C:\windows\temp and C:\Users\%Username%\AppData\Local\Temp).

  3. Don’t set your temporary Internet files on C drive.(Internet Options\Browsing history settings\move folder)

  4. Move the Windows Search Service Database. If you have started Microsoft Search services, please move Windows.edb file to another drive.

    ( C:\ProgramData\Microsoft\Search\Data\Applications\Windows )

  5. Compress folders to save disk space and use disk cleanup

  6. Use mount point to mount an additional drive.

  7. “Compln.exe” can only be used to clean Service Pack, such as (RTM and SP1). In your system Windows server 2008 r2, it don’t contain any service pack. It cannot clean the patches in your system.

  8. ???? (not sure what this idea is) "Microsoft provide the built-in tool – disk cleanup .(You need to install a feature called "Desktop Experience" to get Disk Cleanup.) "

What other things can be done to clean up your server and free up space?

Lastly, it would be nice to get an idea of what drive size you use for c:\ for whatever version of Windows you use.

  • No definite answer, might be best as a wiki – Bart Silverstrim Sep 29 '10 at 14:02
  • That said...not wise to delete the compressed patches in c:\Windows, but if they're old (and won't see having to uninstall the patches), I've been known to move them to temporary consolidated storage, then delete them if there's no side effects. Also if backups are taken religiously then moving the compressed patch dirs shouldn't cause much headache to restore if they're needed. Not the best practice I'm first to admit, but it sheared some excess storage for us (and nothing horrible happened.) – Bart Silverstrim Sep 29 '10 at 14:04
  • For future reference, you can "activate" the built in Microsoft drive cleaner utility without installing the desktop experience. Follow the steps outlined in this technet article. – Viertaxa Feb 9 '15 at 14:40
  • did anyone find a solution to this?I am experiencing the same problem – user293152 Jun 9 '15 at 8:36

Lastly, it would be nice to get an idea of what drive size you use for c:\ for whatever version of Windows you use.

Server 2003: We use 15GB C: drives for these now. We used to use 10GB ones, but the patch-dirs ate us out of house and home. We're not spinning up many of these any more, but if we do, 15GB is it.

Server 2008 & 2008R2: Microsoft itself is saying that 30GB is the number you should be aiming at. Seeing as how they made the patch-dirs nigh undeleteable with these server versions, I'm not going to doubt them. Currently we make our C: drives 20GB, but that's because we made our VM templates before this guidance emerged. We need to change it. 40 is probably better once you factor in 3rd party installers that resolutely stash things on C: no matter what you tell them.

| improve this answer | |
  • 3
    We are finding that 40GB is too small for 2008 these days with the continual growth of the Winsxs folder. Every time a patch, service pack or new DLL is installed, that folder can grow larger. – Doug Luxem Sep 29 '10 at 14:35

In the interest of preserving the information in case the TechNet article moves, here is how to "activate" the Microsoft disk cleanup utility on server 2008 or 2008 R2:

Windows Server 2008 R2



Windows Server 2008 R2



Windows Server 2008



Windows Server 2008



Windows Server 2008



Windows Server 2008



Once you’ve located the files move them to the following locations:

Cleanmgr.exe should go in %systemroot%\System32.

Cleanmgr.exe.mui should go in %systemroot%\System32\en-US.

You can now launch the Disk cleanup tool by running Cleanmgr.exe from the command prompt.

| improve this answer | |
  • For older in installs this can free up 10+ GBs. Make sure you click the "Clean up system files" button and it'll nuke all the accumulated windows update install files that have already been applied. – Molomby May 14 '17 at 15:09

I've used 'junction' by sysinternals to redirect folders like the software distribution directory, or windows search. You can also use the built in mklink command, but junction works on older versions of windows and can be standardized against in automated deployment scripts.

It works wonders for getting a server install running off of a space restricted EEEpc.

For more information on mklink: directory junction vs directory symbolic link?

For a step by step guide regarding specifically the patches directory, try this blog. Entry is appended below with some formatting modifications:



You have a server with an 8 GB system partition and it keeps filling up. The software distribution folder used by windows updates is a major source of bloat and Microsoft support has said there is nothing you can do to move this folder from the C drive.


Using the Microsoft Junction Tool found on the Systernals site create a symbolic link to another hard drive or partition. I will use the terms symbolic link and junction interchangeably in this post.


  • Stopping the Windows Update Service and renaming the folder

    Start>Run type cmd and press enter type net stop wuauserv and press enter type rename c:\windows\SoftwareDistribution softwaredistribution.old and press enter

  • Creating a symbolic link using Junction

    In this example the software distribution folder will be redirected from C:\WINDOWS\SoftwareDistribution to the D:\WINDOWS\SoftwareDistribution

  • Creating the Junction

    To create the target directory from the command prompt

    C:\>md D:\Windows\SoftwareDistribution

  • To create the Junction

    C:\>junction C:\WINDOWS\SoftwareDistribution "D:\WINDOWS\SoftwareDistribution"

  • Restart the Windows Update Service

    type net start wuauserv and press enter

    Once everything has been verfieid to be working normally delete the softwaredistribution.old folder.

Jeff Loucks

(You may optionally copy the .old directory's contents into the new location).


IIS logs and Windows Error Reports.

  1. C:\inetpub\logs\LogFiles
  2. %LOCALAPPDATA%\CrashDumps

Find a program like SpaceMonger to find the space hogs.

| improve this answer | |

If it's 2008 R2, you can attempt to run dism /online /cleanup-image /spsuperseded. That will get back some space if you've installed SP1 since the initial install. If it was slipstreamed, I doubt you'll get any space back, however.

| improve this answer | |

A little less known but worth mentioning: Windows Update stores the updates it downloads in C:\Windows\SoftwareDistribution\Download; and they are not deleted after having been installed, thus the folder can grow to be quite large over time.

After new updates are installed, you can safely empty that folder and reclaim some disk space.

| improve this answer | |

There are two more clean up commands that help reducing system, of course after running them such updates will not be able to be uninstalled.

For Service Packs:

  • dism /Online /Cleanup-Image /SPSuperseded /HideSP

For Windows UpDates:

  • dism /Online /Cleanup-Image /StartComponentCleanup /ResetBase

Both can take a lot of time to run.

Just some advice:

  1. Do not run them if you want to uninstall updates
  2. New updates will be able to be uninstalled until you re-run the command
  3. They must be run with admin rights
  4. They can take a lot of time, on my virtual Windows 10 Home, it took hours after cumulative updates
  5. Do not run them just after updates, let the computer reboot between updates and then clean
  6. If on Windows 10, do not just reboot, do a power off and power on; it is very different than just reboot (on Windows 10 reboot is like hibernating, but only the kernel, a lot of problems if using VeraCrypt or other filesystem mount tools)

That commands do a big clean up on Service Packs and on WinSXS folder respectively. They only delete/remove files not needed anymore (assuming you will not want to uninstall Service Packs/Updates that are already installed).

Please note that they do not block future Services Packs / updates from being uninstalled.

The main idea of them is: They remove what is needed to uninstall the updates that are installed and old system files versions that are not in use anymore.

Just check the Microsoft website description to know more.


To automate this process you can find PowerShell script on link below.

How to Clean up the WinSxS Directory and Free Up Disk Space

???? (not sure what this idea is) "Microsoft provide the built-in tool – disk cleanup .(You need to install a feature called "Desktop Experience" to get Disk Cleanup.) "

Also, on link above you will find steps for disk cleanup(cleanmgr.exe) how to:

1) install

2) run

3) use

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.