How to completelly remove docker and all leftovers?

I installed docker for windows. The installer did not allowed me to chose the installation drive (that is ridiculous) and it grabbed 13 GB of space in my C:, leaving only 10 GB free, that is not enough to windows run properly.

I uninstalled docker, but it removed only 3 GB of data.

Where are the other 10 GB and how to remove it?
(no container was installed)

As Docker for Windows uses a technology called Hyper-V to create virtual machines, and these virtual machines take up disk space. When you installed Docker for Windows, it likely created a virtual hard drive (VHD) file for the default virtual machine, which can take up a significant amount of space. You can check the location of this VHD file by going to Control Panel > Programs and Features > Docker for Windows > Uninstall.
You can remove the remaining space by deleting this file.

Also, you can also use the command prompt and type docker system prune to remove all stopped containers, all networks not used by at least one container, all dangling images, and all build cache

Thank you for the answer, Ajeet!

Yes, seems a VHD was created, as there is an icon called “Linux” as a kind of drive.

I uninstalled docker at:
Control Panel > Programs and Features > Docker for Windows > Uninstall
but the VHD still is there.

If I right-click the “Linux” drive and choose “properties”, then pops a message saying “properties are not available”.

That “Linux” is not in the partion’s list, but going to drive C: > PROPERTIES > HARDWARE there is the Microsoft virtual disk.

I entered in its properties and “removed” it, but after restart the computer it is back, and the 10 GB space was not released.

I searched for large files at C: (above 4 GB), setting the system to show hidden files, but could not find any that can be such VHD.

:worried:

The vhdx files for the Docker Desktop WSL distributions are located in %USERPROFILE%\AppData\Local\Docker\wsl\.

Hi Metin,

The directory is empty.
I searched all the C: for *.vhdx files, and could not find anything related to docker.

:frowning_face:

Hi I encountered this issue as well. Is there a fix to this? As sukhoi47 said, directory for %USERPROFILE%\AppData\Local\Docker\wsl\ is empty

Any updates?

I have the same issue.

I can’t find any directory where Docker exists.

I want to get rid of Linux icon in file explorer as it has nothing in it.