Friday, January 10, 2014

Free up space in Windows 8

This is sort of up there in terms of freeing up space. A bit over the top for the ordinary users.
There is however a method of removing the install files for Windows features you don’t need. It goes like this:
/>dism.exe /online /disable-feature /featurename:sua /remove
But if you want to remove a lot of not needing features this could be tedious. enter powershell
------------flushfeatures.ps1-----------
foreach ($item in get-content featuresclean.txt)
{
write-host "Removing feature $item"
dism.exe /online /disable-feature /featurename:$item /remove
    }
-----------eof-------------
Where featuresclean.txt is a file where every line contains a feature to be flushed.
To get all windowsfeatures on the system in a single list it can be a bit tricky.
I solved it a bit rough bit
/>get-windowsoptionalfeature –online |? state –eq ‘disabled’ |export-csv output.csv
and then copied the relevant columns from the csv to featuresclean.txt
Really not recommended if you don’t know what your doing
References:
http://technet.microsoft.com/en-us/magazine/2007.04.powershell.aspx
http://blogs.technet.com/b/joscon/archive/2012/11/20/features-on-demand-in-windows-8-and-windows-server-2012.aspx
http://technet.microsoft.com/en-us/library/hh824822.aspx
http://www.howtogeek.com/174705/how-to-reduce-the-size-of-your-winsxs-folder-on-windows-7-or-8/

No comments:

Powershell and Uptimerobot

Uptimerobot can be quite tedious when you need to update many monitors at once. For example say you bought the license for Uptimerobot and n...