Managing Windows subsystem for Linux (WSL)

If you activate the WSL Windows feature, images and config will reside under %userprofile%\AppData\Local\Packages

Some simple powershell commands for managing WSL

List images

wsl -l -v

Uninstall an image:

wsl --unregister kali-rolling
removes your image of choice

Backup your image:

wsl --export <distro> <filename.tar>

Import your image:

wsl --import <distro> <install location> <filename> 

Upgrade WSL version:

wsl --set-version <distro name> 2

Stop WSL:

wsl --shutdown

Kali Linux specific tip:

Run Kali in a nice desktop experience

More articles

DISM repair Windows Server 2016

Repair Windows Server 2016 with DISM dism /online /cleanup-image /scanhealth dism /online /cleanup-image /checkhealth dism /online /cleanup-image /restorehealth /source:WIM:d:sourcesinstall.wim:2 /limitaccess sfc

Read More »