Take2: rsync over ssh with --link-dest
mysqlstudent at gmail.com
Wed Nov 11 16:32:01 MST 2009
>> rsync -avz --delete --numeric-ids --exclude-from=/backup/exclude-file.txt \
>> --link-dest=/backup/seg/serverA/xxx.xxx.228/cdrive/20091109 \
>> rsync://serverA/cdrive/20091110/ \
> Your daemon setup looks exactly right. I don't understand why you
> consider it more complicated than the previous setup. Previously you
> had one SSH authorized key for each backup point with the appropriate
Well, no, I didn't have that because it doesn't work. I've been using
empty passphrase keys with command= for many years, but never really
had a requirement to override the path in this way.
> In contrast, the forced-server-command approach would clobber the
> 20091110/ part, preventing you from setting up the --link-dest properly.
> Is it clear now?
Yes, and hopefully I've clarified what I'm doing now too. :-)
> It seems to me that you would have had to do the same thing under the
> forced-server-command setup. No?
Yep, exactly :-)
> In any case, sed is overkill to vary the date. You can just use a shell
> DATE=$(date +%Y%m%d)
> rsync ... /backup/seg/serverA/xxx.xxx.228/cdrive/$DATE
It's part of a larger backup script with its own configuration file, actually.
Thanks so much.
More information about the rsync