Skip to main content

intro

What is WSL?

WSL stands for Windows Subsystem for Linux. It is a compatibility layer for running Linux binary executables natively on Windows 10 and Windows Server 2019. It was developed by Microsoft and first introduced in Windows 10 Anniversary Update.

general issues and solutions

  1. install ssh but failed to start with systemctl
sudo apt-get install openssh-server
sudo systemctl start ssh
sudo systemctl enable ssh

wsl default not start systemd, if you want to use systemctl, you can ref this link

  1. how to ssh to wsl

wsl is a vm and for local develop, if need remote connet need other setting, if need remote access, I usually use linux(ubuntu or debian), and you can use ssh to connect to it when you are at local environment, use below command to get the ip address

ip -c a

and you will get an ip like 174.xxx.xxx.xxx, then you can use ssh to connect to it