我试图从一个ec2实例到另一个(通过SSH客户端)的SCP。 两台服务器都使用相同的密钥。
我最初的调查使我相信,通过使用AgentForwarding这一切都是可能的:
scp -o "ForwardAgent yes" -v /path/to/file [email protected]:/path/to/file
创build输出结束于:
> debug1: Connecting to xx.xx.xx.xx [xx.xx.xx.xx] port 22. debug1: > connect to address xx.xx.xx.xx port 22: Connection timed out ssh: > connect to host xx.xx.xx.xx port 22: Connection timed out lost > connection
或者,我也试着用-i指定一个密钥文件,但是我只有.ppk和.key文件版本,而不像大多数例子所显示的.pem。 我在/home/ec2-user/.ssh/id_rsa(在.ssh目录下的所有文件都是'config','known_hosts'和'authorized_keys')也没有文件,这似乎是许多人使用的解决scheme。
我已经尝试编辑configuration,并添加AgentForwarding yes也有。
似乎没有任何工作,我最终在所有的尝试中得到同样的时间消息。
我遇到了很多的阻力,所以任何帮助,将不胜感激。 谢谢!
我要检查的第一件事是确保您的安全组允许此服务器间通信。