I have a Western Digital connected to my router at 192.168.1.65 statically.
How can I automatically connect at login and rsync? At the moment I am using this command that doesn't work.
rsync -Paz /home/chris/ 192.168.1.65:LinuxHome/
but I get this
ssh: connect to host 192.168.1.65 port 22: Connection refused
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: unexplained error (code 255) at io.c(605) [sender=3.0.9]
This screenshot of the Western Digital MyBookWorld control panel might help
https://dl.dropbox.com/u/2423935/wd.png
EDIT: I updated the command to rsync -Paz -e ssh /home/chris/ 192.168.1.65:LinuxHome/
as suggested and it works (I also enabled ssh from the control panel) but I would like to connect-rsync automatically (either by a cron job or during login no matter to me)
Your command is not complete, try something like this:
rsync -Paz -e ssh /home/chris/ [email protected]:/LinuxHome/
To connect to your Box without giving a Password create an authorized_key. You can find a Howto hiere: http://sshkeychain.sourceforge.net/mirrors/SSH-with-Keys-HOWTO/SSH-with-Keys-HOWTO-4.html
Copy your public key in the "Key"-Field of you WC configuration. Don't change anything, just copy it like it is. When it works you should connect with your Key and you won't be asked for a password while connecting.