Is Syncthing able to detect cross folder changes?

#1

We have three nodes and these three nodes share several folders (A, B, C, …) via Syncthing between each other. If we move files from shared folder A to shared folder B can Syncthing detect this change or will Syncthing regard these files in folder B as new/created and up-/download them completely?

0 Likes

(Simon) #2

Neither :slight_smile:

It can’t detect moves between folders, but if the creation happens before the deletion it will copy the data locally instead of getting the data from remotes. If you use filesystem watching that should be the case, as deletions get delayed compared to creations. And if you don’t, it would work if there are enough changes for both folders, as deletions are processed last. If there’s deletions only on one folder and creations only for the other, deletions will be fast and thus delete stuff before it can be copied locally and it will have to pull data from remotes.

0 Likes

(Audrius Butkevicius) #3

Even then, it’s not guaranteed, as if you move large folder trees across (which has hundereds of file entries) there is a protocol level size of message that limits what might be noticed in what order at what time.

Best bet is to copy, wait for a rebuild on the other side, delete.

1 Like

#4

Thanks for your input, very interesting indeed. Does this also apply cross shares? Or does each Syncthing folder have its own independent database?

0 Likes

(Audrius Butkevicius) #5

Renames don’t work across folders as each folder is independent, but avoiding downloads by reusing data from another folder works across folders, which would kick in in the copy wait delete scenario.

0 Likes