Thursday, September 10, 2009

how to run rsync command remotely

I wanted to rsync the data from one node to other but I was frustrated by the rsync error of cod 12 at io.c 463. It was like this

[root@192.168.1.100]# rsync -racv -e "ssh -l root" /vz/private/130 192.168.1.1:/vz/private
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]

Connection from 192.168.1.100 were giving errors while connecting to the 192.168.1.1

But the connection from 192.168.1.1 to 192.168.1.100 were fine. So I modified the command to trigger the backup from 192.168.1.1 to 192.168.1.100. Command exectuted at 192.168.1.1

[root@192.168.1.1]# rsync -racv -e "ssh -l root" 192.168.1.100:/vz/private/130 /vz/private

Now the data from 192.168.1.100 is dumping to the 192.168.1.1

Took sometime to find the resolution for code 12 but no results on yahoo or google. Will still look the resolution but till that time I running dump... lol

No comments: