Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: WinSXS Folder not actually consuming lots of space

19 Jun 2012   #21
pxfragonard

Microsoft Windows 7 Home Premium 64-bit 7601 Multiprocessor Free Service Pack 1
 
 

How does one get rid of the hard links so the "properties" tab runs true?


My System SpecsSystem Spec
.

19 Jun 2012   #22
logicearth

Windows 8.1 Pro (x64)
 
 

Quote   Quote: Originally Posted by pxfragonard View Post
How does one get rid of the hard links so the "properties" tab runs true?
You don't.
My System SpecsSystem Spec
11 Dec 2014   #23
jonnyhotchkiss

Windows 7 Ultimate 64bit
 
 

everyone is interested in this!

look at the time dedicated to attempting to get a true reflection of the space consumed by files alone - that is my understanding of the issue here (unable to understand true folder size, ignoring hardlinks)

Many others asking for similar

I use the amazing TuneUp Utilities, and the Disk Space Explorer has excellent filtering options.. but nothing for "ignoring hard-links"

The previous tool I used (treesize) does have that option... but apparently only as an option in it's duplicate file finding functionality.

solution: try and ignore the gargantuan growth of the windows folder?

Almost every atom of me is screaming don't do this
My System SpecsSystem Spec
.


11 Dec 2014   #24
jonnyhotchkiss

Windows 7 Ultimate 64bit
 
 
keep it simple! listen to pparks!

Quote   Quote: Originally Posted by pparks1 View Post
Quote   Quote: Originally Posted by Belgarionbg View Post
Lets make it simple. So that space exist but is not usable in normal everyday way. That I wanted to know
You aren't making it simple, you are not understanding it completely.

1). Some of the files, are real files. They really take up some space on your hard drive. These reduce the amount of space available to store files and install applications.
2). The other items are hardlinks to files that exist someplace else on the hard drive. Now, the real true physical file exists and WILL decrease the amount of space that is really on your hard drive. The hardlinks are NOT real physical files and DO NOT consume disk space on your hard drive.

Go back to my example recently.
  • I started with 44.9GB of free disk space.
  • I copied in a "REAL" file that was about 650MB in size
  • My hard drive space dropped to 44.2GB of free disk space. This is what applications have access to and represents how much stuff I can copy onto my hard drive before it's full.
  • I then created numerous hardlinks and made it appear that my C:\Windows\aTestFolder had almost 4GB of stuff in it.
  • I demonstrated that TreeSize free would report an increased size of my C:\windows folder and would report that C:\windows\aTestFolder was 4GB in size.
  • But looking at my command prompt showed that my free drive space stayed consistent at 44.2GB of free space. it's the same amount of space that I had above, applications still have access to the exact same amount of free space. (even though I magically created what appears to be 4GB folder called C:\windows\aTestFolder)
  • I could have made 500 hard links to that same file and made it appears that my C:\windows\aTestFolder was (500 x 650MB) was 325GB in size. Treesize free would show a 325GB folder, and Explorer would show a 325GB folder if I looked at properties. All miraculously on my 80GB hard drive.
  • Even with 500 hard links to the file, my command prompt would continue to show 44.2GB of space free. (Because none of these hardlinks actually decrease the amount of free space on your hard drive.


So, NO....it's not like the space exists and you cannot use it in everyday use. The space that is free can be demonstrated with a command prompt or looking at Windows Explorer...or the bottom of the TreeSizeFree window. The hardlinks DO NOT, and HAVE NOT reduced the amount of free space on your hard drive. The amount of hardlinks have never counted against you.

the 4.2GB worth of hardlinks you discovered have NOT reduced your available free space by 4.2GB. In fact, if they did actually count against you, instead of having 8GB of free space on your hard drive, it would actually drop to 4.

YOU ARE NOT BEING CHEATED OUT OF ANY SPACE, THE SPACE ISN'T MASKED OFF AND UNUSABLE.
I've read a few pages this morning on this winsxsx and hardlinks and actual folder size thing. On this thread pparks is the only one who is clear enough with his explanation for me to glean any insights.

VERY surprised re the apparent absence of apps developed to deliver info on (what I would class as) actual folder size...

So I understand (thanks to pparks clear workings why this misunderstanding occurs...
My question is: how do we use this info to work out folder size (files only) as efficiently as possible?

I can imagine it could involve subtracting (actual) free space from (actual) volume size ... and then I get stuck....

If we could identify hard links, count them recursively, and subtract that from reported folder size, would that work?

Thanks

My System SpecsSystem Spec
11 Dec 2014   #25
jonnyhotchkiss

Windows 7 Ultimate 64bit
 
 

finddupe c:\windows\** -listlink

Files: 16722836 kBytes in 83506 files
Dupes: 1600291 kBytes in 11492 files
12 files of zero length were skipped
18 files could not be opened

This is a clean build, with zero windows functions installed.

I calculate that 1.526(GB) of windows is duplicates; taken from reported (16.23) that makes windows ~ 14.704GB


on winsxs

Files: 13417882 kBytes in 59325 files
Dupes: 1108638 kBytes in 7692 files (1gb)
2 files could not be opened

great article here, the author claims his 5Gb winsxs is only ACTUALLY 1.5 GB (references hardlink scanner, broken link )

I'm wasting so much time being obsessive compulsive over this because I'm trying to get as small a footprint on my base VHD as possible.

Would love to hear if anyone else has similar figures to the author, and especially if anyone has a copy of hardlink's installer / URL they can share.

thanks again
My System SpecsSystem Spec
11 Dec 2014   #26
jonnyhotchkiss

Windows 7 Ultimate 64bit
 
 

found hardlink scanner (thanks james ross!)

Does anyone know what params to give hardlink scanner to ascertain how much of a folder (winsxs, for example is actually extra hardlinks?

ie how to do

EN only:

Full size: 6.18 GB
Hard links: 4.80 GB
Normal files: 1.37 GB

Given that every file is a hardlink, and we're interested in files with more than one hardlink, I tried

"Hardlink Scanner.exe" c:\windows/winsxs /c 2
(count: 2)

and got this
Naive file size: 10,305,500,773
Unique file size: 9,129,396,568 ( 88%)
Difference: 1,176,104,205 ( 11%)
My System SpecsSystem Spec
11 Dec 2014   #27
LMiller7

Windows 7 Home Premium 32 bit
 
 

It is important to understand that the folder size reported (by any utility) is at best only an approximation. There are numerous issues involved, hard links being only one. The problem is inherent in any file system but particularly so in complex file systems like NTFS. This blog entry explains this in more detail:

Computing the size of a directory is more than just adding file sizes - The Old New Thing - Site Home - MSDN Blogs

The author of the blog is Raymond Chen, a Microsoft developer since prior to Windows 95.
My System SpecsSystem Spec
Reply

 WinSXS Folder not actually consuming lots of space




Thread Tools





Similar help and support threads
Thread Forum
Large Windows and winsxs folders taking up too much space
I have an ultrabook with 128 GB of space, 101 GiB after partitioning and so on, so it got annoying when I just checked my C:\Windows directory and it was up to 25 GBs, with winsxs up to 14 GBs. I had heard on Windows Weekly that there was a way to clean up the winsxs directory now, so I followed...
Performance & Maintenance
Windows 7 OS consuming 100GB space ,how????
Thank's for stopping by, I was wondering how just the windows 7 operating system alone takes nearly 100GB? :cry: I am trying to use my c drive just for os keeping all other stuff in other partition-assuming this will speed up system!!! (HDD reading speed,my windows experience index lacks(5.9)...
Performance & Maintenance
Winsxs file already consumes half of my disk space...
I recently replaced a 60GB SSD because my winsxs file was using over 25GB and I was down to about 8GB of usable space. I went out and bought an 80GB SSD and after my install it was already half full before I put any application on it. The winsxs file is already at 11GB and I really do not want to...
Installation & Setup
Too much space on OS drive being taken up by WinSxS
This may be an old one but couldn't find any ready answers to fix it. I am running out of disk space on my OS drive and having run TreeSize, I discovered that the WinSxS folder is taking up over 11.5 GB. Has anybody ever found a solution to this problem?
General Discussion
Cannot shrink any more space... When I have lots of space left.
I have a partition set at 237 GB. I have 161 GB of free space left and want to move more out of the partition. But it would not let me move more out. Is this a bug or something?
Performance & Maintenance
winsxs folder
can it be deleted without damage to the system , i ask this as it has took up 11gb of space in my hard drive , thanks
General Discussion

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 08:26.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App