How to Free C:\ Drive Disk Space in Windows 7 and Reduce System Size?

by Yang Yang on July 15, 2012

Windows 7 is a beast in consuming hard drive disk spaces, especially the system drive, C, which is constantly being filled up. After a while it will keep annoying you with low disk space warnings because C drive is running out of space and almost full. So how can I safely free up all the disk spaces in C drive in Windows 7 and reduce its disk storage?

The methodology is to find the fattest folders in C drive, move as many of them to another drive (such as D, E, etc.) as possible, and make symbolic links (by mklink) from C drive to the folders in other drives.

Step 1 – Find culprit folders that occupy the most disk space!

There are so many ways to do this but what I did was to look at the size stats for each of the major folders in my C drive. After 10 minutes, I was able to pinpoint these folders that are consuming large chunks of the disk volume:

  • C:\Windows\winsxs – very high-profile system folder that are not easily reduced / moved, which I’ll leave alone.
  • C:\Windows\Installer – Over 3GB, program installers that can be moved safely and easily.
  • C:\Users\Administrator\AppData\Google – About 0.8GB, Google products data such as those by Chrome.
  • C:\Users\Administrator\AppData\Mozilla – About 1.6GB, Firefox profiles and browser data.
  • Some folders in C:\Program Files – I wish I could move this entire folder but I couldn’t. I could only move some of the folders such as “Microsoft Games”.
  • Some folders in C:\Program Files (x86) – Same as above.

This is just my case. You may as well find totally different folders that need to be moved. After you have found something, proceed to step 2 to duplicate them elsewhere.

Step 2 – Copy these folders to another drive that is much more spacious!

This one is easy. Just perform the omnipotent Ctrl+C and Ctrl+V combination to copy these folders to another drive. In this example, we’ll copy these folders to their new destination – D:\C_DRIVE:

  • C:\Windows\Installer –> D:\C_DRIVE\Windows\Installer
  • C:\Users\Administrator\AppData\Google –> D:\C_DRIVE\Users\Administrator\AppData\Google
  • C:\Users\Administrator\AppData\Mozilla –> D:\C_DRIVE\Users\Administrator\AppData\Mozilla

After the duplications, proceed to step 3.

Step 3 – Delete original folders and create the symbolic links

Now we need to delete the original folders in drive C. Some files and folders in Windows 7 are owned by TrustedInstaller while some by SYSTEM that cannot be easily deleted by Administrator. To delete them, you have to acquire SYSTEM privileges to do this, because the most privileged account in a Windows 7 computer is SYSTEM, not Administrator.

To do this, just create a file named syscmd.bat and put in the following commands:

sc Create SysCMD binPath="cmd /K start" type=own type=interact
sc start SysCMD

Double click to run the file syscmd.bat and you will be prompted by a dialog with 2 buttons, click the top one to view the interactive message.

And you will enter a command line interactive mode with SYSTEM privileges which basically grant you full rights to the computer – you can do whatever you want now.

Run these commands one by one – line by line, you type in the command and hit enter:

rmdir /s /q C:\Windows\Installer
rmdir /s /q C:\Users\Administrator\AppData\Google
rmdir /s /q C:\Users\Administrator\AppData\Mozilla

Now that the original folders are deleted, we’ll make symbolic links in the same name so that any requests for these folders are correctly diverted to those on the D drive:

mklink /D C:\Windows\Installer D:\C_DRIVE\Windows\Installer
mklink /D C:\Users\Administrator\AppData\Google D:\C_DRIVE\Users\Administrator\AppData\Google
mklink /D C:\Users\Administrator\AppData\Mozilla D:\C_DRIVE\Users\Administrator\AppData\Mozilla

That’s it.

After these 3 steps, my C drive is successfully reduced in size by 5.4GB. I can move more folders to further enlarge / extend the free space but for now, it’s good enough for me.

Feel free to leave any comment about how you are doing with this approach.

Jeff March 30, 2015 at 10:05 pm

Yang,
Thanks. That helped a lot – freeing up room on my 100g SSD.
I want to try it with my Surface Pro 2 – redirecting to a SD card. Wish I could dump all the Windows/WINSXS files – but following your recommendation on that.

Rich May 15, 2015 at 7:25 am

The bat file refuses to run. I see a cli window flash open and then close.

I try to run the sc create command manually and it fails with …

DESCRIPTION:
Creates a service entry in the registry and Service Database.
USAGE:
sc create [service name] [binPath= ] …

OPTIONS:
NOTE: The option name includes the equal sign.
A space is required between the equal sign and the value.
type=
(default = own)
start=
(default = demand)
error=
(default = normal)
binPath=
group=
tag=
depend=
obj=
(default = LocalSystem)
DisplayName=
password=

… and when it tries to execute the sysCMD it just fails with the service cannot be started????

Please help!

Rich May 15, 2015 at 7:28 am

I tried to cut and paste the error and it looked correct in the comment box but it’s lost all formating in the above. The bottom line though is I cannot run the sc create command not matter how I try to do it. I am following the format exactly and it just keeps spitting the usage nastygram at me! I am gertting very frustrated!!!

Rich May 15, 2015 at 7:44 am

sort of figured it out partially there MUST be a space after all the “=” signs so the command should be:

sc create SysCMD binPath= “cmd /K start” type= own type= interact

but it is still just flashing a cli window open and it instantly closes and leave a service SysCMD STOPPED. I then have to run the command

sc delete SysCMD

Please what the heck am I doing wrong?>????

Comments on this entry are closed.

Previous post:

Next post: