If you have to reinstall a distro for WSL it loses the default setting so that bash
from PowerShell
no longer works.
Here is the fix
wsl --list
This will get the current distributions on your machine. The distro you installed should be there
wsl --set-default <distro>
Replace <distro> will the distro name
Use wsl -l -v
to list the WSL version and distro versions
Use wsl --distribution <distro>
to start a distro, it’s the same as doing bash
from PowerShell.
Use wsl -t <distro>
to terminate a running distro.
If you get an error saying a feature has not been enable or installed after enabling the WSL, try enabling the virtual machine option as shown below, restart the host machine, and try reinstalling a distro, solution courtesy of https://superuser.com/questions/1736443/wsl-2-installing-linux-failed-error-code-0x80370114