0
votes

I'm trying to copy file using scp to Amazon EC2 AMI instance with the command

scp -i ~/.ssh/azhdanov_aws.txt udt-0.9.jar [email protected]:~

but I recieved:

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

I can login with ssh

ssh -i ~/.ssh/azhdanov_aws.txt [email protected]

and see that there are exactly 16K bytes of file on the volume

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

Then I checked I dont have a volume limit by copy the file on 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

And seems I didnot exceed EC2 limits:

My Amazon services usage

Debug info didnot get me an answer why I could not copy files more then 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
Did you try rsync? rsync.samba.org/examples.htmlstrongjz
@strongjz, this time no data is trasfered at all: rsync -avL --progress -e "ssh -i ~/.ssh/azhdanov_aws.txt" ~/temas/git/protocols-benchmark/udt/build/libs/udt-0.9.jar [email protected]:~ building file list ... 1 file to consider udt-0.9.jar packet_write_wait: Connection to 13.59.11.218 port 22: Broken pipe rsync: writefd_unbuffered failed to write 32768 bytes [sender]: Broken pipe (32) rsync: connection unexpectedly closed (174 bytes received so far) [sender] rsync error: unexplained error (code 255)at/BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-52/rsync/io.cuser5910784
I would check /var/log/secure and /var/log/messages on both servers while doing the backup. Are they any firewalls between the two servers?strongjz

1 Answers

0
votes

The problem is gone right now and I did not manage to get the root cause. Hoping it will not reproduce in future.