-
Notifications
You must be signed in to change notification settings - Fork 834
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wsl --manage Alpine --set-sparse true # No result for auto disk space clean up (Set sparse VHD) #10703
Open
1 of 2 tasks
Comments
This comment was marked as resolved.
This comment was marked as resolved.
Any updates please? |
Bump |
+1 |
1 similar comment
+1 |
any fix yet? same issue |
+1 |
I have the same issue wait for help. |
I used wsl updates from |
2 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Windows Version
Microsoft Windows [Version 10.0.22621.2428]
WSL Version
2.0.6.0
Are you using WSL 1 or WSL 2?
Kernel Version
Linux version 5.15.133.1-microsoft-standard-WSL2 (root@1c602f52c2e4) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) #1 SMP Thu Oct 5 21:02:42 UTC 2023
Distro Version
Alpine distribution, MINI ROOT FILESYSTEM, x86_64, "alpine-minirootfs-3.18.4-x86_64.tar.gz"
Other Software
No response
Repro Steps
WSL - Automatic disk space clean up (Set sparse VHD)
I followed the topic:
Import any Linux distribution to use with WSL
https://learn.microsoft.com/en-us/windows/wsl/use-custom-distro
Obtain from "https://alpinelinux.org/downloads/" a tar file for the Alpine distribution, MINI ROOT FILESYSTEM, x86_64,
alpine-minirootfs-3.18.4-x86_64.tar.gz
.Import the tar file into WSL
wsl --import Alpine D:\wslDistroStorage\Alpine .\alpine-minirootfs-3.18.4-x86_64.tar.gz
https://devblogs.microsoft.com/commandline/windows-subsystem-for-linux-september-2023-update/#automatic-disk-space-clean-up-set-sparse-vhd
Update WSL to pre-release:
wsl --update; wsl --update --pre-release
wsl --shutdown
wsl --manage Alpine --set-sparse true
Where
Alpine
is an example distribution.C:\Users\UserName\.wslconfig
and add its content:
[wsl2]
[experimental]
sparseVhd=true
Now, test:
wsl -d Alpine
cd ~
cp /mnt/c/tmp/some-file-about-3GB-size .
D:\wslDistroStorage\Alpine\ext4.vhdx
increased the size from about 100 MB to 3.5GB.
rm some-file-about-3GB-size
D:\wslDistroStorage\Alpine\ext4.vhdx
Nothing happened.
Expected Behavior
Automatic disk space clean up
Actual Behavior
No disk space clean up
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: