server network

<aside>

SSH in windows

PowerShell 7.x

https://learn.microsoft.com/zh-cn/windows-server/administration/openssh/openssh_install_firstuse?tabs=powershell&pivots=windows-11

Get-WindowsCapability -Online | Where-Object Name -like 'OpenSSH*'
# Install the OpenSSH Client
Add-WindowsCapability -Online -Name OpenSSH.Client~~~~0.0.1.0

# Install the OpenSSH Server
Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0

</aside>

<aside>

sshd_config配置清单/etc/ssh/sshd_config

sudo nano ~/.ssh/authorized_keys

</aside>

ssh登录

SSH简介及两种远程登录的方法_ssh @-CSDN博客

ssh -o ServerAliveInterval=30 -p 22 [email protected]

exit

Example:

利用跳板机SSH登录

config 文件配置:(ssh -F “path-to-config”)

推荐配置

Host *
         ServerAliveCountMax 5                
         ServerAliveInterval 30

Host codeup
	HostName git@

Host VPS-ip
    HostName ECS-jump-IP
    User hazy
    Port 22
    IdentityFile "D:\\Open-SSH\\id_ecs"

Host jump-to-c1m3
    HostName ECS-C1M3-private-IP
    User ecs-user
    Port 22
    ProxyJump VPS-ip
    IdentityFile "D:\\Open-SSH\\id_c1m3"
    IdentitiesOnly yes
    ForwardAgent no
    ForwardX11 no
    ForwardX11Trusted no

ssh密钥

【Client】添加密钥 - #1

HOW TO SAVE PRIVATE KEY?

RUN IN GIT BASH

https://blog.csdn.net/Dior_wjy/article/details/79035214