wsl.rst
changeset 2580 6f1bb96dc0d2
parent 2543 a1103b02f8f3
child 2583 1eb4d7b161be
--- a/wsl.rst	Thu Feb 08 16:28:59 2024 +0200
+++ b/wsl.rst	Sat Feb 10 16:09:29 2024 +0200
@@ -176,3 +176,18 @@
   [wsl2]
   kernel=C:\\Users\\<USER>\\vmlinux
 
+Enabling trimming
+=================
+
+::
+
+  wsl --manage $NAME --set-sparse true
+  wsl --manage $NAME --set-sparse false
+
+or in ``.wslconfig``::
+
+  [experimental]
+  sparseVhd=true
+
+https://devblogs.microsoft.com/commandline/windows-subsystem-for-linux-september-2023-update/#automatic-disk-space-clean-up-set-sparse-vhd
+  Automatic disk space clean up (Set sparse VHD).