How to clean Docker Disk Storage Usage
Dec 14, 2021
Docker Desktop running on WSL 2, WSL2 stores its filesystem on a .vhdx
, that file grows and never releases that space. And it will be consuming all of your empty space of your disk storage.
You could check the size of your .vhdx file at
%LOCALAPPDATA%\Docker\wsl\data\
Below is my .vhdx file size
To clean this huge size consumption, we could open docker dashboard, and we click the Troubleshoot button (the bug icon), then click on “Clean/Purge data”
Note : If you check Windows Container, it will remove all your container and docker images too
After I clean it, my .vhdx file size become 818 MB, previously it is 219 GB
Thanks for reading