Is your feature request related to a problem? Please describe.
My IT department blocked diskpart 🙄 but turns out there's another option for Windows Pro machines with Hyper-V.
Describe the solution you'd like
- (WSL)
sudo fstrim -av
- (Host)
wsl --shutdown
- (Host)
Optimize-VHD -Path "/foo/bar/ext4.vhdx" -Mode Full
https://dev.to/octasoft-ltd/managing-wsl-disk-space-fm9
https://learn.microsoft.com/en-us/powershell/module/hyper-v/optimize-vhd?view=windowsserver2025-ps
Is your feature request related to a problem? Please describe.
My IT department blocked
diskpart🙄 but turns out there's another option for Windows Pro machines with Hyper-V.Describe the solution you'd like
sudo fstrim -avwsl --shutdownOptimize-VHD -Path "/foo/bar/ext4.vhdx" -Mode Fullhttps://dev.to/octasoft-ltd/managing-wsl-disk-space-fm9
https://learn.microsoft.com/en-us/powershell/module/hyper-v/optimize-vhd?view=windowsserver2025-ps