Hi all:
I am using Ubuntu MATE 22.04.3, which comes with the oldish syncthing v1.18.0-ds1. But I am guessing my questions apply to newer Syncthing versions too.
I have a local Linux PC with an external NTFS USB disk configured as “send only”, and another remote Linux PC with a similar external NTFS USB disk configured as “receive only”.
A few months ago I sent many gigabytes over the Internet, which took a very long time. Now I am getting on the remote, receiving PC a prompt to revert local changes. The thing is, I haven’t changed anything locally there, and the PCs, Linux and Syncthing versions, and USB disks are the same. I searched the Internet, and it seems like I am not alone. However, the answers I found are not entirely satisfactory, so I am trying my luck here.
I am worried about confirming the “revert local changes” operation, for fear it may delete files, or retransmit a lot of data again. On another place in the web interface, it said something about “local additions”, and not just general “changes”. The list of unsynchronised files on the remote, receiving PC just lists names and filesizes, suggesting it may transmit all the data again.
The sending side apparently knows what files the receiving side wants to resynchronise too, they are more than 22,000, around half of the files. I picked the first filename and did “stat” on both sides. The “last modification time” (mtime) is exactly the same. On the sending PC, there is no creation time, which I wonder, as both systems are nearly identical. The “last change time” (ctime) and the “last access time” are different, but those should not matter, as far as I understand.
The permissions are different, (0777/-rwxrwxrwx) on the sending side and (0755/-rwxr-xr-x) on the receiving side. I also wonder why, as both setups are very similar. But this difference may be an issue, more on that below.
The file types, sizes and number of blocks are the same too.
The user and group names and IDs are different, but those shouldn’t matter either, if I understood it correctly. I haven’t enabled any funky options to synchronise such details.
Command “syncthing cli debug file” did not work, because I should have enabled debugging, which I did not have time to, and now I haven’t got access to the remote computer for a while.
I did manage to enable option “ignore permissions” on both sides, but that did not have any visible effect at the time.
In the meantime, I wanted to learn how to troubleshoot this issue once and for all. I have read far more documentation and user posts that should really be necessary.
So let me get the following straight:
-
There is no way to preview what Syncthing will do with a file it considers that it has changed (an unsynchronised file). Or is there?
Possibilities would be “I would retransmit the file contents”, “I would only adjust the file permissions”, “I would delete the file as it no longer exists on the sending side”, and maybe more. -
There is no “dry run” mode, so that you could see what Syncthing would actually do. Or am I wrong?
-
There is no way to find out why Syncthing thinks that a file has changed, right? It maybe the timestamp, the permissions, the size, the data hash, or whatever Syncthing comes up with.
You cannot find the “unsynchronised” reason neither in the web interface nor with the API. You can dump JSON data, manually compare interesting values, and then guess. For each file, of course. Or am I wrong here? -
Option “ignore permissions” is only really important on the receiving side. Is that correct?
-
Once files are marked as “unsynchronised”, changing option “ignore permissions” on either side does not trigger a recalculation of the “unsynchronised” file status, or does it?
The reason I am asking is that it looks like only the file permissions on both sides are different, but enabling “ignore permissions” had no visible effect at the time.
If Syncthing knows the metadata on both sides (does it?), then it should have flagged all files immediately as “synchronised” (or so I think). -
There is no way to trigger a “reset-deltas” or a “reset-database” operation from the web interface, right?
I am asking because there is an occasional user at the remote side, but without enough IT skills to use a command console. -
There is no easy way to see a file’s metadata, like its last modification time, with the web interface. You have to resort to “stat” on the shell, “syncthing cli debug file” or the API. Correct?
-
Did Syncthing really run out of ideas about making troubleshooting and fixing spurious “local changes” even harder, or should I hold on tight for yet more refined evilness next time around? Okay, that’s not really a serious question… O8-)
Thanks in advance,
rdiez