windows openssh安装

下载地址:https://github.com/PowerShell/Win32-OpenSSH/releases

20191224135310-openssh.png

解压好后打开目录,执行以下命令:

powershell.exe -ExecutionPolicy Bypass -File install-sshd.ps1

设置服务自动启动并启动服务:

sc config sshd start= auto
net start sshd

也可以在服务控制台设置

20191224135602-openssh-services.png

服务默认端口是22,需要开启。

测试一下收可以执行远程命令:

>ssh -p 22 administrator@远程服务器IP
administrator@远程服务器IP's password:
Microsoft Windows [版本 6.3.9600]
(c) 2013 Microsoft Corporation。保留所有权利。
administrator@iZw7c6o089km3dZ C:\Users\Administrator>dir

猜你喜欢

转载自www.cnblogs.com/ricolee/p/win-openssh.html