5

I have problem copying files to cloud servers with SCP from my office. When I do scp of 17MB war file it says STALLED and then reconnect and again says stalled like the one below:

#scp Desktop/myapp.war user1@204.x.x.x:/tmp/

user1@204.x.x.x's password: 
myapp.war                                         12% 2112KB 736.4KB/s - stalled -^

I checked if it the problem with my ISP but, checking the upload speed they said everything is fine from their side and personally I checked attaching the file in the gmail and it uploaded fine in 3mins usually. So I think no issue from the ISP side.

Contacted the cloud server technician if they could help, and they proved sending files between cloud servers and said everything is fine from their side.

I tried other cloud servers, tried winSCP, tried rsync but the result is same. Somehow I have to make this work as how it was, because the web-developers are waiting for the production deployment.

Today, I took someones help to copy to the Staging cloud server allowing his ip in iptables. This means only from my office the scp stalls but from outside if you have access then everything works fine.

I'm not knowing how I could solve this issue. I think I should have very good network side knowledge. Anybody came across this?, how it could be solved?.

Please need help. Thank you!

user53864
  • 1,653
  • 8
  • 36
  • 66
  • An ugly solution is "netcat 204.x.x.x 7777 < Desktop/myapp.war" and "netcat -l -p 7777 > /tmp/". But you don't get crypted transfer this way. Try if it will work and post the result. – HUB May 30 '11 at 16:32
  • An [automatically-reconnecting TCP tunnel](http://serverfault.com/questions/275321/automatically-reconnecting-tcp-tunnel) would be a general workaround for this kind of unreliable network. – Gilles 'SO- stop being evil' May 30 '11 at 19:48
  • Anybody has any clue? – user53864 May 31 '11 at 05:29

2 Answers2

3

It looks like something between you and the server is dropping connections, possibly an overloaded firewall. I'm afraid I don't have any advice on fixing that, but I'll offer a workaround.

Invoke rsync with the --partial option (or -P), or rsync --partial-dir=.rsync-partial. If the connection is dropped, run rsync again with the same arguments, and the copy will resume where it left off.

1

Sorry!, the problem is at the ISP's end and got it fixed raising 2,3 complaints.

user53864
  • 1,653
  • 8
  • 36
  • 66