DEV Community

Cover image for wslcompact - Optimize Huge Virtual Hard Disk without diskpart/Hyper-V
Viktor Starodubtsev
Viktor Starodubtsev

Posted on

wslcompact - Optimize Huge Virtual Hard Disk without diskpart/Hyper-V

Problem

When trying to optimize disk space the same way as described in this post, I discovered that neither of both solutions can be applied on Windows 11 Home Edition.

Solution

wslcompact

It turned out that wslcompact doesn't force you to work with diskpart nor HyperV and encounter problems of their
unavailability on Windows Home.

You can find the up-to-date and verbose installation guide in the tool's README.

Experience

Now, I would like to demonstrate how it works on my machine.

How it was before

before-1

before-2

Now let's delete a huge directory on Ubuntu

delete-huge-directory

And now the estimated weight of our distro is much less

estimated-size

Let's compact now!

after-1

after-2

As you can see, we claimed our unused disk space back with only couple of prompts.

Top comments (0)