I’m having trouble getting encrypted folders to work; specifically, I’m seeing “unexpected items” errors and “.sync-conflict” files, even though (IIUC) syncthing shouldn’t be creating such files in an ecrypted remote. I hope this is the right place to ask.
The issue happens relatively consistently in normal use, making encrypted remotes unusable in my setup, but unfortunately I haven’t found a consistent repro. Instead, I have a recipe that consistently leads to sync-conflict files being created, which hopefully is a useful start:
Create a folder on the source machine. Share it with the destination machine, with a password.
Accept the share on the destination machine. At this point, the global state will say “0” on the destination machine, and synchronization will not start until syncthing is restarted. I suspect this is the source of the issue, but I’m not sure how to debug it:
… this is despite the source having non-empty state:
Restart syncthing (
systemctl restart syncthing) and wait for synchronization to complete:
Remove the folder, stop syncthing, and delete (
rm -r) the
test/.stfolder.removed-20221111-105603/folder on the destination’s file system
Restart syncthing, accept the folder again and put it in the same path as before.
… notice how the “global state” is wrong again
Restart syncthing again, and syncthing will create conflict files:
… notice the
4in local state. Indeed, on the destination’s file system, we have:
# ls -R test test: 6.syncthing-enc Q.syncthing-enc test/6.syncthing-enc: T0 test/6.syncthing-enc/T0: NK2FKOD9J4GQKEN7F4S5LKG1G NK2FKOD9J4GQKEN7F4S5LKG1G.sync-conflict-20221111-105829- test/Q.syncthing-enc: E7 test/Q.syncthing-enc/E7: S97KM983CLH7R2QP9PVTPFMA0 S97KM983CLH7R2QP9PVTPFMA0.sync-conflict-20221111-105829-
I realize that the recipe above is stressing syncthing, what with removing and re-adding folders. But it also leads to an easy reproduction of the problem I observe (but can’t reliably reproduce) on my normal folders: conflict files and unexpected items.
Is this a bug, and if so how can I diagnose it? It would seem that the “global state 0” might be the root of the issue, but how do I diagnose that?
Thanks a lot!
Syncthing version: syncthing v1.22.1 “Fermium Flea” (go1.19.2 linux-arm64) email@example.com 2022-11-02 06:27:53 UTC [noupgrade]
OS: Debian GNU/Linux 11 (bullseye) (Armbian)