Backing up your website

After glancing at the good "Pass on Passwords with scp":http://www.linuxjournal.com/article/8600 article on Linux Journal, I want to point out that I actually prefer "rsync":http://samba.anu.edu.au/rsync/ as it only backs up modified files. An incantation such as


rsync -av \\
  -e 'ssh -l remoteusername -i ~/.ssh/id_rsa' \\
  remoteusername@webhoster.com:.  backup/

will log in to your web server as _remoteuser_ via _ssh_ using the given identity file and will initiate an _rsync_ back to the local machine, storing it in the _backup/_ directory.

Comments are closed.