MSFN Forum: I want to delete two folders inside my Windows7 partition... - MSFN Forum

Jump to content


Windows 7 forum rules

If you have questions about customizing Windows 7 that are vLite-specific, please post them in the vLite forum, not here. If you have questions regarding the unattended installation of Windows 7, please post them in the Unattended Windows 7/Server 2008 R2 section.
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

I want to delete two folders inside my Windows7 partition...

#1 User is offline   GrofLuigi 

  • GroupPolicy Tattoo Artist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,275
  • Joined: 21-April 05
  • OS:none specified
  • Country: Country Flag

Posted 23 May 2012 - 05:59 PM

...as a help to my filled SSD. These are the ones I picked:

%systemdrive%\Recovery
and
%windir%\System32\DriverStore


I think I will defeat the permissions easily, but how to be sure the beast will stay bootable? I have a growing suspicion that exactly that will happen (unbootability). :)

I chose them because they are large and (with my vague understanding of what they do) they seem nonessential, but I might be wrong.

These are the assumptions:

If I need the first one, I will use the DVD. The second one should be redundant, because there are already drivers in other places. <- Am I wrong with these two sentences?

If Windows7 insists on them, can I persuade it otherwise through registry?

Also, I accept suggestions on other folders to delete, and I have already deleted some.

GL

*edit: I found Driver Store Explorer which should be able to help me. Dissapointed I can't delete it all.

This post has been edited by GrofLuigi: 23 May 2012 - 06:19 PM



#2 User is offline   xpclient 

  • XP was my idea. I had to fight Windows 7 to make it my idea
  • PipPip
  • Group: Members
  • Posts: 233
  • Joined: 30-July 05
  • OS:XP Pro x64
  • Country: Country Flag

Posted 23 May 2012 - 10:17 PM

The DriverStore is where all the drivers shipping with Windows reside as well as any OEM drivers you install as "staged" there. Technically you can delete DriverStore and the OS won't be "damaged" but you will be completely unable to install any drivers. Even for things like a new USB flash drive or a mouse you plug in, they won't work. If you absolutely have no new hardware to install (which would never be the case), you can delete it but not recommended. Read http://blogs.technet.com/b/joscon/archive/2010/09/15/so-what-about-the-driver-store.aspx. You can delete the OEM drivers though. Before that, I hope you have run Disk Cleanup and tried all methods it offers of freeing up disk space (especially the Service Pack 1 files) which are no longer needed if you don't plan to uninstall it as well as all but the last System Restore point and the error memory dumps. Don't touch %systemdrive%\Recovery. You might need to it access the Windows Recovery Environment (WinRE). If you don't use hibernation, disable it and if you need it, you can compress the hibernation file using the cmd: powercfg size 65 from an elevated cmd prompt where 65 is the % of the compressed hibernation file.

Edit: Oops, it's: powercfg hibernate size xx. I forgot the word "hibernate". :) My bad. And yes it cannot be lower than 50 but even at 50 or 55% it won't always successfully resume from hibernate so set it slightly higher.

This post has been edited by xpclient: 24 May 2012 - 01:59 AM


#3 User is offline   bphlpt 

  • MSFN Expert
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,082
  • Joined: 12-May 07

Posted 23 May 2012 - 10:56 PM

View Postxpclient, on 23 May 2012 - 10:17 PM, said:

... If you don't use hibernation, disable it and if you need it, you can compress the hibernation file using the cmd: powercfg size 65 from an elevated cmd prompt where 65 is the % of the compressed hibernation file.


I could not get this to work - I got an "Invalid Parameters" error, and when I tried "powercfg /?", "size" was not listed as an option. [Win7 x64]

Cheers and Regards

#4 User is offline   dencorso 

  • Adiuvat plus qui nihil obstat
  • Group: Super Moderator
  • Posts: 4,866
  • Joined: 07-April 07
  • OS:98SE
  • Country: Country Flag

Posted 24 May 2012 - 01:08 AM

It's:

powercfg -h -size <value>

where, AFAIK, <value> specifies the desired hiberfile size in percentage of the total memory size. It cannot be smaller than 50.
This command also enables automatically the hiberfile.

#5 User is offline   bphlpt 

  • MSFN Expert
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,082
  • Joined: 12-May 07

Posted 24 May 2012 - 02:28 AM

Thanks dencorso. :)

Cheers and Regards

#6 User is offline   GrofLuigi 

  • GroupPolicy Tattoo Artist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,275
  • Joined: 21-April 05
  • OS:none specified
  • Country: Country Flag

Posted 24 May 2012 - 06:16 AM

I have already disabled hibernation. I have already deleted some MUI files for languages I know I won't use on that computer. So far so good. I learned not to touch WinSXS. :)

I'm just looking for additional 'easy kills'. I'm not that much hard pressed for disk space, but every bit freed on SSD helps.

GL

#7 User is offline   MagicAndre1981 

  • after Windows 7 GA still Vista lover :)
  • Group: Patrons
  • Posts: 4,976
  • Joined: 28-August 05
  • OS:Vista Ultimate x86
  • Country: Country Flag

Posted 24 May 2012 - 10:40 AM

View Postxpclient, on 23 May 2012 - 10:17 PM, said:

And yes it cannot be lower than 50


It can be done, but not with the powercfg tool. Change the percent value in the registry and reboot. I set my percentage to 37% and now I have a hibernation file with 2.95 GB when using 8GB RAM.

@GrofLuigi

use legos tool to remove unneeded packages like Hyper-V drivers, TV tuner drivers.

#8 User is offline   GrofLuigi 

  • GroupPolicy Tattoo Artist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,275
  • Joined: 21-April 05
  • OS:none specified
  • Country: Country Flag

Posted 24 May 2012 - 03:33 PM

View PostMagicAndre1981, on 24 May 2012 - 10:40 AM, said:

@GrofLuigi

use legos tool to remove unneeded packages like Hyper-V drivers, TV tuner drivers.

This is a Win7Toolkit installation. :thumbup

But I'm afraid to dig deeper with i.e. dism or Wim tweak because I have ruined some Windows installations before (I just can't stop trimming :blushing: )

GL

#9 User is offline   xpclient 

  • XP was my idea. I had to fight Windows 7 to make it my idea
  • PipPip
  • Group: Members
  • Posts: 233
  • Joined: 30-July 05
  • OS:XP Pro x64
  • Country: Country Flag

Posted 24 May 2012 - 11:54 PM

View PostMagicAndre1981, on 24 May 2012 - 10:40 AM, said:

It can be done, but not with the powercfg tool. Change the percent value in the registry and reboot. I set my percentage to 37% and now I have a hibernation file with 2.95 GB when using 8GB RAM.


I see. But can you resume from hibernate every single time reliably if you set it to 37%? I mean there must be a reason why MS doesn't allow it to be lower than 50%. When I set it to 50%, Windows 7/8 couldn't reliably resume every time.

#10 User is offline   bphlpt 

  • MSFN Expert
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,082
  • Joined: 12-May 07

Posted 25 May 2012 - 12:44 AM

I would guess the actual amount of RAM installed rather than the percentage could be a factor. I'm not sure why they specified it in percentages anyway.

Cheers and Regards

#11 User is offline   MagicAndre1981 

  • after Windows 7 GA still Vista lover :)
  • Group: Patrons
  • Posts: 4,976
  • Joined: 28-August 05
  • OS:Vista Ultimate x86
  • Country: Country Flag

Posted 25 May 2012 - 01:13 PM

View Postxpclient, on 24 May 2012 - 11:54 PM, said:

But can you resume from hibernate every single time reliably if you set it to 37%? I mean there must be a reason why MS doesn't allow it to be lower than 50%. When I set it to 50%, Windows 7/8 couldn't reliably resume every time.


yes, it works fine for me. I've checked what my typical workload is and this is 2GB. So I added 1GB as reserve/buffer and so I have no issues :thumbup

Imagine you have 16GB RAM and with the default 75% you waste 12GB of HDD space for the hibernation file. And even with 50% you have a 8GB file. This is bad :whistle:

#12 User is offline   xpclient 

  • XP was my idea. I had to fight Windows 7 to make it my idea
  • PipPip
  • Group: Members
  • Posts: 233
  • Joined: 30-July 05
  • OS:XP Pro x64
  • Country: Country Flag

Posted 26 May 2012 - 07:32 PM

View PostMagicAndre1981, on 25 May 2012 - 01:13 PM, said:

View Postxpclient, on 24 May 2012 - 11:54 PM, said:

But can you resume from hibernate every single time reliably if you set it to 37%? I mean there must be a reason why MS doesn't allow it to be lower than 50%. When I set it to 50%, Windows 7/8 couldn't reliably resume every time.


yes, it works fine for me. I've checked what my typical workload is and this is 2GB. So I added 1GB as reserve/buffer and so I have no issues :thumbup

Imagine you have 16GB RAM and with the default 75% you waste 12GB of HDD space for the hibernation file. And even with 50% you have a 8GB file. This is bad :whistle:


Can you share which registry key please, Andre? I am too lazy to use Process Monitor.

#13 User is offline   MagicAndre1981 

  • after Windows 7 GA still Vista lover :)
  • Group: Patrons
  • Posts: 4,976
  • Joined: 28-August 05
  • OS:Vista Ultimate x86
  • Country: Country Flag

Posted 27 May 2012 - 01:04 AM

The key is named HiberFileSizePercent and is located under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power. reboot your PC after changing the value

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

2 User(s) are reading this topic
0 members, 2 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy