I have Syncthing v1.20.4 Linux (64-bit Intel/AMD) installed on a QNAP NAS syncing several send-only folders to four Android devices running Syncthing-fork v126.96.36.199 with receive-only folders. Two of them are stuck attempting to sync ignored files:
Yes, this is a bug, specifically https://github.com/syncthing/syncthing/issues/7474. It’s more of a cosmetic problem though, as the synchronisation itself still does work fine. There’s no workaround, so if you want to get rid of the errors in the GUI, you will need to connect all devices together.
I saw #7474. This is happening with a different configuration. #7474 involves three folders in series, while this problem occurs with one send-only and four receive-only folders in a star configuration.
This problem has cost me several hours, and may mask items that are truly out-of-sync.
It’s surprising that connecting receive-only folders together (is that even allowed?) would resolve the problem. And why does it occur on only two of the four devices?
The problem isn’t about three folders, but rather a folder shared between three or more devices in a linear fashion.
Specifically, it happens when you share a folder from Device 1 to Device 2, then on Device 2 add it with some ignore patterns, and then share it again from Device 2 to Device 3, which results with those seemingly ignored files appear stuck in sync between Device 2 and Device 3. When that happens, you can connect Device 1 with Device 3 and share the folder between them, and the issue will go away.
Obviously, there’re cases where you simply can’t connect the two devices with each other, e.g. if Device 1 and Devices 2/3 belong to a different person, as it was in my case when I first experienced the issue.
Connecting all the receive-only folders together got everything “up to date”. Then I manually deleted the unwanted .@__thumb folders from one of the receive-only folders on one of the Android devices. That caused this device to display “Revert Local Changes” and the device with the send-only folder again attempted to sync these “ignored” folders. So then I deleted everything in the receive-only folder, expecting it to be re-synchronized without the “ignored” files, but the “ignored” files were copied too. How do I fix this?
Setting all the .stignore files the same on all devices cleared up the previous problems, but now the two recently-added Android devices are stuck attempting to sync with one of the other two Android devices, and the Out of Sync Items lists are empty. I doubt that anything is actually out-of-sync because all four Android devices are in sync with the NAS, which hosts a copy of all folders, including the send-only folders. Looks like another bug – is there a workaround?
Does the “out of sync” state persists even after restarting Syncthing? If yes, then I’d suggest to go the Android app settings, “experimental”, and “reset delta indexes” from there. This will force Syncthing to exchange indexes, which hopefully should fix the incorrect folder state.
There are files that should be ignored in the receive-only folders, so I deleted the entire contents except for the .stfolder, .stignore, and the .stignore_global.txt file included by .stignore from one of them. This caused the folder to become out-of-sync, as expected, but it was not automatically re-synced from the send-only folder. Instead, the “Revert Local Changes” button appeared. Pressing that caused syncing of >1,000 items to begin. Two problems: (1) syncing is now stuck again with 14 out-of-sync .jpg files which should be synced, and (2) sync.ffs_db files, which should have been ignored (see original post), have been synced. Am I doing something wrong?
Not really sure. Can you post full screenshots of the Syncthing Web GUI from all devices? Please make sure folder info is unfolded, and also list the final ignore patterns that are used for the folder on each device.
I’m going to test this myself, but I’d like to have a full view beforehand, so that I can try to replicate your configuration here.
I’ve found an error in my .stignore files that could explain the problems. I’m retrying syncs after correcting it.
What exactly causes the “Override Changes” button to appear? It seems to have correctly synced a folder on one of the devices. Does it delete ignored files on the receiving folder? That’s what I need to accomplish.
You will see the “Override Changes” button when the folder content on at least one of the remote devices doesn’t match the local Send Only folder. I don’t think using it should touch ignored files, but as mentioned previously, I’d like to test this myself before making any definite statements here.
When you add files locally to a Receive Only folder, the GUI will show the “Revert Local Changes” button. When a remote device does the same and the local folder is Send Only, then you will see the “Override Remote Changes” button.
In general, if you set the folder on one side to Send Only, and on the other side to Receive Only, then the synchronisation is going to be strictly one-way.
I removed the receive-only folder syncthing configuration on the four devices, deleted the folder contents except for the .stignore files, and reconnected them to the send-only folders. The first two devices synced completely, but when I added the second two, the first device began reporting 50% synced:
I gave up and reverted to syncing the Music and Pictures receive-only folders with FolderSync Pro for Android. All worked OK (except for my .stignore error) when synced all folders among 3 devices, but wouldn’t work as described when syncing among 5 devices. One receive-only folder (DISASTER) syncs OK among 5 devices, so it seems the bug(s) are related to the size of the folders and the number of devices.