Friday, June 21, 2013
Jeez windows, lets put you on a diet
So, all of y'all with solid state drives know the bizaareness that is windows 7 or 8.
Windows 7 or 8 64 bit has an initial install size of around 18-20gigs. It can be upward to 50 gigs if you're not careful.
Wait, 50 gigs? HOLY SHIT MAN, WHAT KIND OF BITTY FOOD IS THAT OS EATING?
Well, it's not exactly the OS data persay.
There are 4 massive sections to windows, and 2 of the 4 get massively expansive, the more memory you have.
WinSXS gets huge
Virtual Memory gets huge
Hibernate.sys gets huge
SoftwareDistribution gets huge
So, what the pronged stabby utensils are these things?
WinSXS is a folder that contains a copy and a dynamic link to every single version of every single DLL you ever needed, for every software you have installed. This was created to fix the missing DLL hell that existed in XP.
Uninstalled unneeded applications, regardless of the drive the app is installed on can remove a lot of it. It's imperfect, but it works. There really isn't much else you can do here.
Virtual memory for some reason is set to match your ram. That was fine during the days when people had like 1 gig of ram. If you have 16 or 32 gigs, that's obnoxious. Sometimes it's set to be a dynamic variable, which is even worse because it causes horrific fragmentation.
If you open up a file explorer, find "computer", right click it and press properties. Then click advanced system settings, then under the advanced tab, under the performance section, press settings. Switch to the advanced tab, press change, select custom size, and set both the minimum, and maximum size to 2048. Press Ok until you're out of this mess. The next time you reboot, your virtual memory will be 2 gigs.
Fixing hibernate.sys is easy! Just get rid of it.
Press start (or open start screen), type cmd, rightclick on it and run as administrator.
Let windows user account control approve it's usage, if it asks.
In cmd, type
powercfg -h off
Press enter. The next time you reboot, you will no longer be able to hibernate. Do note, on windows 8, this will slightly increase boot times. If you're on a SSD, you won't care too much though. To reverse it, powercfg -h on works.
This file on a 32 gig ram system is 32 gigs. That's frightening.
Ok. What the heck is SoftwareDistribution? It's a data storage location for all of your old windows updates.
It's typically found at C:\Windows\SoftwareDistribution
On windows 8, it currently can't get big, but on windows 7, it can take up a few unnecessary gigs.
Finish all of your windows updates, as normal (do them, right meow!), then reboot, and then delete the entire contents of this folder. If something won't delete for whatever reason, delete everything but that file.
Doing all of this will slim a WTF HUGE windows 7 or 8 install down to 10 to 14 gigs. This is much more manageable on a SSD
OH btw guys, if you ever use a virtual machine of windows, all of these steps will also apply! Save your space, guys.
Do note guys, if you try these things on windows 2008 R2 or 2012 server, particularly as a virtual machine, I recommend playing around with the virtual memory quantity as necessary. On 2012, you may consider NOT disabling hibernate, because it can increase boot times, which increases downtime during reboot, or the time to load an instance on a cloud provider.
Now I want a cup of tea, cheers!
Subscribe to:
Post Comments (Atom)

No comments:
Post a Comment