-
- 先在win左下角找到设置,搜索开发者模式
- 控制面板搜索:启用或关闭功能中选中:适用于linux子系统的win子系统
- 在微软商店中搜Ubuntu下载安装
- 之后win d盘对应Ubuntu /mnt/d
- 默认的wsl没有设置root密码,设置管理员: sudo passwd root. 来设置root密码
- 下载好go和gcc之后 修改path:cd ~; sudo vi ~/.profile ;sudo source ~/.profile
- export GOPATH=/mnt/d/gopath/src/
- export GOROOT=/mnt/d/tool/go
- export PATH=$PATH:$GOROOT/bin
- 使用xshell登录win子系统
#sudo apt-get remove --purge openssh-server ## 先删ssh
#sudo apt-get install openssh-server ## 在安装ssh
#sudo rm /etc/ssh/ssh_config ## 删配置文件,让ssh服务自己想办法链接
#sudo service ssh --full-restart 重启ssh
-
- 安装文件在/etc/ssh/sshd_config 配置之后重启
- #设置root的口令(密码),用作后续登陆使用
sudo passwd root
#安装openssh-server(似乎ubuntu自带已安装)
sudo apt install openssh-server
#备份很重要
sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_conf
- #设置root的口令(密码),用作后续登陆使用
- 安装文件在/etc/ssh/sshd_config 配置之后重启