Comment 14 for bug 412470

Revision history for this message
Borph (borph) wrote : Re: [Bug 412470] Re: hardlinking doesnt work with schedule per included folder enabled

> Not necessary to exclude something if you don't include it either, except when a subfolder has a lower frequency than the parent folder (otherwise you rsync the subfolder also with the higher freq). That is what I meant...

Ah ok, yes I agree. This would make sense. So what is the current
behaviour given two folders with different frequency?

> And that is exactly where it gets wrong. The copying afterwards is A not hardlinked, and B writes over the complete snapshot if it happens to be a parent folder. If you hardlink the complete older snapshot that copying afterwards is not necessary, except that rsync gets the --delete-excluded option. Why deleting something that you have copied in the first place and then afterwards copy it again. I just don't get that part...

As far as I saw it from the logs, the first "cp" just copies
'included' folders, whereas the second copies the rest, the folders
with the low frequency. I think the reason is the --delete-excluded
option, but this approach doesn't work with overlapping folders like I
had.

So best would be - as you said - to copy hardlinked _all_ files, then
do the rsync but without --delete-excluded. This way, only files we
want are synced, but every file is existing.

The question is: do we want to link _all_ files in each snapshot. This
is bad on fat32, but costs also performance on ext4. Maybe I write
more thoughts in the 'answer' section.

> Ok interesting, where comes that difference in behaviour from (mine is a Ubuntu box, but we use the same cp most probably)?
> Anyway I think we should get rid of this deleting first and then copying afterwards anyway....

I have Ubuntu at home, Fedora at work. But (being a developer myself)
I cannot 100% confirm this behaviour at the moment as long as I don't
do deeper tests at home.. so don't worry.

Peter