On Wed, 14 Oct 2020 11:50:43 +0200 "Carlos E. R." <robin.listas@telefonica.net> wrote:
On 14/10/2020 11.38, Dave Howorth wrote:
On Wed, 14 Oct 2020 10:48:20 +0200 (CEST) "Carlos E. R." <> wrote:
...
I get:
+++............. Erebor:/data # l Portatil_entero_?/rsync_Home/cer/spamassassin.zip - -rw-r--r-- 1 cer users 7592643 Jun 10 2016 Portatil_entero_6/rsync_Home/cer/spamassassin.zip - -rw-r--r-- 1 cer users 7592643 Jun 10 2016 Portatil_entero_7/rsync_Home/cer/spamassassin.zip Erebor:/data # .............++-
The "1" indicate they are real files both, not hardlinks one to the other.
I think that's also correct. I expect there's a way to check by listing numerical IDs instead of filenames or somesuch, depending on the filesystem.
Ah, rings a bell...
original:
cer@Telcontar:~> ls -ltr --inode /data/Datum/mountpoint/Portatil_entero_?/rsync_Home/cer/spamassassin.zip 1442217551 -rw-r--r-- 2 cer users 7592643 Jun 10 2016 /data/Datum/mountpoint/Portatil_entero_7/rsync_Home/cer/spamassassin.zip 1442217551 -rw-r--r-- 2 cer users 7592643 Jun 10 2016 /data/Datum/mountpoint/Portatil_entero_6/rsync_Home/cer/spamassassin.zip cer@Telcontar:~>
copy:
Erebor:/data # ls -ltr --inode Portatil_entero_?/rsync_Home/cer/spamassassin.zip 66229 -rw-r--r-- 1 cer users 7592643 Jun 10 2016 Portatil_entero_7/rsync_Home/cer/spamassassin.zip 939879 -rw-r--r-- 1 cer users 7592643 Jun 10 2016 Portatil_entero_6/rsync_Home/cer/spamassassin.zip Erebor:/data #
Yes, the original backup have the same inode.
Why, what did I do wrong?
Probably silly question, but what's the filesystem structure? i.e. it is possible to make hard links between those two directories, isn't it?
Yes, the directories are in the same partition and filesystem. The original is XFS, the destination is btrfs
Erebor:/data # touch test Erebor:/data # ln test test2 Erebor:/data # ls -ltr --inode test* 1712666 -rw-r--r-- 2 root root 0 Oct 14 11:48 test2 1712666 -rw-r--r-- 2 root root 0 Oct 14 11:48 test Erebor:/data #
Verified.
OK, the manual says: "Note that rsync can only detect hard links between files that are inside the transfer set. If rsync updates a file that has extra hard-link connections to files outside the transfer, that linkage will be broken." I suspect your second set of rsyncs meets that caveat and so your files are unlinked. Copy the whole lot in one transfer and it may work. I also know that rsync can create hard-links on the fly in the destination even when there's no such concept on the source side. I know because that's how my incremental full backup works. But I don't remember the full set of flags at the mo. But if you can figure out the flags, that would presumably also correct your problem. I'll look it up if you get stuck. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org