4

Guys this is an error I am getting when I try sending files to a server. I am not sure what went wrong. Can anyone help me fix this? Thanks in advance.

$ rsync -avz ./ ssc:/webapp/

rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
rsync error: error in rsync protocol data stream (code 12) at io.c(235) [Receiver=3.1.3]
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(228) [sender=3.2.4dev]

4 Answers 4

4

https://youtrack.jetbrains.com/issue/IDEA-270793

i add "-e /usr/bin/ssh" and it fixed the issue.

rsync -e /usr/bin/ssh -vP /c/projects/cpp/RecFileExtractBatch/example_recfile_extract_command_file.xml thtran@p811:/home/thtran/mnt_win_pdatx_linux

2

I'm using cygwin rsync on Windows 11. I'm still not 100% sure why this only started failing for me recently, but I found that using Windows OpenSSH with cygwin rsync was causing the error.

I wound up installing OpenSSH for cygwin and moved C:\cygwin\bin before C:\WINDOWS\System32\OpenSSH\ in my Path in Environment Variables. That fixed it for me.

1

GentlemanJohn's answer was extremely helpful for me. I took his advice but I used /user/bin/ssh instead of revising my path. As in:

$ rsync -avz -e "/bin/ssh -i .ssh/id_rsa" --progress [email protected]:/ads/qsmrp/ qsmrp

(The trailing slash on the qsmrp directory indicates copy its content only.)

The Windows version of openssh prevented rsync from working (0 bytes transferred).

0

Remove OpenSSH-Cliente on ''Settings' > 'Apps' > 'Optional Features', install Git and add C:\Program Files\Git\usr\bin to Windows PATH. and ensure then rsync and ssh have the same paths, use 'where ssh' and 'where rsync' to check that.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .