要登录ssh
我执行以下操作:
ssh -i ~/.ssh/kp1.pem [email protected]
我尝试了所有这些mosh
:
mosh --ssh='ssh -i ~/.ssh/kp1.pem [email protected]'
mosh -i ~/.ssh/kp1.pem [email protected]
但我收到了错误:
/usr/bin/mosh: could not get canonical name for /home/$USER/.ssh/kp1.pem: Name or service not known
ssh_exchange_identification: Connection closed by remote host
/usr/bin/mosh: Did not find remote IP address (is SSH ProxyCommand disabled?).
答案1
我最终需要运行如下命令:
mosh --ssh="ssh -i ~/.ssh/kp1.pem" [email protected]
这可行,但我还需要在安全组下的 EC2 管理控制台中添加运行60001
端口的规则。mosh