I have a old Win XP system running as a Virtualbox guest on a linux host. The image is really large because of an (apparent) large winsxs directory on the windows guest.

I know that this is due to the fact that because of the hardlinks the size is not calculated correctly, but on the linux host, this space is really occupied.

Using vboxmanage's compact (after an sdelete on the win guest) command on the linux host doesn't help:

vboxmanage modifymedium --compact /path/to/thedisk.vdi

So what can I do about this?

  • "So what can I do about this?" - You cannot the WinSxS directory should not be modified. The current size is what is required for your system to function. There are no tools to reduce the size of the WinSxS directory on Windows XP. What you want isn't possible. – Ramhound Nov 1 '17 at 20:35
  • Following this anwer: superuser.com/a/372191/53616 the winsxs directory contains actually hardlinks because of that windows reports the occupied space wrong. So, actually much less space is used than reported by windows. – student Nov 1 '17 at 20:39
  • I am more familiar with that fact, check my answers on WinSxS, my point is no tools exist to reduce the actual size. Only Windows 7 has a single DISM command to reduce the size. Even then Windows 7 options are pale in comparison to DISM on Windows 8+. Sounds like your current problem is a VirtualBox issue not a Windows issue. Sadly, VirtualBox doesn't support shrinking virtual hdds. – Ramhound Nov 1 '17 at 20:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.