I rsync a file structure from e.g. /home/fred/folder1 to e.g. /home/me/sync, where the latter is a Syncthing directory, and where the operation yields /home/fred/sync/home/fred/folder1 (sic). I have set rsync to preserve ownership, so the owner of /home/fred/sync/home is - remains - root. However, once Syncthing transfers /home/fred/sync/home to another computer, that directory (‘home’) ends up being the user under which Syncthing runs on that other computer - say, ‘Trish’. But I need that owner to remain root (because I then rsync it to the local filesystem).
What to do? I looked at this forum post and this issue but I understand them poorly - they’re too advanced for me. I hope that there is an answer, besides running Syncthing as root.
I suppose the short version of my query is as follows. I use Syncthing with rsync and Syncthing is not preserving ownership.
Thank you. However: having spent months get my syncthing-with-rsync working - working apart from this problem - I’m not giving up now, especially since, for transferring stuff between my laptops, I really need this ability.
Thanks, but since what I want is a partial mirror of my filesystem, the desired ownership varies by item. Also: the project I mentioned is designed to solve exactly my problem. Or so it seems to me. Perhaps I misunderstand.