Recommended rsync tutorials?

Roger H. Goun roger at bcah.com
Tue Oct 19 17:24:26 EDT 2010


On Mon, Oct 18, 2010 at 20:28, Bruce Labitt
<bruce.labitt at myfairpoint.net> wrote:
>  I'm looking to use rsync on a cron job to do some
> 'backup'.  I've read man rsync and a few 'tutorials'.  It
> looks not too hard - this worries me.  :)
>
> Anyone have a good/favorite tutorial on rsync that talks
> about how to do this over ssh and avoids common pitfalls?
> (like unmounted nfs...) lmgtfy, would not be too helpful.
> Done that, checked out a few of them, looking for something
> relatively understandable...

A couple of additional suggestions.

Don't forget to add --rsh=ssh or --rsh="ssh -l ssh-user" to the rsync
command line.

Also, when I need to use an ssh key without a password for unattended
tasks like this, I like to configure ssh on the remote side to
restrict the key to performing only the required rsync command and
nothing else. This prevents a hacker who obtains the private key (say,
by hacking the local system) from having his way with the remote
system. See the discussion of the authorized_keys file format in
sshd(8) for details on how to do this. ssh -vvv is very helpful in
figuring out exactly what rsync command is being executed on the
remote system.

-- Roger



More information about the gnhlug-discuss mailing list