Windows 子系统 WSL 一些记录

安装 SSH 并开启外部访问

sudo apt install openssh-server

启动

sudo service ssh start

编辑配置文件

vim etc/ssh/sshd_config

找到 passwordAuthentication no 把 no 改为 yes

去掉注释并将 PermitRootLogin without-password 改为 PermitRootLogin yes

Windows 子系统 WSL 开机启动服务

Linux 中创建执行脚本

sudo vim /etc/init.wsl

编辑器编写保存并赋予权限

#! /bin/sh
/etc/init.d/ssh start
/etc/init.d/mysql start
/etc/init.d/php-fpm start
/etc/init.d/nginx start 
sudo chmod +x /etc/init.wsl
Continue reading Windows 子系统 WSL 一些记录