Rsync Push files from linux to windoes. ssh issue - connection refused

Posted by piyush c on Server Fault See other posts from Server Fault or by piyush c
Published on 2011-06-24T12:52:32Z Indexed on 2011/06/27 8:24 UTC
Read the original article Hit count: 305

Filed under:
|
|
|
|

For some reason I want to run a script to move files from Linux machine to Windows. I have installed cwRsync on my windows machine and able to connect to linux machine.

When i execute following command:

rsync -e "ssh -l "piyush"" -Wgovz --timeout 120 --delay-updates --remove-sent-files /usr/local/src/piyush/sync/* "[email protected]:/cygdrive/d/temp"

Where 10.0.0.60 is my widows machine and I am running above command on Linux - CentOS 5.5.

After running command I get following error message:

ssh: connect to host 10.0.0.60 port 22: Connection refused
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(463) [sender=2.6.8]
[root@localhost sync]# ssh [email protected]
ssh: connect to host 10.0.0.60 port 22: Connection refused

I have modified my firewall settings on widows to allow all ports. I think this issue is due to SSH Daemon not present on my windows machine. So I tried installing OpenSSH on my machine and running ssh-agent but didn't helped.

I tried similar command to run on my widows machine to pull files from Linux and its working fine. For some reason I want command for Linux machine so that I can embed it in a shell script.

Can you suggest me if I am missing anything.

© Server Fault or respective owner

Related posts about linux

Related posts about shell