首页 文章

使用scp文件复制到Amazon EC2时会在16K上停止传输

提问于
浏览
0

我正在尝试使用scp将文件复制到Amazon EC2 AMI实例并使用该命令

scp -i ~/.ssh/azhdanov_aws.txt udt-0.9.jar ec2-user@ec2-18-191-152-48.us-east-2.compute.amazonaws.com:~

但我收到了:

0%    0     0.0KB/s   --:-- ETApacket_write_wait: Connection to 18.191.152.48 port 22: Broken pipe

我可以用ssh登录

ssh -i ~/.ssh/azhdanov_aws.txt ec2-user@18.191.152.48

并且看到卷上有正好16K字节的文件

drwx------ 3 ec2-user ec2-user  4096 Jun 15 13:15 .
drwxr-xr-x 3 root     root      4096 Apr  6 10:59 ..
-rw------- 1 ec2-user ec2-user  2102 Jun 15 13:12 .bash_history
-rw-r--r-- 1 ec2-user ec2-user    18 Aug 30  2017 .bash_logout
-rw-r--r-- 1 ec2-user ec2-user   193 Aug 30  2017 .bash_profile
-rw-r--r-- 1 ec2-user ec2-user   124 Aug 30  2017 .bashrc
drwx------ 2 ec2-user ec2-user  4096 Apr  6 10:59 .ssh
-rw-r--r-- 1 ec2-user ec2-user 16384 Jun 15 13:15 udt-0.9.jar

然后我通过复制vm上的文件检查我没有卷限制:

drwx------ 3 ec2-user ec2-user  4096 Jun 15 13:27 .
drwxr-xr-x 3 root     root      4096 Apr  6 10:59 ..
-rw------- 1 ec2-user ec2-user  2102 Jun 15 13:12 .bash_history
-rw-r--r-- 1 ec2-user ec2-user    18 Aug 30  2017 .bash_logout
-rw-r--r-- 1 ec2-user ec2-user   193 Aug 30  2017 .bash_profile
-rw-r--r-- 1 ec2-user ec2-user   124 Aug 30  2017 .bashrc
drwx------ 2 ec2-user ec2-user  4096 Apr  6 10:59 .ssh
-rw-r--r-- 1 ec2-user ec2-user 16384 Jun 15 13:27 copy_udt-0.9.jar
-rw-r--r-- 1 ec2-user ec2-user 16384 Jun 15 13:15 udt-0.9.jar

似乎我没有超过EC2限制:

My Amazon services usage

调试信息没有得到我的答案为什么我不能复制超过16K的文件:

debug3: send packet: type 98
debug3: Ignored env SECURITYSESSIONID
debug3: Ignored env _
debug3: Ignored env __CF_USER_TEXT_ENCODING
debug1: Sending command: scp -v -t ~
debug2: channel 0: request exec confirm 1
debug3: send packet: type 98
debug2: channel_input_open_confirmation: channel 0: callback done
debug2: channel 0: open confirm rwindow 0 rmax 32768
debug2: channel 0: rcvd adjust 2097152
debug3: receive packet: type 99
debug2: channel_input_status_confirm: type 99 id 0
debug2: exec request accepted on channel 0
Sending file modes: C0644 11610816 udt-0.9.jar
debug2: channel 0: rcvd ext data 33
Sink: C0644 11610816 udt-0.9.jar
debug2: channel 0: written 33 to efd 8
udt-0.9.jar                                                                                                                                                        
0%    0     0.0KB/s   --:-- ETAdebug3: send packet: type 1
packet_write_wait: Connection to 18.191.152.48 port 22: Broken pipe
lost connection

1 回答

  • 0

    问题现在已经消失,我无法找到根本原因 . 希望它将来不会重现 .

相关问题