We are using rsync 2.3.1 for daily backups. The script creates
a hardlink tree (find | cpio -pdml) to duplicate yesterday's state,
then runs rsync to update this. Currently I copy / to just a second
disk /backup/<date> on the same machine.
Options currently used:
--archive --sparse $exclude_rsync --delete --delete-excluded --force
$exclude_rsync is some classes of files and areas we don't save
(e.g. Trash/, *.mp3) plus top levels like /proc and /backup ...
Last time I manually moved my homedir: I had
dir /home/ntm/homes/louis
symlink /home/louis -> ntm/homes/louis
(which already was reflected in /backup), then I did
cd /home
rm louis
mv ntm/homes/louis .
ln -s /home/louis ntm/homes
so I had now
dir /home/louis
symlink /home/ntm/homes/louis -> /home/louis
(note: the new symlink is absolute).
rsync can't detect that I only moved the directory, so it started
to delete the old tree, then copying the new tree.
It seems that while deleting the whole bunch of files it already
installed the new (absolute) symlink. Kept on deleting a list of
files which now happened to be the ones on /home itself. Blush!
Ok. I tried reading and investigating all the safe- and unsafe-link
options, but I can't get it right. --safe-links is the best as it
doesn't shoot my real files, yet the backup is incorrect then (it
doesn't replace the directory by the symlink then).
Any advise besides "Don't use absolute symlinks" (:-)?
louis
--
J�rgen "Louis" Fluk mailto:[EMAIL PROTECTED]
New Technologies Management GmbH Tel +49 89 993415-56
Stefan-George-Ring 24, D-81929 M�nchen Fax +49 89 993415-99